I've taken snippets from several mac's and a bit of codeing of my own to
try and get this running.
Any help, advice, code cleanup, etc would be well appreciated.
Note: one current problem
I cant seem to get the 2 timers to work properly together,eg: Leg Cut the mob (snare) instead of Head Strike'n the mob (stun). I know they both work on the same 12s timer in game but I dont have the first clue as to how to transmit the variable into the script when it says "you can not use this ability for 9sec" (or something to that effect).
Also when I use the Intimidation/Leg Cut combo in the script when activated via the event, It seems it doesn't kick in also (unsure if its the timers or the doevent placement)
Code: Select all
|zerk.mac
#turbo
|#event snare "very afraid"
Sub Main
/zapvars
/declare HeadStrikeTimer1 timer
/declare HeadStrikeTimer2 timer
/call Target
/return
Sub LoopBoth
/doevents
:combatloop
/if n $target(hp,pct)<25 /call SnareCombat
/if $combat=="TRUE" {
/if n $target(distance)<18 }
/if n $char(ability,"Frenzy")>0 /doability "Frenzy"
}
/if n $target(hp,pct)>25 {
/if n @HeadStrikeTimer2<=0 {
/keypress hot8
/varset HeadStrikeTimer2 12s
}
/if $combat=="TRUE" {
/if n $target(distance)<18 }
/if n $char(ability,"Disarm")>0 /doability "Disarm"
}
/if $combat=="TRUE" {
/if n $target(distance)<30 }
/if n $char(ability,"Intimidation")>0 /doability "Intimidation"
}
}
/delay 5
/if $combat=="FALSE" /call Target
/doevents
/goto :combatloop
/return
Sub SnareCombat
/doevents
:combatloop
/if $combat=="TRUE" {
/if n $target(distance)<18 }
/if n $char(ability,"Frenzy")>0 /doability "Frenzy"
}
/if n $target(hp,pct)<25 {
/if n @HeadStrikeTimer1<=0 {
/keypress hot7
/varset HeadStrikeTimer1 12s
}
/if $combat=="TRUE" {
/if n $target(distance)<18 }
/if n $char(ability,"Disarm")>0 /doability "Disarm"
}
/if $combat=="TRUE" {
/if n $target(distance)<30 }
/if n $char(ability,"Intimidation")>0 /doability "Intimidation"
}
}
/delay 5
/if $combat=="FALSE" /call Target
/doevents
/goto :combatloop
/return
Sub Target
/doevents
/if n $char(hp,pct)<49 /call Bindloop
:TargetLoop
/if $combat=="TRUE" /call Loopboth
/echo Searching for a TARGET
/target npc
/if ("$target()"=="FALSE" || n $target(distance)<=40) {
/echo Unable to locate any targets nearby... Will try again in 10 seconds.
/delay 10s
/if $combat=="TRUE" /call Loopboth
/goto :TargetLoop
}
:LoopID
/if $combat=="TRUE" /call Loopboth
/if $combat=="FALSE" {
/if n $target(distance)>40 {
/if n $char(ability,"intimidation")>0 /doability "Intimidation"
}
}
/delay 5
/if $target()=="FALSE" {
/if n $target(distance)<=100 /call Target
}
}
/if $combat=="TRUE" /call Loopboth
/goto :LoopID
/return
Sub Bindloop
/if $combat=="TRUE" /call LoopBoth
:BindWounds
/if "$target(name,clean)"!="$char(name,clean)" /target myself
/if n $char(ability,"Bind Wound")>0 /doability "Bind Wound"
/delay 1s
/doevents
/if n $char(hp,pct)<49 /goto :BindWounds
/if n $char(hp,pct)>49 /call Target
/return
Sub ClearVars
/zapvars
/declare HeadStrikeTimer1 timer
/declare HeadStrikeTimer2 timer
/call SnareCombat
/return
Sub Event_snare
/call ClearVars
/return
