A ragdoll joint config is used for constructions of ragdoll joints.
Constructor
Variables
localSwingAxis1:Vec3
The first body's local swing axis.
The second swing axis is also attached to the first body. It is perpendicular to the first swing axis, and is automatically computed when the joint is created.
maxSwingAngle1:Float
The max angle of rotation along the first swing axis. This value must be positive.
maxSwingAngle2:Float
The max angle of rotation along the second swing axis. This value must be positive.
twistLimitMotor:RotationalLimitMotor
The rotational limit and motor along the twist axis of the joint.
Methods
init(rigidBody1:RigidBody, rigidBody2:RigidBody, worldAnchor:Vec3, worldTwistAxis:Vec3, worldSwingAxis:Vec3):RagdollJointConfig
Sets rigid bodies, local anchors from the world anchor worldAnchor
, local twist axes
from the world twist axis worldTwistAxis
, local swing axis from the world swing axis
worldSwingAxis
, and returns this
.