A unified method for using controller input.
ControllerInput can be used to access the state and change of input buttons, touchpads and thumbsticks on any kind of input controller including game controllers and VR/XR controllers.
- Finger Movements
- Game Controller
%Controllers
You can assign controller buttons to certain functions. Controller input is split into a left and right side. For some controllers, this corresponds to the left or right controller (e.g. SteamVR or Oculus Touch controllers). For game controllers like the Xbox controller, this corresponds to the left and right side of the gamepad. Event input is using an EventHandler to define its behaviour.
Inherits MonoBehaviour.
|
float | leftStickVertical [get] |
|
float | leftStickHorizontal [get] |
|
bool | leftStickPressed [get] |
|
float | leftTouchpadVertical [get] |
|
float | leftTouchpadHorizontal [get] |
|
bool | leftTouchpadPressed [get] |
|
float | leftTrigger1 [get] |
|
bool | leftTrigger1Touched [get] |
|
bool | leftTrigger1Pressed [get] |
|
float | leftTrigger2 [get] |
|
bool | leftTrigger2Touched [get] |
|
bool | leftTrigger2Pressed [get] |
|
bool | leftButton1Pressed [get] |
|
bool | leftButton2Pressed [get] |
|
bool | leftButton3Pressed [get] |
|
bool | leftButton4Pressed [get] |
|
bool | leftOptionPressed [get] |
|
float | rightStickVertical [get] |
|
float | rightStickHorizontal [get] |
|
bool | rightStickPressed [get] |
|
float | rightTouchpadVertical [get] |
|
float | rightTouchpadHorizontal [get] |
|
bool | rightTouchpadPressed [get] |
|
float | rightTrigger1 [get] |
|
bool | rightTrigger1Touched [get] |
|
bool | rightTrigger1Pressed [get] |
|
float | rightTrigger2 [get] |
|
bool | rightTrigger2Touched [get] |
|
bool | rightTrigger2Pressed [get] |
|
bool | rightButton1Pressed [get] |
|
bool | rightButton2Pressed [get] |
|
bool | rightButton3Pressed [get] |
|
bool | rightButton4Pressed [get] |
|
bool | rightOptionPressed [get] |
|