Event Bind ActionUploaded by nul
Apr 6th 2016, 9:27 PM
Includes two input events and three output events which allow you to trigger events when the player performs certain actions.
onActionDown - When the button is pressed. Works for all actions.
onActionUp - When the button is released. Only works for fire, jump, crouch, and jet.
playerActionBind [list] [cd] - Binds a player's action to the targeted brick(s). When the player does (or stops) that action, onActionDown/Up is triggered on that brick.
playerActionUnbind [list] - Reverses the effect of the above event.
playerActionUnbindAll - Removes every single bind the player has.
Fire, Jump, Crouch, Jet, Light, PrevSeat, NextSeat, UseTool, UnUseTool, BrickCancel, BrickDownPlate, BrickToward, BrickUpPlate, BrickLeft, BrickDown, BrickRight, BrickRotateCCW, BrickAway, BrickCW, BrickUp, BrickPlant
Note #1: These are bound to the player, not the client. So when the player respawns or dies, all binds are cleared.
Note #2: If an action has a cooldown, onActionUp will only be called if onActionDown was successfully called.