Skip to main content

PreCollisionEvent <T>

Event thrown on an actor when a collision will occur this frame if it resolves

Hierarchy

Index

Constructors

constructor

  • Type parameters

    Parameters

    • self: T

      The actor the event was thrown on

    • other: T

      The actor that will collided with the current actor

    • side: Side

      The side that will be collided with the current actor

    • intersection: Vector

      Intersection vector

    • contact: CollisionContact

    Returns PreCollisionEvent<T>

Properties

publiccontact

publicintersection

intersection: Vector

Intersection vector

publicinheritedother

other: T

The actor that will collided with the current actor

publicself

self: T

The actor the event was thrown on

publicside

side: Side

The side that will be collided with the current actor

publicinheritedtarget

target: T

Target object for this event.

Accessors

publicinheritedbubbles

  • get bubbles(): boolean
  • set bubbles(value: boolean): void
  • If set to false, prevents event from propagating to other actors. If true it will be propagated to all actors that apply.


    Returns boolean

  • Parameters

    • value: boolean

    Returns void

Methods

publicinheritedstopPropagation

  • stopPropagation(): void
  • Prevents event from bubbling


    Returns void