Mage pet-toys summoner

Post your completed (working) macros here. Only for macros using MQ2Data syntax!

Moderator: MacroQuest Developers

Rollerball
orc pawn
orc pawn
Posts: 12
Joined: Mon May 24, 2004 2:20 pm

Mage pet-toys summoner

Post by Rollerball » Mon May 24, 2004 2:32 pm

Hello, this is my first macro, hope its gonna be useful for the mages here :)

Im getting asked many times to summon pet toys and its getting annoying to mem, click, wait, click.. so i made this simple macro to do it for me.

Code: Select all

| summontoys.mac 
| Mems the spells:Blade of The Kedge,Girdle of Magi'kot and Muzzle of Mardu.
| and summons 2 sets, containing 2 Blades of The Kedge, 1 Girdle of Magi'kot and
| Muzzle of Mardu, per set.
| After it finishes casting you'll have 20 secs (can change tho if you want)
| to give the toys to the pet/person who asked for the toys.
| After 20 secs it will remem the spellset named "normal"
| again, thats what i'm using and you can change it.


Sub Main 
	/echo Meming Blade of The Kedge,Girdle of Magi'kot and Muzzle of Mardu.
	/memspell 1 "Blade of The Kedge"
	/delay 30
	/memspell 2 "Girdle of Magi'kot"
	/delay 30
	/memspell 3 "Muzzle of Mardu"
	/delay 30
	/echo Summoning 2 sets, containing 2 Blades of The Kedge, 1 Girdle of Magi'kot and
	/echo 1 Muzzle of Mardu, per set.
	/cast "Blade of The Kedge"
	/delay 33
	/if (${Me.Casting.ID}>0) /delay 10
	/delay 25
	/cast "Blade of The Kedge"
	/delay 33
	/if (${Me.Casting.ID}>0) /delay 10
	/delay 25
	/cast "Girdle of Magi'kot"
	/delay 33
	/if (${Me.Casting.ID}>0) /delay 10
	/delay 25
	/cast "Muzzle of Mardu"
	/delay 33
	/if (${Me.Casting.ID}>0) /delay 10
	/delay 25
	/cast "Blade of The Kedge"
	/delay 33
	/if (${Me.Casting.ID}>0) /delay 10
	/delay 25
	/cast "Blade of The Kedge"
	/delay 33
	/if (${Me.Casting.ID}>0) /delay 10
	/delay 25
	/cast "Girdle of Magi'kot"
	/delay 33
	/if (${Me.Casting.ID}>0) /delay 10
	/delay 25
	/cast "Muzzle of Mardu"
	/delay 33
	/if (${Me.Casting.ID}>0) /delay 10
	/delay 25
	/echo Done summoning! 20 seconds untill rememing set "normal".
	/delay 200
	/loadspells "normal"
	/echo Meming set "normal".
/endm 
It starts with meming Blade of the Kedge, Girdle of Magi'kot and Muzzle of Mardu in spell slots 1,2 and 3 and then casts them (the blade twice) two times for 2 sets of toys.

If you have ideas on how to improve it, please let me know :)

Preocts
a snow griffon
a snow griffon
Posts: 312
Joined: Thu Jan 29, 2004 1:02 pm

Post by Preocts » Mon May 24, 2004 2:52 pm

You can shorten it greatly by using the following after each /cast statement:

Code: Select all

  /delay 1m !${Me.Casting.ID}
This will delay 1 minutes or until you stop casting, which should be when the spell has completed.

But overall I like seeing this kind of thing. Gives me hope that there aren't just a bunch of power-hungry loser EQ players out there that want to be spoon fed macros that will run the game 100% for them.

Great job.

eqjoe
a grimling bloodguard
a grimling bloodguard
Posts: 984
Joined: Sat Sep 28, 2002 12:26 pm

Post by eqjoe » Mon May 24, 2004 2:53 pm

You need to add some fizzle recast, but otherwise this looks good!

-j

Drumstix42
a grimling bloodguard
a grimling bloodguard
Posts: 808
Joined: Mon May 03, 2004 4:25 pm

Post by Drumstix42 » Mon May 24, 2004 3:54 pm

