Humanoid Control for Unity v4
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Events | List of all members
Passer.ControllerSide Class Reference

Description

Controller input for the left or right side of the controller (pair)

Public Member Functions

delegate void OnButtonDown (Controller.Button buttonNr)
 Function for processing button down events.
 
delegate void OnButtonUp (Controller.Button buttonNr)
 Function for processing button up events.
 
void Update ()
 Update the current values of the controller input.
 
void Clear ()
 Reset the values of all buttons.
 
bool GetButton (Controller.Button buttonID)
 Retrieve the pressed state of a button.
 

Public Attributes

float stickHorizontal
 The vertical value of the thumbstick.
 
float stickVertical
 The horizontal value of the thumbstick.
 
bool stickButton
 The pressed state of the thumbstick.
 
bool stickTouch
 The touched state of the thumbstick.
 
float touchpadVertical
 The vertical value of the touchpad.
 
float touchpadHorizontal
 The horizontal value of the touchpad.
 
bool touchpadPress
 The pressed state of the touchpad.
 
bool touchpadTouch
 The touched state of the touchpad.
 
bool[] buttons = new bool[4]
 The pressed state of genertic buttons.
 
float trigger1
 The value of the first trigger.
 
float trigger2
 The value of the second trigger.
 
bool option
 The pressed state of the option button.
 

Events

OnButtonDown OnButtonDownEvent
 Event for handling Button down events.
 
OnButtonUp OnButtonUpEvent
 Event for handling Button up events.
 

Member Function Documentation

◆ OnButtonDown()

delegate void Passer.ControllerSide.OnButtonDown ( Controller.Button  buttonNr)

Function for processing button down events.

Parameters
buttonNrThe idetification of the pressed button

◆ OnButtonUp()

delegate void Passer.ControllerSide.OnButtonUp ( Controller.Button  buttonNr)

Function for processing button up events.

Parameters
buttonNrThe identification of the released button

◆ GetButton()

bool Passer.ControllerSide.GetButton ( Controller::Button  buttonID)

Retrieve the pressed state of a button.

Parameters
buttonIDThe identification of the requested button

Member Data Documentation

◆ stickHorizontal

float Passer.ControllerSide.stickHorizontal

The vertical value of the thumbstick.

Values: -1..1

◆ stickVertical

float Passer.ControllerSide.stickVertical

The horizontal value of the thumbstick.

Values: -1..1

◆ touchpadVertical

float Passer.ControllerSide.touchpadVertical

The vertical value of the touchpad.

Values: -1..1

◆ touchpadHorizontal

float Passer.ControllerSide.touchpadHorizontal

The horizontal value of the touchpad.

Values: -1..1

◆ buttons

bool [] Passer.ControllerSide.buttons = new bool[4]

The pressed state of genertic buttons.

There can be up to 4 generic buttons. buttons[0] usually mathes the default fire button

◆ trigger1

float Passer.ControllerSide.trigger1

The value of the first trigger.

Values: 0..1 The first trigger is normally operated with the index finger

◆ trigger2

float Passer.ControllerSide.trigger2

The value of the second trigger.

Values: 0..1 The second trigger is normally operated with the middle finger

◆ option

bool Passer.ControllerSide.option

The pressed state of the option button.

The option button is usually a special button for accessing a specific menu


The documentation for this class was generated from the following file: