Page 1 of 1
Pet attacking on enrage macro
Posted: Wed Sep 29, 2004 7:34 pm
by Lum
I'm not so great at making macros, so i figured i would see if one has been made. Search didn't ocme up with any results i wanted that i could see. Its probably put into a larger multi purpose macro but i just want a simple one.
Is it possible to make a macro, or plugin, that will read what your pet replies to /pet attack (attacking thismob, master), and watch for that name NPC to enrage near you. When the npc enrages it will command /pet back off or /pet hold.
I've watched little fluffy tear himself a new one by quadding into a boss mobs enrage before i could get to pet hold

Posted: Wed Sep 29, 2004 7:52 pm
by llama
This works for me. But no check if it is pet target that is Enraged or other mob.
Code: Select all
#Event Enrage "#*#has become ENRAGED#*#"
Sub Main
:loop
/doevents
/goto :loop
/return
Sub Event_Enrage
/echo Enrage, PET OFF.
/pet back
/pet back
/pet hold
/return
Posted: Sun Oct 03, 2004 9:56 pm
by Lum
the code from llama works, but as i wanted to avoid im having problems with other pets nearby enraging, my own pet enraging, or just mobs nearby i dont care about. It sucks when fluffy enrages, ses his own message and then backs off, getting his butt reemed before a heal lands
as i asked before is it possible to read the Text that pet says he is attacking, watch for that name of mob to enrage and that makes him back off, but not another mob nearby that i haven't told him specifically to attack? I dont need the macro to make him attack again as i dont intend to afk it

Posted: Mon Oct 04, 2004 1:59 am
by Goofmester1
Well this is close to what you want but definatly should need work since I have never used the #1# type of events I am not sure I added them right.. maybe someone can clean this up.
Code: Select all
#Event mob "#*#attacking #1#, master"
#Event Enrage "#1#has become ENRAGED#*#"
Sub Main
/declare mobname string global
:waitforevents
/doevents
/delay 1
/goto waitforevents
/return
Sub mob
/varset mobname #1#
/return
Sub Enrage
/if ${mobname} ==#1#
/pet hold
/return
Posted: Mon Oct 04, 2004 2:33 am
by Falco72
Code: Select all
#Event Mob "#*#attacking #1#, master"
#Event Enrage "#1# has become ENRAGED#*#"
#Event UnEnrage "#1# is no longer enraged#*#"
Sub Main
/declare mobname string outer
:waitforevents
/doevents
/delay 1
/goto :waitforevents
/return
Sub Event_Mob(string MobText,string AttkMobName)
/varset mobname ${AttkMobName}
/return
Sub Event_Enrage(string OnRageText,string EnRgName)
/if (!${Me.Pet.ID} /return
/if ${mobname.Equal[${EnRgName}]} {
/pet back off
/delay 2
/pet hold
}
/return
Sub Event_UnEnrage(string OffRageText,string OffRgName)
/if (!${Me.Pet.ID} /return
/if (${mobname.Equal[${OffRgName}]) {
/target npc ${mobname}
/delay 3
/pet kill
}
/return
Reworked the code so it can really works in a macro. BUT, working with enrage is a pain, you need to be enough near to the mob to ear the enrage call and your macro need not to be doing other things else the event will kick off later and your pet will be probably killed.
Posted: Mon Oct 04, 2004 10:51 am
by blueninja
You can use variables in event trigger definitions.
This would trigger if mobname was set correctly:
Code: Select all
#event enrage "|${mobname}| has become enraged."
Posted: Mon Oct 04, 2004 1:58 pm
by Lum
Thanks, ill have to try it out next time i come to something that enrages. i already know I'll have to be in range to hear enrage, I usually do if i know the mob enrages so i can TRY to protect my pet hehe