cbot.mac
Code: Select all
| cbot.mac
| cleric botting macro
| written by dreamer
| modified by sempi
| modified even more by S_B_R
| Usage: /macro cbot.mac <character in control>
#include SpellSub.mac
#chat tell
#Event Invited "To join the group, click on the 'FOLLOW' option, or 'DISBAND' to cancel"
#Event ClarityGone "Your mind returns to normal."
#Event InvisGone "You feel yourself starting to appear"
#Event FollowOff "You are no longer auto-following "
Sub Main
/varset v69 $p0
:chkevent
/doevents
/goto :chkevent
/return
Sub Event_Chat
/varset v3 "$p2"
/target $arg(2,"$v3")
/if $arg(2,"$v3")=="self" {
/target myself
} else /if $arg(2,"$v3")=="me" {
/target $p1
}
/delay 5
/if $arg(1,"$v3")=="ch" {
/g COMPLETE HEAL on %T in 10seconds
/call SpellSub 1 105
} else /if $arg(1,"$v3")=="ce" {
/g Celestial Healing on %T
/call SpellSub 3 45
} else /if $arg(1,"$v3")=="mok" {
/assist
/delay 2
/g Mark of Karn on %T in 4 seconds
/call SpellSub 7 40
/delay 5
/g Mark of Retribution on %T in 4 seconds
/call SpellSub 8 55
} else /if $arg(1,"$v3")=="dl" {
/g Divine Light on %T
/call SpellSub 2 50
} else /if $arg(1,"$v3")=="rem" {
/g Remedy on %T
/call SpellSub 4 35
} else /if $arg(1,"$v3")=="symbol" {
/g Symbol on %T
/call SpellSub 5 65
} else /if $arg(1,"$v3")=="hb" {
/g Heroic bond on %T
/call SpellSub 6 40
} else /if $arg(1,"$v3")=="mana" {
/target myself
/delay 5
/g Mana is at $char(mana,pct)
} else /if "$p2"=="follow" {
/target $v69
/sit off
/follow
/g Lead on %T
/varset v10 0
} else /if "$p2"=="stop" {
/press down
/varset v10 1
/tell $v69 Holding position here.
} else /if "$p2"=="sit" {
/sit
} else /if "$p2"=="LFG" {
/delay 10
/target myself
/delay 10
/disband
/delay 10
/lfg on
/tell $v69 LFG now.
} else /if "$p2"=="camp" {
/sit off
/sit
/camp
/delay 10
/unload
}
/return
Sub Event_Invited
/delay 20
/invite
/return
Sub Event_ClarityGone
/tell $v69 KEI just faded...
/return
Sub Event_InvisGone
/tell $v69 INVIS IS ABOUT TO WARE OFF.
/return
Sub Event_FollowOff
/if n $v10==1 {
/tell $v69 Holding position here.
} else {
/tell $v69 AUTO-FOLLOW BROKE!!!
/target $v69
/sendkey down up
:KeepRunning
/face
/if n $target(distance)<50 {
/sendkey up up
/follow
/varset v10 0
/tell $v69 Back on Auto-Follow go ahead.
} else {
/goto :KeepRunning
}
}
/returnCode: Select all
| - SpellSub.mac -
| Spell Casting Sub routine - Usage "/call SpellSub <gem> <delay *actual cast time plus recast*>"
| Will return $v99 = 999 if you go oom.
|
| Modified by GD to work with the 7-4-2002 Release
|
| modified by sempi to include sitting/standing and be more cleric oriented
|
| Modified by S_B_R to handle more events and relay more information to the person
| issuing the command. Also removed the auto-sit function to help control aggro. 09-07-02
#Event CastStart "You begin casting"
#Event CastFizzle "Your spell fizzles!"
#Event CastInterrupt "Your spell is interrupted."
#Event CastNoMana "Insufficient Mana to cast this spell"
#Event CastTooFar "Your target is out of range, get closer!"
#Event CastTimer "You haven't recovered yet..."
#Event CastResist "Your target resisted "
Sub SpellSub
/varset v98 $p0
/varset v99 $p1
:ReCast
/sit off
/varset v1 2
/cast $v98
/delay 10
/doevents
/if n $v1==0 /goto :ReCast
/if n $v1>1 /goto :Failure
/return
:Failure
/if n $v1==2 {
/reply Spell failed for unknown reason...
/delay 5
} else /if n $v1==3 {
/reply %T IS TOO FAR AWAY!!!
/delay 5
} else /if n $v1==4 {
/reply OOM
/delay 100
/sit on
} else /if n $v1==5 {
/reply Recast timer not met...
} else /if n $v1==6 {
/reply %T RESISTED.
}
/return
Sub Event_CastStart
/varset v1 1
/delay $v99
/return
Sub Event_CastFizzle
/varset v1 0
/return
Sub Event_CastInterrupt
/varset v1 0
/return
Sub Event_CastTooFar
/varset v1 3
/return
Sub Event_CastNoMana
/varset v1 4
/return
Sub Event_CastTimer
/varset v1 5
/return
Sub Event_CastResist
/varset v1 6
/return


