ProtoFlux:Index Controller

From Resonite Wiki
Revision as of 16:32, 17 April 2024 by AmasterAmaster (talk | contribs) (Added missing joystick output descriptions.)

This article or section is a Stub. You can help the Resonite Wiki by expanding it.


Index Controller
User
IsActive
Node
Type
BatteryLevel
BatteryCharging
ButtonA
ButtonB
ButtonA_Touch
ButtonB_Touch
Grip
GripTouch
GripClick
Joystick
JoystickTouch
JoystickClick
Trigger
TriggerTouch
TriggerClick
Touchpad
TouchpadTouch
TouchpadPress
TouchpadForce
Controllers

This node provides information provided by Index controllers.


Usage

IsActive (Bool)

Bool for showing if the device is active. Useful for troubleshooting if your controller is not responding.

Type (Type)

BatteryLevel (Float)

Shows the battery level of the device from 1 to 0.

BatteryCharging (Bool)

Shows if the battery is currently charging.

ButtonA (Bool)

Shows if the A button is being pressed.

ButtonB (Bool)

Shows if the B button is being pressed.

ButtonA_Touch (Bool)

Shows if the capacitive touch is being pressed on A button.

ButtonB_Touch (Bool)

Shows if the capacitive touch is being pressed on B button.

Grip (Float)

Shows the strength of the grip on the device.

GripTouch (Bool)

Shows if the grip is being touched.

GripClick (Bool)

Shows if the grip is being gripped enough to trigger a grab action.

Joystick (Float2)

The position of this controller's joystick.

JoystickTouch (Bool)

Is the controller's joystick being touched right now.

JoystickClick (Bool)

Is the controller's joystick clicked down right now.

Trigger (Float)

Shows the strength of the trigger while pressed.

TriggerTouch (Bool)

Shows if the trigger is being touched.

TriggerClick (Bool)

Shows if the trigger is pushed enough to trigger a click action.

Touchpad (Float2)

Shows the X and Y of the area where the Touchpad is touched.

TouchpadTouch (Bool)

Shows if the touchpad being touched.

TouchpadForce (Float)

Shows the strength of the touch on the touchpad.

Examples

Driving a blendshape with a button press

Controller nodes are commonly used to create gesture systems, where pressing a button or combination of buttons can control a blendshape, which usually are 'emotes' on avatars with custom facial expressions.

  • To define whose controller will be used in the node, you must input the User. Using the Get Active User Self node will ensure that it will always be the user of the avatar, if the flux is packed under the avatar.
  • The node input also must be input which can be Left or Right.
  • While many of the outputs are Bool, they can be easily changed to Float type by using a ZeroOne node to translate the bool to a float.
  • Getting the drive node from a blendshape, we can use that to connect to the ZeroOne node, which will 'drive' the blendshape from 0 to 1 while the button is held.

There is more detailed information on how to do this on the Gestures page.

This is an example circuit of using an A button press to control a blendshape.