Skip to content

textmode.js / Textmodifier / gamepadAxisChanged

Method: gamepadAxisChanged()

ts
gamepadAxisChanged(callback): void;

Register the single-callback handler for meaningful gamepad axis changes.

Axis callbacks are derived from per-frame polling, not native DOM events. For continuous stick or trigger state, polling Textmodifier.gamepads inside draw() is often the simpler choice; use this callback when you specifically want change notifications.

Parameters

ParameterTypeDescription
callbackGamepadAxisEventHandlerHandler to run with gamepad axis data when an axis changes.

Returns

void

Example