Code: Select all
|smokebot.mac
|
| SmokeBot v1.0 by orestes
|
| This is a simple script I wrote because I smoke often and don't want to leave
| my friend powerleveling our toons by himself when I'm gone during the 5 minutes
| I'm outside. This gives him the control over my melee toon briefly by creating
| a loop dedicated to picking up event triggers and then acting upon them
| accordingly.
|
| Note: The movement code is a bit unorthodox but like I said, it's simple but it
| works fine Make sure you've got Num Lock set to auto-run or it'll just
| sit there looking pretty.
|
|----------
| Commands:
|----------
|
| /t Bot assist me now (Will assist whoever you set as MasterName)
| /t Bot follow me now (Will follow whoever you set as MasterName)
| /t Bot stop following me (Will stop following.. You get the picture.)
|
#event Assist "assist me now"
#event Follow "follow me now"
#event NoFollow "stop following me"
#event Ding "You have gained a level! "
Sub Main
/declare MasterName global
||||||||| Who commands you? |||||||||
/varset MasterName SomeRandomDude
||||||||| Who commands you? |||||||||
:AssistLoop
/doevents
/goto :AssistLoop
}
Sub Event_Assist
/assist @MasterName
/delay 2s
/face
:GetDistance
/if n $target(distance)>=13 {
/goto :CombatBegin
} else {
/face
/press Num_Lock
/press Num_Lock
/goto :GetDistance
}
:CombatBegin
/attack on
:CombatLoop
/if n $target(distance)>=13 {
/face
/press Num_Lock
/press Num_Lock
}
/if $target(type)==NULL /call ResetEvents
/goto :CombatLoop
/return
Sub Event_Follow
/target @MasterName
/delay 1s
/face
/delay 1s
/follow
/call ResetEvents
/return
Sub Event_NoFollow
/press Right
/call ResetEvents
/return
Sub Event_Ding
/tell @MasterName Ding [$char(level)]!
/call ResetEvents
/return
Sub ResetEvents
/doevents flush
/return 
