i want to recreate the hunter aspect bar for wod using custom buttons based on SecureActionButtonTemplate
currently i'm using this to cast a spell on left click and cancel the aura on rightclick:
Lua Code:
button:SetAttribute("type", "spell");
button:SetAttribute("spell", spellId);
button:SetAttribute("type2", "cancelaura");
button:SetAttribute("unit2", "player");
button:SetAttribute("spell2", spellName);
button:RegisterForClicks("AnyUp");
is there a way to change the behavior of my buttons to act more like the real stancebar, that means left click should cancel the aura if it is already active and casts it if not?