crashcat docs
    Preparing search index...

    Type Alias CharacterContact

    contact information for a character collision

    type CharacterContact = {
        bodyId: BodyId;
        canPushCharacter: boolean;
        canReceiveImpulses: boolean;
        contactNormal: Vec3;
        distance: number;
        fraction: number;
        hadCollision: boolean;
        isSensor: boolean;
        linearVelocity: Vec3;
        materialId: number;
        motionType: MotionType;
        position: Vec3;
        subShapeId: number;
        surfaceNormal: Vec3;
        wasDiscarded: boolean;
    }
    Index

    Properties

    bodyId: BodyId

    body ID of contacted body (use BodyId for persistence safety)

    canPushCharacter: boolean

    can this contact push the character?

    canReceiveImpulses: boolean

    can character push body? (apply impulses)

    contactNormal: Vec3

    normal pointing toward character

    distance: number

    distance to surface (negative = penetration)

    fraction: number

    fraction along sweep (0-1)

    hadCollision: boolean

    did actual collision occur? (vs just predictive)

    isSensor: boolean

    is the contacted body a sensor? (sensors don't push character)

    linearVelocity: Vec3

    velocity at contact point (from contacted body)

    materialId: number

    material ID of contacted sub-shape

    motionType: MotionType

    motion type of contacted body (for constraint prioritization)

    position: Vec3

    world position of contact

    subShapeId: number

    sub-shape ID on contacted body

    surfaceNormal: Vec3

    true surface normal (may differ from contactNormal for edges)

    wasDiscarded: boolean

    was contact discarded by validation?