Code: Select all
#turbo
#event NI "You begin casting Nature's Infusion."
#event KR "You begin casting Karana's Renewal."
#event snare "has been ensnared."
#event root "You begin casting Savage Roots."
#event RI "is surrounded by an outline of cold flame."
#event HoR "is immolated by blazing flames."
#event eci "is encrusted with a thin layer of ice."
#event sotw "is encrusted by bark."
#event rooted "is entrapped by roots."
#event DS "surrounded by a thorny barrier."
#event unsnare" Your Ensnare spell has worn off."
#event exp "experience"
#event cure "you begin casting Radiant "
#event immune "Your target is immune to changes in its run speed"
#define ensnare v56
#define Damageshield1 t1
#define Damageshield2 t2
#define Damageshield3 t3
#define tank1 v55
#define tank2 v57
#define tank3 v58
#define Vsotw v59
#define channel v60
||usage: /macro call.mac <channel (/g, /2)> <MT> <ST>
Sub Main
/echo usage: /macro call.mac <channel (g, 2) [[don't use a /]]> <MT> <ST>
/if $p0== {
/echo you must specify a channel for calls
/end }
/varset v10 $p1
/varset v11 $p2
/varset channel $p0
/varset ensnare 0
/varset Vsotw 0
:loop
/goto :grouphealth
/doevents
/if n $Vsotw>=1 /call sotwCall
/goto :loop
/return
:grouphealth
/if n $spawn($group(1),hp,pct)<=50 {
/if n $spawn($group(1),id)!=$target(id) {
/if n $spawn($group(1),name)!=NULL {
/if n $t5==0 {
/echo better check $spawn($group(1),name)
/varset t5 5s
}
}
}
}
/if n $spawn($group(2),hp,pct)<=50 {
/if n $spawn($group(2),id)!=$target(id) {
/if n $spawn($group(2),name)!=NULL {
/if n $t6==0 {
/echo better check $spawn($group(2),name)
/varset t6 5s
}
}
}
}
/if n $spawn($group(3),hp,pct)<=50 {
/if n $spawn($group(3),id)!=$target(id) {
/if n $spawn($group(3),name)!=NULL {
/if n $t7==0 {
/echo better check $spawn($group(3),name)
/varset t7 5s
}
}
}
}
/if n $spawn($group(4),hp,pct)<=50 {
/if n $spawn($group(4),id)!=$target(id) {
/if n $spawn($group(4),name)!=NULL {
/if n $t8==0 {
/echo better check $spawn($group(4),name)
/varset t8 5s
}
}
}
}
/if n $spawn($group(5),hp,pct)<=50 {
/if n $spawn($group(5),id)!=$target(id) {
/if n $spawn($group(5),name)!=NULL {
/if n $t9==0 {
/echo better check $spawn($group(5),name)
/varset t9 5s
}
}
}
}
/goto :loop
sub Event_unsnare
/varset ensnare 0
/return
sub Event_cure
/$channel cure incomming
/return
sub Event_immune
/$channel %T is immune to changes in its run speed
/return
sub Event_exp
/varset ensnare 0
/return
Sub Event_NI
/if $target(type)==NPC {
/delay 1s
/press s
/delay 1s
/press s
/return
}
/if $target(type)==Corpse {
/delay 1s
/press s
/delay 1s
/press s
/return
}
/if $target(type)!=NPC {
/IF $target(type)!=Corpse {
/if n $target(hp,pct)<=80 /$channel patching %T
/return
}
}
Sub Event_KR
/if $target(type)==NPC {
/delay 1s
/press s
/delay 1s
/press s
/return
}
/if $target(type)==Corpse {
/delay 1s
/press s
/delay 1s
/press s
}
/if $target(type)!=NPC {
/if $target(type) != Corpse {
/if n $target(hp,pct)<90 {
/$channel 4.7k heal inc %T, 10 seconds
/return
}
}
}
Sub Event_snare
/if n $ensnare==0 /$channel %T snared
/varset ensnare 1
/return
Sub Event_Rooted
/$channel %T rooted! back away so it doesn't pwn you.
/return
Sub sotwCall
/if $target(id)==$group(0) /g SotW inc
/if $target(id)==$group(1) /g SotW inc
/if $target(id)==$group(2) /g SotW inc
/if $target(id)==$group(3) /g SotW inc
/if $target(id)==$group(4) /g SotW inc
/if $target(id)==$group(5) /g SotW inc
/if $target(type)==NPC /g SotW inc
/if $target(type)!=NPC {
/if $channel!=g {
/$channel SotW to %Ts group
}
}
/varset Vsotw 0
/return
Sub Event_sotw
/varadd Vsotw 1
/return
Sub Event_RI
/if n $target(level)>=65 /$channel Ro's Illumination on %T, ac(15) and atk(80) debuffed.
/return
Sub Event_HoR
/if n $target(level)>=65 /$channel HoR on %T, ac(15), atk(100) and FR(72) debuffed
/return
Sub Event_eci
/if n $target(level)>=65 /$channel e`ci's on %T, ac(24) and CR(55) debuffed
/return
Sub Event_DS
/if n $Damageshield1==0 {
/varset tank1 $target(name)
/varset Damageshield1 6m
} else /if ($Damageshield1!=0 && $Damageshield2==0) {
/varset tank2 $target(name)
/varset Damageshield2 6m
} else /if n $Damageshield3==0 {
/varset tank3 $target(name)
/varset Damageshield3 6m
}
/return
Sub Event_timer
/if n $p0==1 {
/echo time to redo DS on $tank1
} else /if n $p0==2 {
/echo time to redo DS on $tank2
} else /if n $p0==3 {
/echo time to redo DS on $tank3
}
/return
|||TODO|||
get all checks on heals to work (mostly working I think, get couldn't parse '=Corpse when cast on PC)
it should warn me if the mob gets below 40 health and I haven't snared it yet
link snare to $target(id) (for multiple targets)
add abort mesage for aborted heals
calculate targets health and calculate if I should abort the Cheal and start a patch or not
add a str buff timer
add patch msg for chloroblast
make it invis me every time invis drops and I have a pet, or let me set autoinvis on the fly
give a rogue calculation for when I should start a CH based on the rate at which the tanks HPs drop**|at random intervals, I will get an error with something to the effect of event_snare colliding with sub Main. then, two events will go off, it'll say "target is snared" and "cure incomming" then the macro will crash. any hints? I think it may have something to do with where I put /doevents.
I also have some more questions if anyone cares to answer them. the :grouphealth loop doesn't seem to work at all.
Also, I have is say $channel to use /g, /2 or whatever as the channel for all my calls. This doesn't work unless I do /if n 1==1, etc. It doesn't work period if I have channel as /rs.
And if anyone wants to help get anything on my todo list done... :twisted: :twisted: :D
thanks
Edit: updated it so that when sending a msg it's initialized by a / and then the appropriat channel. I'll test it when I get home.



