Skip to content
ClassInput & Controls@public

FlxGamepadManager ​

Fixed-step Web Gamepad poller with reconnect-stable logical IDs.

ts
export declare class FlxGamepadManager

Constructors ​

ts
constructor(provider?: FlxGamepadProvider)

Constructs a new instance of the FlxGamepadManager class

ParameterTypeDescription
providerFlxGamepadProvider-

Properties ​

PropertyModifiersTypeDescription
connectedreadonlyreadonly FlxGamepad[]-
firstActivereadonlyFlxGamepad | null-

Methods ​

destroy() ​

ts
destroy(): void

Returns: void

getByID() ​

ts
getByID(uid: number): FlxGamepad | null

Parameters:

ParameterTypeDescription
uidnumber-

Returns: FlxGamepad | null

getByIndex() ​

ts
getByIndex(index: number): FlxGamepad | null

Parameters:

ParameterTypeDescription
indexnumber-

Returns: FlxGamepad | null

playback() ​

ts
playback(records: readonly FlxGamepadFrameRecord[]): void

Parameters:

ParameterTypeDescription
recordsreadonly FlxGamepadFrameRecord[]-

Returns: void

record() ​

ts
record(): FlxGamepadFrameRecord[]

Returns: FlxGamepadFrameRecord[]

reset() ​

ts
reset(): void

Returns: void

update() ​

ts
update(): void

Returns: void

Released under the MIT License.