hey everyone, Im trying to make a mod that automatically toggles the hunter pet abilities "Growl" and "Cower" on entering a PvP battle.
Code:
if (event == "PLAYER_REGEN_DISABLED") then
if (UnitIsPlayer("target")) then
if (name == "Growl") and (autoCastEnabled) then
TogglePetAutocast(DunnoWhatGoesHere);
end
end
end
that's about all I have...
and I tried adding the following code to Rauen's PetDefend because he had a premade toggle function that already worked but my code didnt work I guess....
Code:
-- Toggle Growl On PvP Enter
if (event == "PLAYER_REGEN_DISABLED") then
if (UnitIsPlayer("target")) then
PetDefend_Config.Growl = false;
else
PetDefend_Config.Growl = true;
end
end
so anyway, I would like it very much if somone could help me out here, I perfer to start from stratch but if u get Rauen's premade toggle thing to work Im cool with that too.
Thanks