Companion/Pet

UI and Macro
I've noticed that there has been modifications to the summon companion macros, making it show an error that "You do not have a pet" regardless of which companion I try to summon.

I'm not sure if they've disabled the command or changed it to comply with the new pet battle feature.. but if anyone knows how to get them to work I'd appreciate some help.

Macros I've tried:
/cast PETNAME
/use PETNAME
/run CallCompanion("CRITTER",1)
None of them worked.
(Note: I am not trying to summon a random companion, but a specific one.)
They made the new pet API really macro-unfriendly.

To summon a specific pet, first you need to know its id. You can get that by opening the pet journal and with the mouse remaining over the pet you want to always summon:

/dump GetMouseFocus().petID

It will print a very large number like 123456

Then this macro will summon that pet:

/run C_PetJournal.SummonPetByID(123456)

To summon by name, make this macro:

/run local pet,p="Black Tabby Cat",C_PetJournal for i=1,p.GetNumPets(false) do local id,_,_,m,_,_,_,n=p.GetPetInfoByIndex(i) if n==pet or m==pet then p.SummonPetByID(id) return end end
If I use

09/14/2012 02:46 PMPosted by Ro
/run C_PetJournal.SummonPetByID(123456)


or

/run local pet,p="Black Tabby Cat",C_PetJournal for i=1,p.GetNumPets(false) do local id,_,_,m,_,_,_,n=p.GetPetInfoByIndex(i) if n==pet or m==pet then p.SummonPetByID(id) return end end


is there a way to use modifiers (shift, etc) to cast multiple pets from a single macro?
SecureCmdOptionParse allows you to use macro conditionals in scripts.

/run C_PetJournal.SummonPetByID(tonumber(SecureCmdOptionParse"[mod:alt]123456;[mod:ctrl]54698;67543"))

/run local pet,p=SecureCmdOptionParse"[mod:alt]Argent Squire;Black Tabby Cat",C_PetJournal for i=1,p.GetNumPets(false) do local id,_,_,m,_,_,_,n=p.GetPetInfoByIndex(i) if n==pet or m==pet then p.SummonPetByID(id) return end end

Join the Conversation

Return to Forum