phaser - v4.0.0-rc.4
    Preparing search index...

    Type Alias InteractiveObject

    type InteractiveObject = {
        camera: Cameras.Scene2D.Camera;
        cursor: boolean | string;
        customHitArea: boolean;
        draggable: boolean;
        dragStartX: number;
        dragStartXGlobal: number;
        dragStartY: number;
        dragStartYGlobal: number;
        dragState: 0 | 1 | 2;
        dragX: number;
        dragY: number;
        dropZone: boolean;
        enabled: boolean;
        gameObject: GameObject;
        hitArea: any;
        hitAreaCallback: HitAreaCallback;
        hitAreaDebug: Shape;
        localX: number;
        localY: number;
        target: GameObject | null;
    }
    Index

    Properties

    The most recent Camera to be tested against this Interactive Object.

    cursor: boolean | string

    Should this Interactive Object change the cursor (via css) when over? (desktop only)

    customHitArea: boolean

    Was the hitArea for this Interactive Object created based on texture size (false), or a custom shape? (true)

    draggable: boolean

    Is this Interactive Object draggable? Enable with InputPlugin.setDraggable.

    dragStartX: number

    The x coordinate of the Game Object that owns this Interactive Object when the drag started.

    dragStartXGlobal: number

    The x coordinate that the Pointer started dragging this Interactive Object from.

    dragStartY: number

    The y coordinate of the Game Object that owns this Interactive Object when the drag started.

    dragStartYGlobal: number

    The y coordinate that the Pointer started dragging this Interactive Object from.

    dragState: 0 | 1 | 2

    The current drag state of this Interactive Object. 0 = Not being dragged, 1 = being checked for drag, or 2 = being actively dragged.

    dragX: number

    The x coordinate that this Interactive Object is currently being dragged to.

    dragY: number

    The y coordinate that this Interactive Object is currently being dragged to.

    dropZone: boolean

    Is this Interactive Object a drag-targets drop zone? Set when the object is created.

    enabled: boolean

    Is this Interactive Object currently enabled for input events?

    gameObject: GameObject

    The Game Object to which this Interactive Object is bound.

    hitArea: any

    The hit area for this Interactive Object. Typically a geometry shape, like a Rectangle or Circle.

    hitAreaCallback: HitAreaCallback

    The 'contains' check callback that the hit area shape will use for all hit tests.

    hitAreaDebug: Shape

    If this Interactive Object has been enabled for debug, via InputPlugin.enableDebug then this property holds its debug shape.

    localX: number

    The x coordinate that the Pointer interacted with this object on, relative to the Game Object's top-left position.

    localY: number

    The y coordinate that the Pointer interacted with this object on, relative to the Game Object's top-left position.

    target: GameObject | null

    An optional drop target for a draggable Interactive Object.