:shock:
/memspell 1 "Blade of The Kedge"
/delay 30
/memspell 2 "Girdle of Magi'kot"
/delay 30
/memspell 3 "Muzzle of Mardu"
/delay 30
Do you know about SpellSets in EQ? Would probably save you tons of time :)

Drumstix42
a grimling bloodguard
a grimling bloodguard
Posts: 808
Joined: Mon May 03, 2004 4:25 pm

Post by Drumstix42 » Mon May 24, 2004 3:57 pm

/cast "Blade of The Kedge"
/delay 33
/if (${Me.Casting.ID}>0) /delay 10
/delay 25
/cast "Blade of The Kedge"
/delay 33
/if (${Me.Casting.ID}>0) /delay 10
/delay 25
/cast "Girdle of Magi'kot"
/delay 33
/if (${Me.Casting.ID}>0) /delay 10
/delay 25
/cast "Muzzle of Mardu"
/delay 33
/if (${Me.Casting.ID}>0) /delay 10
/delay 25
/cast "Blade of The Kedge"
/delay 33
/if (${Me.Casting.ID}>0) /delay 10
/delay 25
/cast "Blade of The Kedge"
/delay 33
/if (${Me.Casting.ID}>0) /delay 10
/delay 25
/cast "Girdle of Magi'kot"
/delay 33
/if (${Me.Casting.ID}>0) /delay 10
/delay 25
/cast "Muzzle of Mardu"
/delay 33
/if (${Me.Casting.ID}>0) /delay 10
/delay 25
Just another option for you. Look up SPELLCAST.INC in the Snippets section, and you can very easily cast as many spells in a row.

An example from my Beastlords buffing up spell:

Code: Select all

   /call cast "Dexterity"
   /call cast "Stamina"
   /call cast "Shifting Shield"
   /call cast "Furious Strength"
   /call cast "Talisman of Tnarg"
   /call cast "Spirit of the Storm"
Will cast each one, and cast the next one in line ASAP. Works great for me. Hope you can tweak yours to work even better as well.

Rollerball
orc pawn
orc pawn
Posts: 12
Joined: Mon May 24, 2004 2:20 pm

Post by Rollerball » Mon May 24, 2004 5:58 pm

Thanks alot for the help guys.

code right now:

Code: Select all

| summontoys.mac 
| Mems the spells:Blade of The Kedge,Girdle of Magi'kot and Muzzle of Mardu.
| and summons 2 sets, containing 2 Blades of The Kedge, 1 Girdle of Magi'kot and
| Muzzle of Mardu, per set.
| After it finishes casting you'll have 20 secs (can change tho if you want)
| to give the toys to the pet/person who asked for the toys.
| After 20 secs it will remem the spellset named "normal"
| again, thats what i'm using and you can change it. 


Sub Main 
	/echo Meming Blade of The Kedge,Girdle of Magi'kot and Muzzle of Mardu.
	/memspell 1 "Blade of The Kedge"
	/delay 30
	/memspell 2 "Girdle of Magi'kot"
	/delay 30
	/memspell 3 "Muzzle of Mardu"
	/delay 30
	/echo Summoning 2 sets, containing 2 Blades of The Kedge, 1 Girdle of Magi'kot and
	/echo 1 Muzzle of Mardu, per set.
	/cast "Blade of The Kedge"
	/delay 1m !${Me.Casting.ID}
	/delay 25
	/cast "Blade of The Kedge"
	/delay 1m !${Me.Casting.ID}
	/delay 25
	/cast "Girdle of Magi'kot"
	/delay 1m !${Me.Casting.ID}
	/delay 25
	/cast "Muzzle of Mardu"
	/delay 1m !${Me.Casting.ID}
	/delay 25
	/cast "Blade of The Kedge"
	/delay 1m !${Me.Casting.ID}
	/delay 25
	/cast "Blade of The Kedge"
	/delay 1m !${Me.Casting.ID}
	/delay 25
	/cast "Girdle of Magi'kot"
	/delay 1m !${Me.Casting.ID}
	/delay 25
	/cast "Muzzle of Mardu"
	/delay 1m !${Me.Casting.ID}
	/delay 25
	/echo Done summoning! 20 seconds untill rememing set "normal".
	/delay 200
	/loadspells "NORMAL"
	/echo Meming set "normal".
