TGamepadDevicesManager Class
Definition
Gamepad manager class, to use as a singleton.
type TGamepadDevicesManager = class(TInterfacedObject)
- Inheritance
-
TInterfacedObjectTGamepadDevicesManager
Constructors
Properties
| Enabled |
Start or stop the gamepad infos check loop |
| IsSupported |
Check if the gamepad API is available for this platform |
| OnGamepadAxesChange |
Called for each new value of a gamepad axe (X,Y or others) |
| OnGamepadButtonDown |
Called when a gamepad button is down (pressed) |
| OnGamepadButtonUp |
Called when a gamepad button is up (unpressed) |
| OnGamepadDirectionPadChange |
Called for each direction change from a gamepad DPAD (if available on it) |
| OnGamepadLost |
To know if a connected gamepad is disconnected from the system or powered off. |
| OnNewGamepadDetected |
Used when a new gamepad is detected (it should be connected but can be not). |
| SynchronizedEvents |
Execute events in main thread or in the thread used by the gamepad manager |
| Tag |
Tag property "in case of" not used in this class |
| TagBool |
TagBool property "in case of" not used in this class |
| TagFloat |
TagFloat property "in case of" not used in this class |
| TagObject |
TagObject property "in case of" not used in this class |
| TagString |
TagString property "in case of" not used in this class |
Methods
| ConnectedGamepadCount |
Return the connected gamepads number |
| Current | |
| DoGamepadAxesChange(Integer, TJoystickAxes, Single) | |
| DoGamepadButtonDown(Integer, TJoystickButtons) | |
| DoGamepadButtonUp(Integer, TJoystickButtons) | |
| DoGamepadDirectionPadChange(Integer, TJoystickDPad) | |
| DoLostGamepad(Integer) | |
| DoNewGamepadDetected(Integer) | |
| Execute | |
| GamepadCount |
Count the detected gamepads number (detected or declared in the OS depending on the platform) |
| GetGamepad(Integer) |
Return the gamepad data class |
| IsGamepadConnected(Integer) | |
| RegisterGamePadDevice(TGamepadDevice) | |
| RegisterGamePadManager(TDGEGamepadManager) | |
| UnRegisterGamePadDevice(TGamepadDevice) | |
| UnRegisterGamePadManager(TDGEGamepadManager) |