dacha
    Preparing search index...

    Class Collider

    Gives an actor a shape for collisions: a box, a circle, a capsule or a segment.

    Hierarchy (View Summary)

    Index
    actor?: Actor

    The actor that has this component. It is undefined until the component is added to an actor.

    debugColor?: string

    The color of the collider in the debug view of the editor.

    disabled: boolean

    Turns the collider off.

    layer: string

    The collision layer. Layers decide which colliders collide.

    offset: Point

    Moves the shape away from the position of the actor.

    The shape and its size.

    • Returns the component of the same class on the parent actor.

      Returns Component<object> | undefined

      The component, or undefined if the actor has no parent actor or the parent has no such component.