View Single Post
01-23-18, 06:03 AM   #9
kurapica.igas
A Chromatic Dragonspawn
Join Date: Aug 2011
Posts: 152
For the right-click on pet action, you can use macro type for the right-click. Well, no harm to click the original pet action button.
Lua Code:
  1. self:SetAttribute("type2", "macro")
  2. self:SetAttribute("macrotext2", "/click PetActionButton".. target .. " RightButton")

It's a little difficult to figure out the action page, I use three steps to figure it out:

1. Use SetFrameRef to register the MainMenuBarArtFrame and OverrideActionBar to your secure frame, so we can get some action page securely during combat:
ActionHandler.lua#L147-L148

2. Register state for conditions like stanceActionHandler.lua#L151-L188

3. At last, the secure snippet to get the real action page based on the state and the MainMenuBarArtFrame or OverrideActionBar ActionHandler.lua#L94-L117
  Reply With Quote