Public Macros Help withs Greenmachine
Reply
Help withs Greenmachine
I've been using the basic macro for a while now, and I LOVE It!! I typically 3 box (monk/bst/cleric), and lately I've been joined by other players. I need some help tweaking the macro a bit to make this work when others join me.

1. is there a way to make the macro /if statement check the class before attempting to heal? if the other player says "heal" in grp, the bst will stop attacking and try to heal (and i don't want that). i send a tell to the cleric (via EQBC) to heal me to overcome this.

2. Is there a way to make the macro auto accept items in the trade window? I keep the monks weight down by passing loot to the cleric. this would keep me from constantly switching screens.


thanks in advance

Macro
More +

| ########################################################################################
| ##  ALL FUNCTIONS ARE VERY BASIC, YOU NEED TO READ THE MACRO AND UNDERSTAND HOW IT WORKS TO EXPAND AND ADD TO IT
| ##  by: greenmachine, enjoy all
| ########################################################################################
|
|   >>> WORKS WITH UNDERFOOT CLIENT <<<
|
| Follows and Stops
| Auto Accepts Rez and Loots own corpse
| Auto accept invite to group
| Assists sender and pushes /attack button >> USES mq2melee plugin <<
| Prepares bot for a rezz and loot session
| Can use eqbc chat just like group chat or tells ( U must be running the eqbc chat exe to use)
| YOU NEED SPELL ROUTINES.INC to use spells, a copy if it is pasted below
| HEALS: say heal in group chat or tell or bc chat and this toon will heal you with Supernal Light spell
| BUFFS: Tell this toon virtue and it casts virtue on you

#chat tell
#chat group
#include spell_routines.inc

#Event BC         "<#1#> #2#"
#Event BC         "[#1#(msg)] #2#"
#Event Death      "You have been slain by#*#"
#event rezinc      "#*##1# tells you, 'rezinc'#*#"
#Event Invited      "#*#To join the group, click on the 'FOLLOW' option, or 'DISBAND' to cancel#*#"
#Event Invited      "#*#To join the group, click on the 'FOLLOW' option, or 'DECLINE' to cancel#*#"

Sub Main

/echo Basic mac with buffs and eqbc chat
/popup Very basic macro with Buffs and eqbc chat
/declare x int outer 0

:Start
| ## --> The line below searches to see if u have items on your toon in chest and another, if not it waits for the rez box to show up to click
   /if (!${Me.Inventory[17].ID} && !${Me.Inventory[18].ID}) /call Wait4Rez
   /doevents
/goto :Start
/return


|++++++++++++++++++++++++++
| FOLLOW
|++++++++++++++++++++++++++

Sub Event_Chat(ChatType,Sender,ChatText)

/if (${ChatType.NotEqual[EQBC]} && ${Sender.Left[1].Compare[ ]}<0) /varset Sender ${Sender.Right[-2].Left[-1]}

/if (${ChatText.Equal[Follow]}) {
   /target ${Sender}
   /varset x 1
   :Loop
   /if (${Target.ID}) {
      /face fast
      /keypress forward hold
   }
   /if (${Target.Distance}>10 && ${x}==1 && ${Target.ID}) /goto :Loop
   /if (${Target.Distance}<10 && ${Target.ID}) /goto :noFollow

   :noFollow
   /if (${Target.ID}) {
      /keypress forward
      /face fast
   }
   /doevents
   /if (${Target.Distance}>10 && ${x}==1 && ${Target.ID}) /goto :Loop
   /if (!${Target.ID}) /varset x 0
   /if (${x}==0) /return
   /goto :noFollow
   /return
}

/if (${ChatText.Equal[Stop]}) {
   /varset x 0
   /return
}

|++++++++++++++++++++++++++
| ATTACK
|++++++++++++++++++++++++++

/if (${ChatText.Equal[attack]}) {
   /assist ${Sender}
   /delay 1s ${Target.Type.Equal[NPC]}
   /if (${Target.Type.Equal[NPC]}) {
      /attack on
      /g attacking ${Target.CleanName}
   }
}

|++++++++++++++++++++++++++
| HEAL
|++++++++++++++++++++++++++

/if (${ChatText.Equal[heal]}) {
   /target pc ${Sender}
   /if (${Me.CurrentMana}>600 && ${Target.Distance}<=100 && ${Target.Name.Equal[${Sender}]}) {
      /g Healing ${Target}
      /call cast "Supernal Light" gem2 10s
   }
}

|++++++++++++++++++++++++++
| BUFFS
|++++++++++++++++++++++++++

/if (${ChatText.Equal[virtue]}) {
   /target pc ${Sender}
   /if (${Me.CurrentMana}>1200 && ${Target.Distance}<=100 && ${Target.Name.Equal[${Sender}]}) {
      /tell ${Sender} Virtue inc
      /call cast "virtue" gem1 10s
   }
}
/return

Sub Event_BC(Line, Sender, Text)
   /call Event_Chat "BC" "${Sender}" "${Text}"
/return

|++++++++++++++++++++++++++++++++
| rezinc
|+++++++++++++++++++++++++++++++++
sub event_rezinc
   /call wait4rez
/return


|+++++++++++++++++++++++++++++++++
| Death.
|+++++++++++++++++++++++++++++++++
Sub Death
   :Zone_Loop
   /consent Your_Name_Here
   /delay 20
   /if (${Me.State.Equal[Stand]}) /sit
/return

|+++++++++++++++++++++++++++++++++
| Wait 4 Rez
|+++++++++++++++++++++++++++++++++
Sub Wait4Rez
   :waitforrez
   /if (!${Window[ConfirmationDialogBox].Open}) {
      /delay 5s ${Window[ConfirmationDialogBox].Open}
      /goto :waitforrez
   }
   /if (${Window[ConfirmationDialogBox].Open}) /notify ConfirmationDialogBox Yes_Button leftmouseup
   :zonein
   /delay 5
   /squelch /target ${Me}'s
   /delay 5
   /if (${Target.CleanName.NotEqual[${Me}'s corpse]}) /goto :zonein
   /if (${Target.CleanName.Equal[${Me}'s corpse]}) {
      /delay 3s
      /call Loot_Corpse
   } else /goto :zonein
/return

|+++++++++++++++++++++++++++++++++
| AutoLoot.
|+++++++++++++++++++++++++++++++++

Sub Loot_Corpse
   /declare LootTotal int local 0
   /declare LootSlot int local
   /squelch /target ${Me}'s
   /if (${Target.CleanName.NotEqual[${Me}'s corpse]} || !${Target.ID}) {
      /echo ** Can't target my corpse.
      /return
   }
   /corpse
   /delay 1s
   /loot
   /delay 1s
   /if (${Me.State.NotEqual[BIND]}) {
      /echo ** Massive lag right now... Aborting looting.
      /return
   }
   :LootLag
   /if (${LootTotal}!=${Corpse.Items}) {
      /varset LootTotal ${Corpse.Items}
      /delay 5
      /goto :LootLag
   }
   /for LootSlot 1 to ${LootTotal}
   :LootItem
   /itemnotify loot${LootSlot} rightmouseup
   /delay 5
   /if (${Corpse.Item[${LootSlot}].ID}) {
      /delay 5
      /goto :LootItem
   }
   /next LootSlot
   /delay 5
   /echo ** Done looting my corpse.
   /notify LootWnd DoneButton leftmouseup
/return

+++++++++++++++++++++++++++++
| Auto Accept Group Invites
+++++++++++++++++++++++++++++

Sub Event_Invited
   /echo Got invited and accepting
   /invite
/return
Fri Jan 20, 2017 9:58 am
I'm not in front of the game and I'm rusty so this may not be right, try testing it with an /echo in game. Something like this though:

/if (${Me.Class.Name.NotEqual[Cleric]}) /return

/echo the variable from your cleric and from a non-cleric to make sure the syntax is right:

/echo ${Me.Class.Name.NotEqual[Cleric]}

It should say FALSE on your cleric and TRUE on a non cleric if it's right. For the trade accept thing, look to your resurrection code in the macro as an example. It would function very similar. The Rez code basically checks to see if the Rez window is open and then clicks the yes button if it is.
Last edited by Maudigan on Fri Jan 20, 2017 3:58 pm; edited 2 times in total
Fri Jan 20, 2017 3:52 pm
Project Lead
http://www.macroquest2.com/includes/wassup/manual.php#tlowindow

Check that out. It's the documentation on the Window TLO, also read about the /window command. It'll help identify the window names. I'm not 100% sure but you might be able to derive the window/button names from looking at the EQ user interface XML files... not positive on that but it would make a lot of sense, you could confirm it with the Rez window/button name first since you know them already.
Fri Jan 20, 2017 3:55 pm
Project Lead
Public Macros Help withs Greenmachine
Reply