/endm 
Thanks Preocts, It made it much faster :)

About the fizzles I wasn't lucky enough to get any fizzle so I can't really tell if the "after fizzle" is working, thats why I left it out.
from other posts i saw its supposed to be like:

Code: Select all

#event Fizzle "#*#Your spell fizzles#*#"
Sub Event_Fizzle 
/cast "${Casting}" 
/return
That is correct?

About the spell sets, when I first wrote that i thought i wont use spell sets so other ppl that use it wont have to change it for their sets, but afterwards I used the "normal" set after it finished summoning so I'll put "toys summon" set or something like that after I'll be sure about the fizzles.

Chill
Contributing Member
Contributing Member
Posts: 435
Joined: Fri May 07, 2004 5:06 pm
Location: Erie, PA

Post by Chill » Mon May 24, 2004 7:14 pm

Drumstix is tryin to help you out man. Copy SpellCast.inc to your macro directory and your macro would become:

Code: Select all

|summontoys.mac
|summons 2 sets of pet gear and gives you 20 seconds to give away the gear
|usage: /macro summontoys

#include SpellCast.inc

Sub Main 
   /loadspells "PET GEAR"
   /echo Summoning 2 sets of gear.
   /call cast "Blade of The Kedge" 
   /call cast "Blade of The Kedge" 
   /call cast "Girdle of Magi'kot" 
   /call cast "Muzzle of Mardu" 

   /call cast "Blade of The Kedge" 
   /call cast "Blade of The Kedge" 
   /call cast "Girdle of Magi'kot" 
   /call cast "Muzzle of Mardu" 

   /echo Done summoning! 20 seconds untill rememing set "normal".
   /delay 200

   /loadspells "NORMAL"

/endmacro

A couple changes you may like however, you could specify the number of sets you want as a paramter, and just drop the gear into your bags (or on the ground if full) and end the macro faster. Would be something like this:

(untested)

Code: Select all

|summontoys.mac
|Casts the specified number of pet gear sets (default is 2), and drops them into your inventory.
|usage: /macro summontoys [# of sets]

#include SpellCast.inc

Sub Main 
   /declare c int local 2
   /if (${param0}) /varset c ${Int[${param0}]}

   /loadspells "PET GEAR"

   /echo Summoning ${c} sets of gear.

   /for c 1 to ${c}
      /call GearSet
   /next c

   :invloop
   /if (${Cursor.ID}) {
      /autoinventory
      /goto :invloop
   }

   /loadspells "NORMAL"

/endmacro

Sub GearSet
   /call cast "Blade of The Kedge" 
   /call cast "Blade of The Kedge" 
   /call cast "Girdle of Magi'kot" 
   /call cast "Muzzle of Mardu" 
/return
Prolly obvious above but this macro assumes that you have 2 spell sets, your "NORMAL" spell set, and a "PET GEAR" spell set containing those spells. Would prolly be easier than memming the individual spells.

One other enhancement you coud add...you could make a couple different sets of gear (if you wanted MR CR or FR procs) and make that a second param (param1). Based on its value, you could call different subs... Dont know if you have all those spells or would use that, but was a thought.
Last edited by Chill on Tue May 25, 2004 3:18 am, edited 3 times in total.

Drumstix42
a grimling bloodguard
a grimling bloodguard
Posts: 808
Joined: Mon May 03, 2004 4:25 pm

Post by Drumstix42 » Mon May 24, 2004 9:27 pm

Thanx Chill

Rollerball
orc pawn
orc pawn
Posts: 12
Joined: Mon May 24, 2004 2:20 pm

Post by Rollerball » Tue May 25, 2004 2:59 am

Oh, so sorry Drumstix42, I didn't see your second post :(
Thanks Chill, I tried to make the number of sets as parameters but I did something wrong at some point so it didnt work,I copied spellcast.inc to it my macro directory. looking foward to check yours.
Currently people mostly ask for the kedge blade but if low level characters will ask, its a good idea to make diferent kinds of sets, working on it :) .

