Provides access to Wand inputs More...
Public Types | |
enum class | WandButton : UInt32 { T5 = 1 << 0 , One = 1 << 1 , Two = 1 << 2 , Three = 1 << 7 , Y = 1 << 3 , B = 1 << 4 , A = 1 << 5 , X = 1 << 6 , System = T5 , Z = Three } |
Static Public Member Functions | |
static bool | GetButton (WandButton button, ControllerIndex controllerIndex=ControllerIndex.Right, PlayerIndex playerIndex=PlayerIndex.One) |
Whether the indicated wand button is currently being pressed. More... | |
static bool | TryGetButton (WandButton button, out bool pressed, ControllerIndex controllerIndex=ControllerIndex.Right, PlayerIndex playerIndex=PlayerIndex.One) |
Whether the indicated wand button is currently being pressed. Fails if the wand is unavailable. More... | |
static bool | GetButtonDown (WandButton button, ControllerIndex controllerIndex=ControllerIndex.Right, PlayerIndex playerIndex=PlayerIndex.One) |
Whether the indicated wand button was pressed during this frame. More... | |
static bool | TryGetButtonDown (WandButton button, out bool buttonDown, ControllerIndex controllerIndex=ControllerIndex.Right, PlayerIndex playerIndex=PlayerIndex.One) |
Whether the indicated wand button was pressed during this frame. Fails if the wand is unavailable. More... | |
static bool | GetButtonUp (WandButton button, ControllerIndex controllerIndex=ControllerIndex.Right, PlayerIndex playerIndex=PlayerIndex.One) |
Whether the indicated wand button was released during this frame. More... | |
static bool | TryGetButtonUp (WandButton button, out bool buttonUp, ControllerIndex controllerIndex=ControllerIndex.Right, PlayerIndex playerIndex=PlayerIndex.One) |
Whether the indicated wand button was released during this frame. Fails if the wand is unavailable. More... | |
static Vector2 | GetStickTilt (ControllerIndex controllerIndex=ControllerIndex.Right, PlayerIndex playerIndex=PlayerIndex.One) |
Gets the direction and magnitude of the stick's tilt for the indicated wand. More... | |
static bool | TryGetStickTilt (out Vector2 stickTilt, ControllerIndex controllerIndex=ControllerIndex.Right, PlayerIndex playerIndex=PlayerIndex.One) |
Gets the direction and magnitude of the stick's tilt for the indicated wand. Fails if the wand is unavailable. More... | |
static float | GetTrigger (ControllerIndex controllerIndex=ControllerIndex.Right, PlayerIndex playerIndex=PlayerIndex.One) |
Gets the degree to which the trigger is depressed, from 0.0 (released) to 1.0 (fully depressed). More... | |
static bool | TryGetTrigger (out float triggerDisplacement, ControllerIndex controllerIndex=ControllerIndex.Right, PlayerIndex playerIndex=PlayerIndex.One) |
Gets the degree to which the trigger is depressed, from 0.0 (released) to 1.0 (fully depressed). Fails if the wand is unavailable. More... | |
static bool | GetWandAvailability (ControllerIndex controllerIndex=ControllerIndex.Right) |
Gets the connection status of the indicated wand. More... | |
static void | Update () |
Static Private Member Functions | |
static | Input () |
|
strong |
|
staticprivate |
|
static |
Whether the indicated wand button is currently being pressed.
button | The wand button to check. |
controllerIndex | Unless specified, the state of the right-hand wand is returned. |
If the wand is unavailable, this function returns a default value of false.
playerIndex | The index of the player using the wand we want to query. |
Definition at line 74 of file Input.cs.
References TiltFive.Input.TryGetButton().
|
static |
Whether the indicated wand button was pressed during this frame.
button | The wand button to check. |
controllerIndex | Unless specified, the state of the right-hand wand is returned. |
playerIndex | The index of the player using the wand we want to query. |
If the wand is unavailable, this function returns a default value of false.
Definition at line 109 of file Input.cs.
References TiltFive.Input.TryGetButtonDown().
|
static |
Whether the indicated wand button was released during this frame.
button | The wand button to check. |
controllerIndex | Unless specified, the state of the right-hand wand is returned. |
playerIndex | The index of the player using the wand we want to query. |
Definition at line 144 of file Input.cs.
References TiltFive.Input.TryGetButtonUp().
|
static |
Gets the direction and magnitude of the stick's tilt for the indicated wand.
controllerIndex | Unless specified, the state of the right-hand wand joystick is used. |
playerIndex | The index of the player using the wand we want to query. |
Definition at line 180 of file Input.cs.
References TiltFive.Input.TryGetStickTilt().
|
static |
Gets the degree to which the trigger is depressed, from 0.0 (released) to 1.0 (fully depressed).
controllerIndex | Unless specified, the state of the right-hand wand trigger is used. |
playerIndex | The index of the player using the wand we want to query. |
Definition at line 214 of file Input.cs.
References TiltFive.Input.TryGetTrigger().
|
static |
Gets the connection status of the indicated wand.
controllerIndex | Unless specified, the right-hand wand is queried. |
Definition at line 247 of file Input.cs.
References TiltFive.Wand.TryCheckConnected().
|
static |
Whether the indicated wand button is currently being pressed. Fails if the wand is unavailable.
button | The wand button to check. |
pressed | |
controllerIndex | Unless specified, the state of the right-hand wand is returned. |
playerIndex | The index of the player using the wand we want to query. |
If the wand is unavailable, this function returns false and pressed is set to a default value of false.
Definition at line 89 of file Input.cs.
Referenced by TiltFive.Input.GetButton().
|
static |
Whether the indicated wand button was pressed during this frame. Fails if the wand is unavailable.
button | The wand button to check. |
buttonDown | Whether the button was pressed during this frame. |
controllerIndex | Unless specified, the state of the right-hand wand is returned. |
playerIndex | The index of the player using the wand we want to query. |
If the wand is unavailable, this function returns false and buttonDown is given a default value of false.
Definition at line 124 of file Input.cs.
Referenced by TiltFive.Input.GetButtonDown().
|
static |
Whether the indicated wand button was released during this frame. Fails if the wand is unavailable.
button | The wand button to check. |
buttonUp | Whether the button was released during this frame. |
controllerIndex | Unless specified, the state of the right-hand wand is returned. |
playerIndex | The index of the player using the wand we want to query. |
If the wand is unavailable, this function returns false and buttonUp is set to the return value of GetButtonUp(WandButton, WandTarget) GetButtonUp.
Definition at line 160 of file Input.cs.
Referenced by TiltFive.Input.GetButtonUp().
|
static |
Gets the direction and magnitude of the stick's tilt for the indicated wand. Fails if the wand is unavailable.
stickTilt | A vector representing the direction and magnitude of the stick's tilt. |
controllerIndex | Unless specified, the state of the right-hand wand joystick is used. |
playerIndex | The index of the player using the wand we want to query. |
Definition at line 196 of file Input.cs.
Referenced by TiltFive.Input.GetStickTilt().
|
static |
Gets the degree to which the trigger is depressed, from 0.0 (released) to 1.0 (fully depressed). Fails if the wand is unavailable.
triggerDisplacement | A float representing how much the trigger has depressed by the user, from 0.0 (released) to 1.0 (fully depressed). |
controllerIndex | Unless specified, the state of the right-hand wand trigger is used. |
playerIndex | The index of the player using the wand we want to query. |
Definition at line 231 of file Input.cs.
Referenced by TiltFive.Input.GetTrigger().
|
static |