Skip to main content

Interface: GamepadInputOptions

Defined in: src/interaction/GamepadInput.ts:168

Options for a GamepadInput.

Properties​

autoEnable?​

optional autoEnable: boolean

Defined in: src/interaction/GamepadInput.ts:183

Attach the connection listeners immediately on construction. Set false to attach later with GamepadInput.enable. Default true.


deadzone?​

optional deadzone: number

Defined in: src/interaction/GamepadInput.ts:178

Stick deadzone in [0, 1]. An axis whose magnitude is below this reads as 0, so a resting stick does not drift. Default 0.1.


gamepadIndex?​

optional gamepadIndex: number

Defined in: src/interaction/GamepadInput.ts:173

Which pad slot to read. By default the first connected pad in the snapshot is used, so a single controller just works.