EDIT: just tried the /call cast, and it wont open the spellbook to meme the next spell, because of items i summoned are "in my hands".
Can drop them in a bag but that wont help much, I think I'll make it mem the spell set and then cast it.

Drumstix42
a grimling bloodguard
a grimling bloodguard
Posts: 808
Joined: Mon May 03, 2004 4:25 pm

Post by Drumstix42 » Tue May 25, 2004 9:46 am

Hence my first post. Make a SPELLSET for the Summon Spells. You have a spell set for your NORMAL spells, why not making things easier on yourself :)

Rollerball
orc pawn
orc pawn
Posts: 12
Joined: Mon May 24, 2004 2:20 pm

Post by Rollerball » Tue May 25, 2004 12:05 pm

For some reason spell sets didn't work when I first tried them, seems to work now *shrug*. Thanks.
code atm:

Code: Select all

|summontoys.mac 
|Casts the specified number of pet gear sets (default is 2).
|sets: CR-2 Blade of the Kedge, FR- 2 fist of Ixiblat, MR- 2 Blades of Walnan.
|All contain Girdle of Magi'kot and Muzzle of Mardu.
|uses spell sets "MRwep","FRwep"and"CRwep" and "normal". Make if you don't have them. 
|usage: /macro summontoys [CR|FR|MR] [# of sets] 

Sub Main 
   /declare c int local
   /if (${param0}) /varset c $Int[${param0}]} 
   /declare i int local
   /if (${param0}) /varset i $int[${param0}]}  
   /if (${Param${i}.Equal[MR]}) { 
         /echo "Blade of Walnan sets inc!" 	 
   /for c 1 to ${c} 
         /goto :MRset
	:MRset
      { 
   /loadspells "MRwep"
   /delay 75
   /cast "Blade of Walnan" 
   /delay 1m !${Me.Casting.ID}
   /cast "Blade of Walnan"
   /delay 1m !${Me.Casting.ID}  
   /cast "Girdle of Magi'kot"
   /delay 1m !${Me.Casting.ID} 
   /cast "Muzzle of Mardu" 
   /delay 1m !${Me.Casting.ID}
	} 
         } 
   /if (${Param${i}.Equal[FR]}) { 
         /echo "Fist of Ixiblat sets inc!" 
	 
   /for c 1 to ${c} 
         /goto :FRset
	:FRset
      { 
   /loadspells "FRwep"
   /delay 75
   /cast "Fist of Ixiblat" 
   /delay 1m !${Me.Casting.ID}
   /cast "Fist of Ixiblat"
   /delay 1m !${Me.Casting.ID}  
   /cast "Girdle of Magi'kot"
   /delay 1m !${Me.Casting.ID} 
   /cast "Muzzle of Mardu" 
   /delay 1m !${Me.Casting.ID}
	}  
         } 
   /if (${Param${i}.Equal[CR]}) { 
         /echo "Blade of the Kedge sets inc!"	 
   /for c 1 to ${c} 
         /goto :CRset
	:CRset
      { 
   /loadspells "CRwep"
   /delay 75
   /cast "Blade of The Kedge" 
   /delay 1m !${Me.Casting.ID}
   /cast "Blade of The Kedge"
   /delay 1m !${Me.Casting.ID}  
   /cast "Girdle of Magi'kot"
   /delay 1m !${Me.Casting.ID} 
   /cast "Muzzle of Mardu" 
   /delay 1m !${Me.Casting.ID}
	} 
	
         } 
	/echo Done summoning! 10 seconds until meming "normal" set
	/delay 100
	/loadspells "normal"	
