bard.mac - a bard botting macro

Macro depository for macros written before the user variable changes that broke all of them.

Moderator: MacroQuest Developers

sempi
orc pawn
orc pawn
Posts: 22
Joined: Wed Jul 10, 2002 10:31 pm

bard.mac - a bard botting macro

Post by sempi » Wed Jul 10, 2002 10:35 pm

Need some testers on this new macro, its completely untested but logical to me. Also have a cleric one I might post soon, don't need it to be tested though.
Edited for some corrections, macro now works fairly well.

Code: Select all

| - bard.mac -
|
| first 3 gems are battle songs
| gem 4 is snare
| gem 5 is mana song
| gem 6 is mez
|
| commands:  x is an npc name, sent by %t
| "attack x"
| "mez x"
| "snare"  Will snare current target
| "mana"
| Example: /tell bard attack %t (when you have something targeted)
|
| written by sempi, with the help of dreamer

#Event CastFizzle "Your spell fizzles!"
#Event CastInterrupt "Your spell is interrupted."

#chat tell

Sub Main
    /press esc
    /press esc
    /press esc
    /sit off
    /g super kitty bard to the rescue
    /varset v1 1
    /varset v2 2
    /varset v3 3
    /stopsong
    /delay 5
    :Sing
       /if $combat==TRUE /if n $target(distance)>12 /call UpClose
       /varset v10 0    | if v10==1 restart singing from first song in order
       /call cast v1
       /delay 22
       /stopsong
       /doevents
       /if $combat==FALSE /call mana  | will do endless mana song if not in combat
       /if n $v10==1 /goto :Sing
       /if $combat==TRUE /if n $target(distance)>12 /call UpClose  | get close to target
       /delay 4
       /call cast v2
       /delay 22
       /stopsong
       /doevents
       /if $combat==FALSE /call mana
       /if n $v10==1 /goto :Sing
       /if $combat==TRUE /if n $target(distance)>12 /call UpClose
       /delay 4
       /call cast v3
       /delay 22
       /stopsong
       /doevents
       /delay 4
       /if $combat==FALSE /call mana
    /goto :Sing
/return

Sub cast
 /varset v4 $p0   | v4=current spell being casted
   :ReCast 
   /varset v99 0  | v99 check for interupt and fizzle
   /cast $v4 
   /delay 1s 
   /doevents 
   /if n $v99==1 /goto :ReCast 
 /return

Sub Event_Chat
 /varset v69 "$p2" 
 /if "$arg(1,"$v69")"=="snare" /call snare
 /if "$arg(1,"$v69")"=="mana" /call mana
 /if "$arg(1,"$v69")"=="attack" /call attack
 /if "$arg(1,"$v69")"=="mez" /call mez
 /return

Sub UpClose
	:evencloser
		/doevents
		/face
		/if n $target(distance)>10 /sendkey down up
		/if n $target(distance)<11 /sendkey up up
		/if n $target(distance)<11 /return
		/doevents
	/goto :evencloser
/return

Sub snare
 /doevents flush
 /if "$target(name)"=="NULL" /g target not found
 /if "$target(name)"=="NULL" /return
 /delay 4
 /varset v1 4
 /varset v10 1
 /return

Sub mana
 /doevents flush
 /delay 4
 /varset v1 5
 /varset v10 1
 /return

Sub Attack
 /doevents flush
 /varset v1 1
 /varset v2 2
 /varset v3 3
 /varset v10 1
 /target npc $arg(2,"$v69")
 /if "$target(name)"=="NULL" /g target not found
 /if "$target(name)"=="NULL" /return
 /attack on
 /delay 4
 /return

Sub mez
 /doevents flush
 /if "$target(name)"=="NULL" /g target not found
 /if "$target(name)"=="NULL" /return
 /varset v1 6
 /varset v10 1
 /attack off
 /target npc $arg(2,"$v69")
 /delay 4
 /return

Sub Event_CastFizzle
 /varset v99 1
 /return

Sub Event_CastInterrupt 
 /varset v99 1 
/return