GearConstraint Class
Connects two bodies at given offset points, letting them rotate relative to each other around this point.
Constructor
Item Index
Methods
getMaxTorque
()
Number
Get the max torque for the constraint.
Returns:
Number:
setMaxTorque
(
-
torque
Set the max torque for the constraint.
Parameters:
-
torqueNumber
setRelaxation
(
-
relaxation
Set relaxation for this constraint.
Parameters:
-
relaxationNumber
setStiffness
(
-
stiffness
Set stiffness for this constraint.
Parameters:
-
stiffnessNumber
update
()
Updates the internal constraint parameters before solve.
Properties
angle
Number
The relative angle
collideConnected
Boolean
Set to true if you want the connected bodies to collide.
Default: true
equations
Array
Equations to be solved in this constraint
ratio
Number
The gear ratio.
