Added in inputs and output descriptions. |
TheAutopilot (talk | contribs) No edit summary |
||
Line 28: | Line 28: | ||
== Usage == | == Usage == | ||
The standard controller node allows one to interact with the players virtual reality controller. | |||
Say you want to get the user's grip and trigger strength, just feed it a user and a "Chirality input" for the left or right controller and volla! | |||
Just pull an output from the grip boolean and the strength float value and now you have the users grip and trigger on/off and strength! | |||
== Examples == | == Examples == | ||
Line 40: | Line 40: | ||
=== User ([[User]]) === | === User ([[User]]) === | ||
The user | The user to get controller information from. | ||
=== Node ([[Type:Chirality|Chirality]]) === | === Node ([[Type:Chirality|Chirality]]) === | ||
Line 54: | Line 54: | ||
=== Type ([[Type:Type|Type]]) === | === Type ([[Type:Type|Type]]) === | ||
The controller type being used. | The controller type being used. (a subtype of [[Type:IStandardController|IStandardController]] | ||
=== BatteryLevel ([[Type:float|float]]) === | === BatteryLevel ([[Type:float|float]]) === | ||
The battery level of this controller. | The battery level of this controller. (<code>1</code>: full, <code>0</code>: empty) | ||
=== IsBatteryCharging ([[Type:bool|bool]]) === | === IsBatteryCharging ([[Type:bool|bool]]) === | ||
Line 72: | Line 72: | ||
Is secondary pressed right now. | Is secondary pressed right now. | ||
=== Grab ([[Type: | === Grab ([[Type:bool|bool]]) === | ||
Is the controller's grip button pressed right now. | Is the controller's grip button pressed right now. | ||
Line 82: | Line 82: | ||
=== Strength ([[Type:float|float]]) === | === Strength ([[Type:float|float]]) === | ||
How much the trigger is pressed currently. | How much the trigger is pressed currently. (from <code>0</code> to <code>1</code>) | ||
=== Axis ([[Type:float2|float2]]) === | === Axis ([[Type:float2|float2]]) === | ||
The position of this controller's joystick. | The position of this controller's joystick or touchpad depending on controller type. (<code>[-1; -1]</code>: bottom left, <code>[+1; +1]</code>: top right, <code>[0; 0]</code> for touchpads that are untouched) | ||
[[ProtoFlux:Index Controller|Index Controllers]] have both types of input. <code>Axis</code> returns the touchpad position. | |||
[[Category:ProtoFlux:Devices:Controllers]] | [[Category:ProtoFlux:Devices:Controllers]] |
Revision as of 21:50, 14 May 2024
This article or section is a Stub. You can help the Resonite Wiki by expanding it.
This node provides information for generic controllers.
Usage
The standard controller node allows one to interact with the players virtual reality controller.
Say you want to get the user's grip and trigger strength, just feed it a user and a "Chirality input" for the left or right controller and volla!
Just pull an output from the grip boolean and the strength float value and now you have the users grip and trigger on/off and strength!
Examples
Inputs
User (User)
The user to get controller information from.
Node (Chirality)
The controller side to get information from.
Outputs
IsActive (bool)
Is this controller actively being used right now.
Type (Type)
The controller type being used. (a subtype of IStandardController
BatteryLevel (float)
The battery level of this controller. (1
: full, 0
: empty)
IsBatteryCharging (bool)
Is this controller currently charging.
Primary (bool)
Is primary pressed right now.
Secondary (bool)
Is secondary pressed right now.
Grab (bool)
Is the controller's grip button pressed right now.
Menu (bool)
Is the menu button being pressed right now.
Strength (float)
How much the trigger is pressed currently. (from 0
to 1
)
Axis (float2)
The position of this controller's joystick or touchpad depending on controller type. ([-1; -1]
: bottom left, [+1; +1]
: top right, [0; 0]
for touchpads that are untouched)
Index Controllers have both types of input. Axis
returns the touchpad position.