public class GamePad
extends java.lang.Object
Constructor and Description |
---|
GamePad() |
Modifier and Type | Method and Description |
---|---|
static GamePadCapabilities |
GetCapabilities(PlayerIndex playerIndex)
Retrieves the capabilities of an Xbox 360 Controller.
|
static GamePadState |
GetState(PlayerIndex playerIndex)
Gets the current state of an Xbox 360 Controller.
|
static GamePadState |
GetState(PlayerIndex playerIndex,
GamePadDeadZone deadZoneMode)
Gets the current state of an Xbox 360 Controller, using a specified dead zone on analog stick positions.
|
static boolean |
SetVibration(PlayerIndex playerIndex,
float leftMotor,
float rightMotor)
Sets the vibration motor speeds on an Xbox 360 Controller.
|
public static GamePadCapabilities GetCapabilities(PlayerIndex playerIndex)
playerIndex
- Index of the controller to query.public static GamePadState GetState(PlayerIndex playerIndex)
playerIndex
- Player index for the controller you want to query.public static GamePadState GetState(PlayerIndex playerIndex, GamePadDeadZone deadZoneMode)
playerIndex
- Player index for the controller you want to query.deadZoneMode
- Enumerated value that specifies what dead zone type to use.public static boolean SetVibration(PlayerIndex playerIndex, float leftMotor, float rightMotor)
playerIndex
- Player index that identifies the controller to set.leftMotor
- The speed of the left motor, between 0.0 and 1.0. This motor is a low-frequency motor.rightMotor
- The speed of the right motor, between 0.0 and 1.0. This motor is a high-frequency motor.