Code: Select all
#turbo
#event HideFail "You failed to hide yourself."
#event HideSuccess "You have hidden yourself from view."
~~~~
Sub Rest
/doability "Hide" | Obviously, attempt to Hide.
/delay 2s |Delay to allow the Hide chat-window text to pop up for /doevent
/doevents | Run check on result of attempted Hide and act accordingly
/press ` | Target myself (I use ` instead of the customary F1 key)
/delay 1s | Wait a second to make sure I am targetted around lag.
:BindWound
/doability "Bind Wound" | Obviously, attempt to Bind Wound
/delay 2.5s | I was too lazy to make anything fancy, so I just dropped in a delay
/if n $char(hp,pct)>="48" /goto :Rest | If I'm at 48% health, stop and move on to Rest.
/if n $char(hp,pct)<="48" /goto :BindWound | If I'm still under 48% health, keep Binding Wounds.
:Rest
/delay 8s | Delay in place to make sure Bind Wound cleans up, otherwise the message "You have moved and your attempt to bandage has failed" flashes and the /sit command below is skipped, and I stay standing.
/sit | Sit down
/press esc | Make sure I have nothing targetted
/press esc
/press esc
:Healthcheck
/if n $target(id)!=0 /return | In case I somehow get agro'ed while sitting, I'll hop up and take care of it.
/if $target()!="NULL" /return | See above.
/if n $char(hp,pct)=="100" { | Check health status
/sit off | If I'm at 100 percent health, hop up, and resume the hunt
/return
} else {
/delay 8s | Delay 8 seconds per HealthCheck
/goto :HealthCheck
{
/return
Sub Event_HideFail
/doability "Hide"
/delay 9s
/call Main
/return
Sub Event_HideSuccess
/return

