Documentation
    Preparing search index...

    Interface TriangleMeshShape

    A triangle mesh, "3d" only (§24) — arbitrary, possibly concave static geometry.

    Composite (see the module header): no interior, no derived mass, refused as a §30 query shape. This is what a level's collision mesh is.

    interface TriangleMeshShape {
        indices: readonly number[];
        type: "triangle-mesh";
        vertices: readonly Vector3[];
    }
    Index
    indices: readonly number[]

    Three indices into TriangleMeshShape.vertices per triangle, so the length is a positive multiple of three. Every entry must be an integer in [0, vertices.length).

    type: "triangle-mesh"
    vertices: readonly Vector3[]

    At least three finite vertices, in the collider's local frame.