mage thing..

Macro requests from before the user variable changes that broke all macros

Moderator: MacroQuest Developers

Kardath
decaying skeleton
decaying skeleton
Posts: 1
Joined: Thu Jun 19, 2003 12:05 pm
Location: NV

mage thing..

Post by Kardath » Tue Jul 01, 2003 1:20 pm

looking for someone to write a macro for me that will let me send a tell to my mage and have him assist then /pet attack.. would do it myself but I can never get events to work right :p

|-|ead_|-|unter
decaying skeleton
decaying skeleton
Posts: 1
Joined: Fri Jul 11, 2003 2:53 pm

Post by |-|ead_|-|unter » Fri Jul 11, 2003 2:55 pm

This is my first attempt at a macro.. But does this look right?? Please give feed back on other methods instead of press.

Sub Main
:Loop
/doevents Chat
/goto :Loop
/return

Sub Event_Chat
/if "$p0"~~"tell" {
/if "$p1"~~"playername" { |* enter player name here *|
if "$p2"~~"patt" {
/call patt($p1)
} else if "$p2"~~"pbo" {
/call pbo
}

}
}

/return


sub patt
/target "&po"

/press /
/press a
/press s
/press s
/press enter

/press /
/press a
/press s
/press s
/press enter

/press /
/press p
/press e
/press t
/press space
/press a
/press t
/press t
/press a
/press c
/press k
/press enter
/return

sub pbo
/press /
/press p
/press e
/press t
/press space
/press b
/press a
/press c
/press k
/press space
/press o
/press f
/press f
/press enter
/return

GoatFoot
a lesser mummy
a lesser mummy
Posts: 68
Joined: Fri Jan 17, 2003 1:48 am

magebot.mac

Post by GoatFoot » Fri Jul 11, 2003 3:50 pm

Very rough, as is, not tested, use at own risk, not responsible for any burnt cheese.

/mac magebot name

Code: Select all

#chat tell

sub main
/varset v1 "$p0"

  :Loop
    /doevents chat
    /delay 3s
  /goto :Loop

/return

sub Even_Chat
  /if "$p1"!="$v1"  {
    /tell "$p1" "wait one"
    /tell "$v1" $p1 told me $p2
    /return
  }

  /if "$p2"=="patk" {
    /target pc "$p1"


    |This is a bad example, easier if I knew we could do nested {}'s
    :VerifyTarget
    /if "$target(name)"!="$p1" /goto :TargetVerified
      /assist
      /delay 3
      /goto :VerifyTarget
    :TargetVerified

    /pet attack
    /return
  }

  /if "$p2"=="pbo" {
    /attack off
    /pet back off
    /return
  }

/tell "$p1" huh?
/return

fixed typo and misplaced "/assist"