crashcat docs
    Preparing search index...

    Type Alias WorldContactPoint

    A single contact point with non-penetration constraint data. Links world-space geometry to constraint solving.

    Friction is no longer per-contact-point — it lives on the parent ContactConstraint. Each WorldContactPoint only owns the 1-DOF non-penetration constraint plus a cached moment-arm to the friction center for computing the angular friction cap.

    type WorldContactPoint = {
        distanceToFrictionCenter: number;
        localPositionA: Vec3;
        localPositionB: Vec3;
        normalConstraint: axisConstraintPart.AxisConstraintPart;
        positionA: Vec3;
        positionB: Vec3;
    }
    Index

    Properties

    distanceToFrictionCenter: number

    Distance from this contact point on body A to the mean of body A's contact points, projected onto the plane perpendicular to the contact normal. Used as the moment arm when computing the angular friction cap: μ · Σ_i (distanceToFrictionCenter_i · normalLambda_i).

    localPositionA: Vec3

    Contact point position in body A's local/relative space (center of mass space). Constant - used to recompute world position when body moves.

    localPositionB: Vec3

    Contact point position in body B's local/relative space (center of mass space). Constant - used to recompute world position when body moves.

    normalConstraint: axisConstraintPart.AxisConstraintPart

    Normal constraint: prevents interpenetration. Direction: contact normal (perpendicular to contact surface). Lambda clamping: normalLambda >= 0 (push only, no pull).

    positionA: Vec3

    Contact point position on body A (world space). Recomputed each solving iteration from local position + body transform.

    positionB: Vec3

    Contact point position on body B (world space). Recomputed each solving iteration from local position + body transform.