Preparing search index...

    Simulates cloth physics with stretching, bending, and collision interactions.

    Hierarchy (View Summary)

    Index

    Constructors

    Properties

    bendMode: BendMode

    Bending calculation method for the cloth simulation.

    bendStiffness: number

    Resistance to bending, from 0 to 1.

    colliders: ColliderComponent[]

    Physics colliders the cloth can collide with.

    collisionEnabled: boolean

    Whether cloth collides with physics colliders.

    collisionFriction: number

    Friction applied during cloth-collider contact.

    collisionOffset: number

    Distance offset for collision detection.

    collisionStiffness: number

    How stiffly cloth responds to collisions.

    debugModeEnabled: boolean

    Whether debug visualization is rendered.

    enabled: boolean

    Whether the component is active.

    frameRate: number

    Simulation updates per second.

    friction: number

    Air resistance and internal cloth damping.

    gravity: vec3

    Gravity acceleration vector applied to the cloth.

    horizontalAlignment: Horizontal

    Horizontal alignment of the mesh visual.

    id: Uuid

    The unique id of the entity.

    iterations: number

    Constraint solver iterations per frame.

    mainMaterial: Material

    Primary material used for rendering.

    mass: number

    Total cloth mass in kilograms.

    materials: Material[]

    Array of all materials on this mesh visual.

    maxAcceleration: number

    Maximum acceleration any vertex can experience.

    RenderMesh defining the cloth geometry.

    meshShadowMode: MeshShadowMode

    Shadow rendering mode for the mesh.

    meta: Meta

    Metadata associated with this entity, providing access to its unique identifier and other descriptive properties.

    name: string

    Name of the component.

    renderOrder: number

    Determines the order in which this visual component is rendered relative to others.

    sceneObject: SceneObject

    Scene object this component is attached to.

    shadowColor: vec4

    Color of the mesh shadow.

    shadowDensity: number

    Opacity of the mesh shadow.

    stretchMode: StretchMode

    How the mesh stretches to fit its container.

    stretchStiffness: number

    Resistance to stretching, from 0 to 1.

    type: string

    The entity's type.

    updateNormalsEnabled: boolean

    Whether normals are recalculated each frame.

    vertexBindings: VertexBinding[]

    Array of pinned or constrained vertex bindings.

    verticalAlignment: Vertical

    Vertical alignment of the mesh visual.

    Methods

    • Returns true if the object is of the specified type.

      Parameters

      • type: string

      Returns boolean

    • Move a material from one index to another.

      Parameters

      • origin: number
      • destination: number

      Returns void