Documentation
    Preparing search index...

    Interface MockGamepadState

    In-memory state of the gamepad mock.

    interface MockGamepadState {
        available: boolean;
        focusedWindow: string | null;
        pads: (MockGamepadPad | null)[];
        reason?: "unavailable" | "blocked";
        subscribers: Map<string, string | undefined>;
        ticks: number;
        timer?: () => void;
    }
    Index

    Properties

    available: boolean

    Whether the runtime can read controllers.

    focusedWindow: string | null

    Window holding input focus.

    pads: (MockGamepadPad | null)[]

    Physical slots as read by the runtime's single native reader.

    reason?: "unavailable" | "blocked"

    Unavailability reason.

    subscribers: Map<string, string | undefined>

    Subscribed windows → last delivered snapshot signature.

    ticks: number

    Idle-loop tick counter.

    timer?: () => void

    Cancel function of the autoplay loop.