/endm
The /delay 75 after loadspells is the time that takes me to mem, I think I saw a better way like what Preocts said with casts somewhere, can't find it though :( .
Since you can still open spellbook in trade window (unless you didn't put all the items in the trade window) it will remem "normal" set after 10 secs.
Yeah I know I used "i" as int when I used words for i (CR/FR/MR) but it worked so I kept it :wink:.
I tried the "c" for sets but for some reason, as I run the macro, it mems the right spell set but only casts the first spell and only once so couldn't really see if the "c" works. (removing it didnt solve the problem either)

Preocts
a snow griffon
a snow griffon
Posts: 312
Joined: Thu Jan 29, 2004 1:02 pm

Post by Preocts » Tue May 25, 2004 12:41 pm

hmmmm. :? I'd say you jumped ahead of yourself. This is the problem I see with trying to make a macro far more complex than is needed. Anyway, there are quite of few things that you are trying to do that don't work quite in the way you intend.

Code: Select all

/for c 1 to ${c} [color=yellow]The intent is there, just the wrong use of the command[/color]
      /goto :FRset 
:FRset 
   {  [color=yellow]<--- 'Goto' labels are not block-code[/color]
/loadspells "FRwep"
[color=yellow]/delay 3m !${Window[SpellBookWnd].Open}[/color]
|Assumes you start the macro with the book closed.
/cast "Fist of Ixiblat" 
/delay 1m !${Me.Casting.ID} 
/cast "Fist of Ixiblat" 
/delay 1m !${Me.Casting.ID}  
/cast "Girdle of Magi'kot" 
/delay 1m !${Me.Casting.ID} 
/cast "Muzzle of Mardu" 
/delay 1m !${Me.Casting.ID} 
}  | <--- again, about the blockcode issue.
My version (untested)

Code: Select all


Sub Main(string sType,int nSets)
|Handle a case if the number of sets is not given. Default 1
  /if (!${Defined[nSets]}) /delcare nSets int local 1
  /declare c int local 0
|If they want MR gear
  /if (${sType.Equal[MR]}) { 
    /echo "Blade of Walnan sets inc!"     
|Load the spell set before the loop (only need to load once)
    /loadspells "MRwep" 
|Wait three minutes or until the spellbook closes (done loading)
    /delay 3m !${Window[SpellBookWnd].Open} 
|Loop 1 to the number of sets asked for. At least 1 time
    /for c 1 to ${nSets} 
|Fizzle check can be added later
      /cast "Blade of Walnan" 
      /delay 1m !${Me.Casting.ID} 
      /cast "Blade of Walnan" 
      /delay 1m !${Me.Casting.ID}  
      /cast "Girdle of Magi'kot" 
      /delay 1m !${Me.Casting.ID} 
      /cast "Muzzle of Mardu" 
      /delay 1m !${Me.Casting.ID} 
|Loop
   /next c
  } 
|Rinse and repeat for FR and CR (just a case of changing the spell names)
  /echo Done summoning! 10 seconds until meming "normal" set 
  /delay 100 
  /loadspells "normal"    
/endmacro
While SpellCast.inc does handle almost every case of failures on casting I personally find the include... just too complex for my tastes. Fizzle checking isn't hard and once you've learn some more we can touch on that.

Drumstix42
a grimling bloodguard
a grimling bloodguard
Posts: 808
Joined: Mon May 03, 2004 4:25 pm

Post by Drumstix42 » Tue May 25, 2004 3:48 pm

/smack himself

Ok I tried to help, and Chill did as well pointing out what I said. You also said yourself you weren't sure about the fizzling thing. If you use the SpellCast.inc it is done for you. Of course, I can see maybe you'd rather code it yourself.

Anyhows... for meming the spell set, you can change your /delay to look like this:

Code: Select all

/delay 75 !${Window[SpellBookWnd].Open}
And, incase you had the spellbook open before that. You could do something like this:

Code: Select all

/if (${Window[SpellBookWnd].Open}) /book
/delay 75 !${Window[SpellBookWnd].Open}
And that'll close the spellbook right before memming the spellset.

Chill
Contributing Member
Contributing Member
Posts: 435
Joined: Fri May 07, 2004 5:06 pm
Location: Erie, PA

Dont do stuff the hard way

Post by Chill » Tue May 25, 2004 5:46 pm

Okay, my very last attempt man. You are basically doing this the hard way. You are worrying about things like fizzles, interrupts, and cast times when there is a very nice include file out there that will do all of this stuff and more for you. Do yourself a favor and follow this link to look at ml2517's SpellCast.inc. If you decide you want to let it do all that crap for you, all you have to do is #include SpellCast.inc somewhere up above your Sub Main, and then replace all your /call "Spell Name" lines with /call cast "Spell Name". You can then safely get rid of all the delay crap.

Also, are you really sure you want to pause for some arbitrary time at the end of the macro while you give away the gear? Would it be easier to have it wait as long as you need until...say you target yourself? Or maybe just drop the gear into your bags (or on the ground if your bags are full)? I added 1 more paramater for these options.

I havent tested it, but I really think this is closer to what you want:

(untested)

Code: Select all

|summontoys.mac 
|Casts the specified number/type of sets pet gear (default is 2 CR sets). 
|It will then [wait] for a 10 seconds, [drop] all items into inventory, or pause until you [target] yourself. 
|Wait is the default option.  If you specify target, /target anything other than yourself before starting. 
|sets: CR-2 Blade of the Kedge, FR- 2 fist of Ixiblat, MR- 2 Blades of Walnan. 
|      All contain Girdle of Magi'kot and Muzzle of Mardu. 
|Uses the spell sets: "PET GEAR" (contains all 5 spells) and "NORMAL". 
|If you dont have these sets, make them or edit "NORMAL" and "PET GEAR" to match yours. 
|usage: /macro summontoys [# of sets] [CR|FR|MR] [wait|drop|target] 

#include SpellCast.inc 

Sub Main(int Sets, string Gear, string Wait) 

   |declare variables, set default for the weapon name
   /declare c int outer 0
   /declare weapon string outer
   /varset weapon Blade of The Kedge

   |set default values if not passed as paramaters
   /if (!${Defined[Sets]}) /varset sets 2 
   /if (!${Defined[Gear]}) /varset gear CR
   /if (!${Defined[Wait]}) /varset Wait wait

   |changes the weapon name if MR or FR specified
   /if (${Gear.Equal[MR]}) /varset weapon Blade of Walnan
   /if (${Gear.Equal[FR]}) /varset weapon Fist of Ixiblat

   |load pet gear spell set, legthen the delay if not long enough.
   /loadspells "PET GEAR" 
   /delay 10s !${Window[SpellBookWnd].Open} 

   /echo Summoning ${Sets} sets of gear. 

   |casts specified number of sets of gear, default is 2 if not given
   /for c 1 to ${Sets}
      /echo ${Weapon} set ${c} inc!
      /call cast "${Weapon}"
      /call cast "${Weapon}"
      /call cast "Girdle of Magi'kot" 
      /call cast "Muzzle of Mardu" 
   /next c 

   |pauses macro until you target yourself if [target] is specified
   /if (${Wait.Equal[target]}) { 
      /echo Done summoning! Target yourself to mem "NORMAL" spell set... 
      /if (${Target.ID}!=${Me.ID}) { 
        /delay 60m ${Target.ID}==${Me.ID} 
      }
   |drops gear into inventory if [drop] is specified
   } else /if (${Wait.Equal[drop]}) 
      /echo Done summoning! Dropping gear into invendory (or the ground if bags full)... 
      :invloop 
      /if (${Cursor.ID}) { 
         /autoinventory 
         /goto :invloop 
      }
   |waits 10 seconds after summoning gear if anything else is specified.
   } else { 
      /echo Done summoning! Memming "NORMAL" spell set in 10 seconds... 
      /delay 10s 
   } 

   /loadspells "NORMAL"
   /delay 10 !${Window[SpellBookWnd].Open}

/endmacro
Havent tested it, but that might actually work as written. If not, it should be pretty close. Good luck either way.

-Got rid of the subs and just added the pet weapon spell name in as a variable.
Last edited by Chill on Wed May 26, 2004 12:54 pm, edited 2 times in total.

Rollerball
orc pawn
orc pawn
Posts: 12
Joined: Mon May 24, 2004 2:20 pm

Post by Rollerball » Wed May 26, 2004 8:01 am

Thanks Drumstix42 wrote that down :).

Preocts your version seems to have the same problem as mine, it mems all the spells but only casts the first :(.


Chill I only got to try yours 15mins before patch :( , although when I tried it it had problems with the subs, will try after the new version will come out.

I wasn't really sure what the spellcast file does, will use it from now on :).