Difference between revisions of "OnButtonUp"
Jump to navigation
Jump to search
imported>Pintocat |
imported>Pintocat |
||
Line 3: | Line 3: | ||
|summary = [[Event_Handling|Event]] block type that calls the [[User_Defined_Function|UDF]] when the gamepad button is released. The released button code (int) is passed to the UDF. | |summary = [[Event_Handling|Event]] block type that calls the [[User_Defined_Function|UDF]] when the gamepad button is released. The released button code (int) is passed to the UDF. | ||
Use any Button code after the ":" delimiter. | Use any Button code after the ":" delimiter. Button code int can be a bitmask of more than one button. | ||
|name = SetEventHandler "OnButtonUp:int" | |name = SetEventHandler "OnButtonUp:int" | ||
|returnVal = buttonID | |returnVal = buttonID |
Latest revision as of 17:30, 21 March 2017
< [[::Category:Functions|Category:Functions]]
A function added by the Lutana NVSE plugin.
Description
Event block type that calls the UDF when the gamepad button is released. The released button code (int) is passed to the UDF.
Use any Button code after the ":" delimiter. Button code int can be a bitmask of more than one button.
Syntax
(buttonID:int) SetEventHandler "OnButtonUp:int" myUDF:userDefinedFunction
Example using either "A" or "B"
SetEventHandler "OnButtonUp:12288" MyUDF scn MyUDF int keyCode begin function {keyCode} end function
Example using "A" button
SetEventHandler "OnButtonUp:4096" MyUDF scn MyUDF int keyCode begin function {keyCode} end function
XBox Controller Button Codes
1 : DPAD_UP 2 : DPAD_DOWN 4 : DPAD_LEFT 8 : DPAD_RIGHT 16 : START 32 : BACK 64 : LEFT_THUMBSTICK 128 : RIGHT_THUMBSTICK 256 : LEFT_SHOULDER (LB) 512 : RIGHT_SHOULDER (RB) 1024 : XBOX_GUIDE 4096 : BUTTON_A 8192 : BUTTON_B 16384 : BUTTON_X 32768 : BUTTON_Y