class
D6Joint
Represents the most customizable type of joint.
This joint type can be used to create all other built-in joint types, and to design your own custom ones, but is less intuitive to use. Allows a specification of a linear constraint (for example for slider), twist constraint (rotating around X) and swing constraint (rotating around Y and Z). It also allows you to constrain limits to only specific axes or completely lock specific axes.
Public
Constructors
D6Joint
Methods
SetMotion
Allows you to constrain motion of the specified axis.
Be aware that when setting drives for a specific axis you must also take care not to constrain its motion in a conflicting way (for example you cannot add a drive that moves the joint on X axis, and then lock the X axis).
Unlocking translations degrees of freedom allows the bodies to move along the subset of the unlocked axes. (for example unlocking just one translational axis is the equivalent of a slider joint.)
Angular degrees of freedom are partitioned as twist (around X axis) and swing (around Y and Z axes). Different effects can be achieves by unlocking their various combinations:
- If a single degree of angular freedom is unlocked it should be the twist degree as it has extra options for that case (for example for a hinge joint).
- If both swing degrees are unlocked but twist is locked the result is a zero-twist joint.
- If one swing and one twist degree of freedom are unlocked the result is a zero-swing joint (for example an arm attached at the elbow)
- If all angular degrees of freedom are unlocked the result is the same as the spherical joint.
GetMotion
Returns motion constraint for the specified axis.
GetTwist
Returns the current rotation of the joint around the X axis.
GetSwingY
Returns the current rotation of the joint around the Y axis.
GetSwingZ
Returns the current rotation of the joint around the Z axis.
SetLimitLinear
Determines the linear limit used for constraining translation degrees of freedom.
GetLimitLinear
SetLimitTwist
Determines the angular limit used for constraining the twist (rotation around X) degree of freedom.
GetLimitTwist
SetLimitSwing
Determines the cone limit used for constraining the swing (rotation around Y and Z) degree of freedom.
GetLimitSwing
SetDrive
Determines a drive that will attempt to move the specified degree(s) of freedom to the wanted position and velocity.
GetDrive
GetDrivePosition
Returns the drive's target position relative to the joint's first body.
GetDriveRotation
Returns the drive's target rotation relative to the joint's first body.
SetDriveTransform
Sets the drive's target position and rotation relative to the joint's first body.
GetDriveLinearVelocity
Returns the drive's target linear velocity.
GetDriveAngularVelocity
Returns the drive's target angular velocity.
SetDriveVelocity
Sets the drive's target linear and angular velocities.
staticGetRttiStatic
Internal
Methods
GetImplementation
Returns the low level joint implementation.
Protected
Constructors
D6Joint
Methods
CreateImplementation
Creates the implementation the joint for use by the component.