Physics.HingeMotorType
EnumEnum that defines motor type.
- Available on all platforms
Platform details: Snapchat, SPECS, Camera Kit Web, Camera Kit Mobile fully supported.
Since Lens Scripting v282
Index
Enumeration Members
Example
//@input Physics.ConstraintComponent constraintComponent
let constraint = script.constraintComponent.constraint;
let motorSettings = constraint.motorSettings;
motorSettings.enabled = true;
motorSettings.maxImpulse = 10;
motorSettings.targetType = HingeMotorType.AngleTarget;
motorSettings.targetValue = Math.PI/2;
motorSettings = motorSettings;
Enumeration Members
AngleTarget
AngleTarget:
number
A motor that attempts to rotate to or hold a specific angle or position along the hinge axis.
Since
Lens Scripting Version 282
VelocityTarget
VelocityTarget:
number
A motor that applies torque to reach or maintain a target speed (angular velocity).
Since
Lens Scripting Version 282