API

Class HingeConstraint

Creates a HingeConstraint, which is a type of PhysicsConstraint.

This code is useful for creating a HingeConstraint, which is a type of PhysicsConstraint. This constraint is used to simulate a hinge joint between two rigid bodies, allowing them to rotate around a single axis.

The first pivot point, in world space.

The second pivot point, in world space.

The scene the constraint is used in.

The new HingeConstraint.

Hierarchy (View Summary)

Index
_pluginData: any = undefined

V2 Physics plugin private data for a physics material

  • get isCollisionsEnabled(): boolean

    Gets whether collisions are enabled for this physics object.

    Returns boolean

    true if collisions are enabled, false otherwise.

  • set isCollisionsEnabled(isEnabled: boolean): void

    Enables or disables collisions for the physics engine.

    Parameters

    • isEnabled: boolean

      A boolean value indicating whether collisions should be enabled or disabled.

    Returns void