setEnabledRotations
Sets which rotations are enabled for the physics object.
Syntax
object.setEnabledRotations(rotations);
Parameters
Name | Type | Description |
---|---|---|
rotations | [ Boolean3Array](/sdk/types/Boolean3Array) | An array of booleans indicating which rotations are enabled. |
Example
// Enable only the Y rotation
object.setEnabledRotations([false, true, false]);
Available on: Client Server