GamepadButton object
GamepadButton objects describe the state of a button on the gamepad device. Use the buttons property to retrieve an array of GamepadButton objects representing the buttons supported by the Gamepad device.
Syntax
var aButtons = gamepad.buttons;
DOM Information
Inheritance Hierarchy
The GamepadButton does not inherit from any class or interface.Members
The GamepadButton object has these types of members:
Properties
The GamepadButton object has these properties.
| Property | Access type | Description |
|---|---|---|
|
Read-only |
Indicates whether a gamepad button is pressed. | |
|
Read-only |
The touched property returns the touched state of a button. | |
|
Read-only |
Returns a numeric value representing the state of the button. |
Show: