gameplate - v2.2.0
    Preparing search index...

    Interface PointerState

    A normalized pointer event (mouse, pen, touch — same shape).

    Coordinates are target-relative when a HTMLElement target is passed (using getBoundingClientRect()); otherwise they're page coordinates.

    interface PointerState {
        x: number;
        y: number;
        dx: number;
        dy: number;
        isDown: boolean;
        event: PointerEvent;
    }
    Index

    Properties

    Properties

    x: number

    Pointer X, in target-local CSS pixels.

    y: number

    Pointer Y, in target-local CSS pixels.

    dx: number

    Distance since the previous event on the X axis.

    dy: number

    Distance since the previous event on the Y axis.

    isDown: boolean

    Whether the primary button is currently pressed.

    event: PointerEvent

    The underlying DOM event, if you need it.