WoW:API TurnOrActionStart: Difference between revisions

m
Move page script moved page API TurnOrActionStart to WoW:API TurnOrActionStart without leaving a redirect
mNo edit summary
m (Move page script moved page API TurnOrActionStart to WoW:API TurnOrActionStart without leaving a redirect)
 
(4 intermediate revisions by 4 users not shown)
Line 1: Line 1:
This is triggered by pressing down on the right mousebutton.  If keystate down is true of that button then this fires.  Anything contained within this function will then also fire.
{{wowapi}}
{{protectedapi|1.10|}}
Begin "Right click" in the 3D game world.


Additions can be made to this functions via temporary override, as follows ...
TurnOrActionStart()
== Parameters ==
=== Arguments ===
:()


function AddOn_OnLoad()
=== Returns ===
Override_TurnOrActionStart=TurnOrActionStart
:''nil''
TurnOrActionStart=Override
end


function Override()
[Do stuff.]
Override_TurnOrActionStart(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9)
end


So we could add the notice; "Right mouse button is down!" into the function.
== Details ==
: This function is called when right clicking in the 3D world.


function Override()
: Calling this function clears the "mouseover" unit.
DEFAULT_CHAT_FRAME:AddMessage("Right mouse button is down!")
Override_TurnOrActionStart(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9)
end


[[Category:API Functions|TurnOrActionStart]]
: If you hook this function be sure to grab UnitName("mouseover") or target the "mouseover" unit because once the original function is called, the "mouseover" will not have a value.
[[Category:API Action Functions|TurnOrActionStart]]
 
[[Category:API Movement Functions|TurnOrActionStart]]
: When used alone, puts you into a "mouseturn" mode until [[API TurnOrActionStop|TurnOrActionStop]] is called.
 
: IMPORTANT: The normal restrictions regarding hardware event initiations still apply to anything this function might do.
__NOTOC__
Anonymous user