;============================================================ ;Wavestorm - By Jarel Jones (http://wavestorm.rangerwiki.com) ;============================================================ ; ;Information on file usage in Readme.txt. ;This file contains the following: ;Popup menus. ;Various aliases. ;Music-related code. alias ws-menuadd { set %wavestorm-menu1 1 if ($hget(Player,Wavelength) == 1) { goto menuadd } elseif ($hget(Player,Wavelength) == 2) { inc %wavestorm-menu1 7 } elseif ($hget(Player,Wavelength) == 3) { inc %wavestorm-menu1 14 } elseif ($hget(Player,Wavelength) == 4) { inc %wavestorm-menu1 21 } elseif ($hget(Player,Wavelength) == 5) { inc %wavestorm-menu1 28 } elseif ($hget(Player,Wavelength) == 6) { inc %wavestorm-menu1 35 } elseif ($hget(Player,Wavelength) == 7) { inc %wavestorm-menu1 42 } elseif ($hget(Player,Wavelength) == 8) { inc %wavestorm-menu1 49 } elseif ($hget(Player,Wavelength) == 9) { inc %wavestorm-menu1 56 } elseif ($hget(Player,Wavelength) == 10) { inc %wavestorm-menu1 63 } :menuadd set %wavestorm-menu2 $calc(%wavestorm-menu1 + 1) set %wavestorm-menu3 $calc(%wavestorm-menu1 + 2) set %wavestorm-menu4 $calc(%wavestorm-menu1 + 3) set %wavestorm-menu5 $calc(%wavestorm-menu1 + 4) set %wavestorm-menu6 $calc(%wavestorm-menu1 + 5) set %wavestorm-menu7 $calc(%wavestorm-menu1 + 6) } menu @Wavestorm { dclick: { if (%wavestorm-battleon == 1) { if ($strip($sline($menu,1)) !ison %wavechat) { return } attack $strip($sline($menu,1)) } else { if ($right($strip($sline($menu,1)),-1) !ison %wavechat) { return } if ($right($strip($sline($menu,1)),-1) == $me) { return } wavestat $right($strip($sline($menu,1)),-1) } } } menu channel,status,nicklist { - Wavestorm .Reset GUI:wavedialog .Reset Channel:changechat } menu @Wavestorm { rclick:wavedialog } alias stats { display3 %wavechat ---------- display3 %wavechat Wavestorm %waveversion Battle Stats: if (%wavestorm-battleon == 1) { display3 %wavechat Euphometer (HP): $+(,%wavestorm-hp,$chr(47),$hget(Player,HealthPoints)) display3 %wavechat Aurometer (MP): $+(,%wavestorm-mp,$chr(47),$hget(Player,MagicPoints)) display3 %wavechat Omega Meter - %wavestorm-omega } else { display3 %wavechat Euphometer (HP): $hget(Player,HealthPoints) display3 %wavechat Aurometer (MP): $hget(Player,MagicPoints) } display3 %wavechat Kenometer (EXP): $+(,$hget(Player,CurrentExperience)),$chr(47),$hget(Player,NeededExperience)) display3 %wavechat Dextometer (AP): $+(,$hget(Player,AbilityPoints)) - Omnis: $hget(Player,Credits) display3 %wavechat Wins: $+(,$hget(Player,Wins)) - Losses: $hget(Player,Losses) display3 %wavechat Level: $hget(Player,Level) - Weapon: $hget(Player,Weaponname) if ($hget(Player,Color) == None) { display3 %wavechat Wavelength Class: 1,0None - Gender: $hget(Player,Gender) } elseif ($hget(Player,Color) == Red) { display3 %wavechat Wavelength Class: 4,0Red - Gender: $hget(Player,Gender) } elseif ($hget(Player,Color) == Yellow) { display3 %wavechat Wavelength Class: 8,1Yellow - Gender: $hget(Player,Gender) } elseif ($hget(Player,Color) == Green) { display3 %wavechat Wavelength Class: 3,5Green - Gender: $hget(Player,Gender) } elseif ($hget(Player,Color) == Blue) { display3 %wavechat Wavelength Class: 2,0Blue - Gender: $hget(Player,Gender) } elseif ($hget(Player,Color) == Purple) { display3 %wavechat Wavelength Class: 6,0Purple - Gender: $hget(Player,Gender) } elseif ($hget(Player,Color) == White) { display3 %wavechat Wavelength Class: 0,1White - Gender: $hget(Player,Gender) } elseif ($hget(Player,Color) == Beige) { display3 %wavechat Wavelength Class: 7,1Beige - Gender: $hget(Player,Gender) } elseif ($hget(Player,Color) == Black) { display3 %wavechat Wavelength Class: 1,0Black - Gender: $hget(Player,Gender) } elseif ($hget(Player,Color) == Orange) { display3 %wavechat Wavelength Class: 1,7Orange - Gender: $hget(Player,Gender) } elseif ($hget(Player,Color) == Gray) { display3 %wavechat Wavelength Class: 0,14Gray - Gender: $hget(Player,Gender) } if (%wavestorm-battleon == 1) { if (%wavestorm-z02 == 1) { set %wavestorm-status02 On } else { set %wavestorm-status02 Off } if (%wavestorm-z10 == 1) { set %wavestorm-status10 On } else { set %wavestorm-status10 Off } if (%wavestorm-z03 == 1) { set %wavestorm-status03 On } else { set %wavestorm-status03 Off } if (%wavestorm-z16 == 1) { set %wavestorm-status16 On } else { set %wavestorm-status16 Off } if (%wavestorm-z05 == 1) { set %wavestorm-status05 On } else { set %wavestorm-status05 Off } if (%wavestorm-z06 == 1) { set %wavestorm-status06 On } else { set %wavestorm-status06 Off } if (%wavestorm-z04 == 1) { set %wavestorm-status04 On } else { set %wavestorm-status04 Off } if (%wavestorm-z07 == 1) { set %wavestorm-status07 On } else { set %wavestorm-status07 Off } if (%wavestorm-z12 == 1) { set %wavestorm-status12 On } else { set %wavestorm-status12 Off } if (%wavestorm-z08 == 1) { set %wavestorm-status08 On } else { set %wavestorm-status08 Off } if (%wavestorm-z13 == 1) { set %wavestorm-status13 On } else { set %wavestorm-status13 Off } if (%wavestorm-z14 == 1) { set %wavestorm-status14 On } else { set %wavestorm-status14 Off } if (%wavestorm-z15 == 1) { set %wavestorm-status15 On } else { set %wavestorm-status15 Off } display3 %wavechat Poisoned: %wavestorm-status02 - Dodge Up: %wavestorm-status10 display3 %wavechat Fortification - Physical: %wavestorm-status03 - Magical: %wavestorm-status16 display3 %wavechat Haste: %wavestorm-status05 - Slowed: %wavestorm-status06 display3 %wavechat Asleep: %wavestorm-status04 - Stopped: %wavestorm-status07 display3 %wavechat Energized: %wavestorm-status12 - Weakened: %wavestorm-status08 display3 %wavechat Cloned: %wavestorm-status13 - Reflect: %wavestorm-status14 display3 %wavechat Teleport: %wavestorm-status15 unset %wavestorm-status* } display3 %wavechat ---------- } on *:NICK: { if ($newnick != $me) { if ($readini(" $+ $scriptdirWSInfo3.ini",$nick,level) != $null) { if ($readini(" $+ $scriptdirWSInfo3.ini",$nick,z01) != $null) { writeini " $+ $scriptdirWSInfo3.ini" $newnick z01 $readini(" $+ $scriptdirWSInfo3.ini",$nick,z01) } if ($readini(" $+ $scriptdirWSInfo3.ini",$nick,s04level) != $null) { writeini " $+ $scriptdirWSInfo3.ini" $newnick s04level $readini(" $+ $scriptdirWSInfo3.ini",$nick,s04level) } if ($readini(" $+ $scriptdirWSInfo3.ini",$nick,b02) != $null) { writeini " $+ $scriptdirWSInfo3.ini" $newnick b02 $readini(" $+ $scriptdirWSInfo3.ini",$nick,b02) } if ($readini(" $+ $scriptdirWSInfo3.ini",$nick,b09) != $null) { writeini " $+ $scriptdirWSInfo3.ini" $newnick b09 $readini(" $+ $scriptdirWSInfo3.ini",$nick,b09) } if ($readini(" $+ $scriptdirWSInfo3.ini",$nick,b17) != $null) { writeini " $+ $scriptdirWSInfo3.ini" $newnick b17 $readini(" $+ $scriptdirWSInfo3.ini",$nick,b17) } if ($readini(" $+ $scriptdirWSInfo3.ini",$nick,b24) != $null) { writeini " $+ $scriptdirWSInfo3.ini" $newnick b24 $readini(" $+ $scriptdirWSInfo3.ini",$nick,b24) } writeini " $+ $scriptdirWSInfo3.ini" $newnick level $readini(" $+ $scriptdirWSInfo3.ini",$nick,level) remini " $+ $scriptdirWSInfo3.ini" $nick } } } alias wavesend { if (%wavestorm-battleground != $null) { set %wavestorm-accept8 %wavestorm-battleground } else { set -n %wavestorm-accept8 Blank } if (%wavestorm-z01 != $null) { set %wavestorm-accept1 %wavestorm-z01 } else { set %wavestorm-accept1 0 } if (%wavestorm-s04level != $null) { set %wavestorm-accept2 %wavestorm-s04level } else { set %wavestorm-accept2 1 } if (%wavestorm-z7mode == 4) { set %wavestorm-accept4 1 } else { set %wavestorm-accept4 0 } if (%wavestorm-z7mode == 5) { set %wavestorm-accept5 1 } else { set %wavestorm-accept5 0 } if (%wavestorm-z7mode == 6) { set %wavestorm-accept6 1 } else { set %wavestorm-accept6 0 } if (%wavestorm-z7mode == 7) { set %wavestorm-accept7 1 } else { set %wavestorm-accept7 0 } set %wavestorm-accept9 $hget(Player,Wavelength) set %wavestorm-accept3 $hget(Player,Level) .notice $1 Wavestorm accept %wavestorm-accept1 %wavestorm-accept2 %wavestorm-accept3 %wavestorm-accept4 %wavestorm-accept5 %wavestorm-accept6 %wavestorm-accept7 %wavestorm-accept8 %wavestorm-accept9 unset %wavestorm-accept* } on *:TEXT:!wavestorm *:#: { statshow $nick } on *:TEXT:!wavestorm-off *:%wavechat: { if (($2- == $me) && (%wavestorm-battleon == 1) && ($nick isop %wavechat)) { display1 %wavechat Remote command from $nick intercepted; quitting out of the battle. wavequit2 } } on *:TEXT:!version:*: { .notice $nick Wavestorm v $+ %waveversion } CTCP *:version:*: { .notice $nick Wavestorm v $+ %waveversion } on *:TEXT:!ad:*: { .notice $nick Wavestorm - The Dynamic mIRC Battle Engine .notice $nick v $+ %waveversion - http://wavestorm.rangerwiki.com .notice $nick Copyright (c) 2002 - 2006 by Jarel Jones. All rights reserved. } alias wavestop { if ((%wavestorm-battleon == 1) && (%wavestorm-z07 != 1) && (%wavestorm-z07mode isnum 1 - 8)) { .timerbattle off unset %wavestorm-battletimer if ($dialog(Datascope)) { did -b datascope 2,3,4,8,12,17,18,19 } set %wavestorm-z07 1 if (%wavestorm-z07mode == 1) { display3 %wavechat You are currently frozen. You can't do anything for 30 more seconds, or until someone heals you. set %wavestorm-stopcount 30 } elseif ((%wavestorm-z07mode == 2) || (%wavestorm-z07mode == 8)) { display3 %wavechat You are currently stopped. You can't do anything for 30 more seconds, or until someone heals you. set %wavestorm-stopcount 30 } elseif (%wavestorm-z07mode == 3) { display3 %wavechat You are currently stopped. You can't do anything for 1 more minute, or until someone heals you. set %wavestorm-stopcount 60 } elseif (%wavestorm-z07mode == 4) { display3 %wavechat You are currently stopped. You can't do anything for 30 more seconds. set %wavestorm-stopcount 30 } elseif (%wavestorm-z07mode == 5) { display3 %wavechat You are currently stopped. You can't do anything for 45 more seconds. set %wavestorm-stopcount 45 } elseif (%wavestorm-z07mode == 6) { display3 %wavechat You are currently stopped. You can't do anything for 20 more seconds. set %wavestorm-stopcount 20 } elseif (%wavestorm-z07mode == 7) { display3 %wavechat You are currently stopped. You can't do anything for 45 more seconds. set %wavestorm-stopcount 45 } .timerstop 0 1 wavestop3 } } alias wavestop3 { dec %wavestorm-stopcount 1 if (%wavestorm-stopcount < 1) { unset %wavestorm-stopcount wavestop2 } else { if ($dialog(Datascope)) { did -b datascope 2,8,12 } if (%wavestorm-stopcount == 1) { if ($dialog(Datascope)) { did -i datascope 15 1 Time left in stopped mode: %wavestorm-stopcount second } } elseif (%wavestorm-stopcount > 1) { if ($dialog(Datascope)) { did -i datascope 15 1 Time left in stopped mode: %wavestorm-stopcount seconds } } } } alias wavestop2 { if ((%wavestorm-battleon == 1) && (%wavestorm-z07 == 1)) { .timerstop off unset %wavestorm-stopcount did -r datascope 15 if ($1 == hastestopcounter) { display2 %wavechat watches in amazement as the energy cylinders snap onto %wavestorm-gender3 arms and legs and suddenly flare extremely brightly. When the flare vanishes, the cylinders are gone, but $me can move again! } elseif ($1 == hastestopcounter2) { display2 %wavechat gasps as the haste counteracts the stop and %wavestorm-gender1 can suddenly move again } elseif (%wavestorm-z07mode == 1) { display2 %wavechat smashes out of the crystal encasing %wavestorm-gender2 and is able to move again } elseif (%wavestorm-z07mode == 2) { display2 %wavechat breaks out of the time warp and is able to move again } elseif (%wavestorm-z07mode == 3) { display2 %wavechat gains %wavestorm-gender3 eyesight back and is able to move } elseif (%wavestorm-z07mode == 4) { if (%wavestorm-s02back == 1) { display2 %wavechat gets caught by a sudden strong gust of wind and is brought back up onto the airship | .notice %wavechat Wavestorm %wavestorm-battleground %wavechat b02 %wavestorm-levelsend | unset %wavestorm-s02back } elseif (%wavestorm-s02back == 2) { display2 %wavechat manages to fall onto the airship when the entire vehicle lurches downward several thousand feet before flying back up again | .notice %wavechat Wavestorm %wavestorm-battleground %wavechat b02 %wavestorm-levelsend | unset %wavestorm-s02back } else { display2 %wavechat climbs hand over hand back onto the airship | .notice %wavechat Wavestorm %wavestorm-battleground %wavechat b02 %wavestorm-levelsend } } elseif (%wavestorm-z07mode == 5) { display2 %wavechat climbs out of the pitfall trap | .notice %wavechat Wavestorm %wavestorm-battleground %wavechat b09 %wavestorm-levelsend } elseif (%wavestorm-z07mode == 6) { display2 %wavechat climbs back on the motorcycle and takes off, catching up with everyone else | .notice %wavechat Wavestorm %wavestorm-battleground %wavechat b17 %wavestorm-levelsend } elseif (%wavestorm-z07mode == 7) { display2 %wavechat stumbles off the electric floor, %wavestorm-gender3 paralysis lifting | .notice %wavechat Wavestorm %wavestorm-battleground %wavechat b24 %wavestorm-levelsend } elseif (%wavestorm-z07mode == 8) { display2 %wavechat blinks as %wavestorm-gender3 body begins to move again! } unset %wavestorm-z07* unset %wavestorm-battletimer battletimer } } alias waveasleep { if (%wavestorm-battleon == 1) { set %wavestorm-z04 1 set %wavestorm-z04juststart 1 .timerbattle off unset %wavestorm-battletimer display3 %wavechat You are currently asleep. You can't do anything until a teammate heals you or until an enemy attacks you and wakes you up. } } alias waveasleep2 { if ((%wavestorm-battleon == 1) && (%wavestorm-z04 == 1)) { display2 %wavechat gets smacked up something fierce and wakes right up! unset %wavestorm-z04* unset %wavestorm-battletimer battletimer } } alias wavemelee { if (%wavestorm-battleon != 1) { if (%wavestorm-melee != 1) { set %wavestorm-melee 1 unset %wavestorm-friend* unset %wavestorm-enemy* display3 %wavechat Wavestorm - Team mode off. Melee mode engaged. } elseif (%wavestorm-melee == 1) { unset %wavestorm-melee display3 %wavechat Wavestorm - Melee mode disengaged. Team mode activated. Teammate select engaging... targetsdialog } } } alias wavemusictoggle { if (%wavemusic != 1) { set %wavemusic 1 if ($dialog(Options)) { did -c options 23 } display3 %wavechat Wavestorm - Music activated. wavestorm-music resume } elseif (%wavemusic == 1) { unset %wavemusic if ($dialog(Options)) { did -u options 23 } display3 %wavechat Wavestorm - Music disengaged. wavestorm-music stop } } alias wavestorm-music { if ($1 isnum 1 - 15) { if (%wavemusic != 1) { return } set %wavestorm-musicnum $1 if ($len(%wavestorm-musicnum) == 1) { set %wavestorm-musicnum $+(0,%wavestorm-musicnum) } if ($exists($+(",$scriptdirMusic\,%wavestorm-musicnum,.mp3,")) == $false) { return } if (($remove($insong.fname,$gettok($insong.fname,$numtok($insong.fname,92),92)) == " $+ $scriptdirMusic\") && ($right($gettok($insong.fname,$numtok($insong.fname,92),92),4) == .mp3) && ($left($gettok($insong.fname,$numtok($insong.fname,92),92),-4) == %wavestorm-musicnum)) { return } splay -p $+(",$scriptdirMusic\,%wavestorm-musicnum,.mp3") } elseif ($1 == 16) { if (%wavemusic != 1) { return } if ($insong == $true) { set %wavevolsong $vol(song) .timer -m 50 100 wavestorm-fade $calc($vol(song) / 50) 16 } } elseif ($1 == resume) { if (%wavemusic != 1) { return } if ((%wavestorm-battleon == 1) && ($insong == $false) && (%wavestorm-battleground)) { if ((%wavestorm-battleground == s15) || (%wavestorm-battleground == s16) || (%wavestorm-battleground == s17) || (%wavestorm-battleground == s18) || (%wavestorm-battleground == s19)) { if ($exists($+(",$scriptdirMusic\15.mp3,")) == $false) { return } splay -p $+(",$scriptdirMusic\15.mp3,") } else { if ($exists($+(",$scriptdirMusic\,$remove(%wavestorm-battleground,s),.mp3,")) == $false) { return } splay -p $+(",$scriptdirMusic\,$remove(%wavestorm-battleground,s),.mp3,") } } } elseif ($1 == stop) { .timer16stop off if ($insong == $true) { set %wavevolsong $vol(song) .timer -m 50 100 wavestorm-fade $calc($vol(song) / 50) } } } alias wavestorm-fade { if ($vol(song) >= $1) { vol -p $calc($vol(song) - $1) | return } if ($vol(song) < $1) { vol -p 0 } if ($vol(song) == 0) { splay -p stop vol -p %wavevolsong unset %wavevolsong if ($2 == 16) { if (!$+(",$scriptdirMusic\16.mp3,")) { return } splay -p $+(",$scriptdirMusic\16.mp3,") .timer16stop 1 10 wavestorm-music stop } } } on *:MP3END: { if ((%wavestorm-battleon == 1) && (%wavemusic == 1)) { if (($remove($filename,$gettok($filename,$numtok($filename,92),92)) == $+($scriptdir,Music\)) && ($right($gettok($filename,$numtok($filename,92),92),4) == .mp3)) { if ($left($gettok($filename,$numtok($filename,92),92),-4) == 16) { return } wavestorm-music $left($gettok($filename,$numtok($filename,92),92),-4) } } } alias wavestat { if ($1 ison %wavechat) { .notice $1 Wavestorm !wavestorm %waveversion } else { display1 %wavechat !wavestorm %waveversion } } alias wavereset { unset %wavestorm-z* if (($1 == 1) || ($1- == $null)) { set %wavestorm-hp $calc($hget(Player,HealthPoints) / 2) } elseif ($1 == 2) { set %wavestorm-hp $hget(Player,HealthPoints) } set %wavestorm-hp $round(%wavestorm-hp,0) if ($hget(Player,MagicPoints) != $null) { set %wavestorm-mp $hget(Player,MagicPoints) } startbattletimer if (%wavestorm-melee == 1) { display2 %wavechat comes back to life for more melee action! .notice %wavechat Wavestorm $me r01 $hget(Player,Level) } } alias wavesound { if (%wavemusic != 1) { return } if ($isfile($+(",%wavevoiceset,Voice.ini,")) == $false) { return } if ($vol(wave) == 0) { vol -w 40000 } if ($1 == 1) { var %wavesoundname = Cry } elseif ($1 == 2) { var %wavesoundname = Death } elseif ($1 == 3) { var %wavesoundname = Grunt } elseif ($1 == 4) { var %wavesoundname = Yah } var %wavesoundnum = $rand(1,$readini($+(",%wavevoiceset,Voice.ini,"),Number,%wavesoundname)) if ($len(%wavesoundnum) == 1) { var %wavesoundnum = $+(0,%wavesoundnum) } if ($isfile($+(",%wavevoiceset,%wavesoundname,%wavesoundnum,.wav")) == $true) { if ($inwave == $true) { set -n %wavevoiceplay $+(",%wavevoiceset,%wavesoundname,%wavesoundnum,.wav") } else { splay -w $+(",%wavevoiceset,%wavesoundname,%wavesoundnum,.wav") } } } on *:WAVEND: { if ((%wavevoiceplay) && (%wavemusic == 1)) { splay -w %wavevoiceplay } } alias wavesetvoice { set -n %wavevoiceset $sdir(" $+ $scriptdir\SFX\Voices",Choose your voice set) }