===== orxBODY_JOINT structure =====
==== Summary ====
A good summary of the various joint types can be found here: https://www.iforce2d.net/b2dtut/joints-overview
=== Revolute Joint ===
[RevoluteJoint]
Type = revolute;
ParentAnchor = [Vector]
ChildAnchor = [Vector]
Collide = true|false
Rotation = [Float]
MinRotation = [Float]
MaxRotation = [Float]
MotorSpeed = [Float]
MaxMotorTorque = [Float]
=== Prismatic Joint ===
[PrismaticJoint]
Type = prismatic;
ParentAnchor = [Vector]
ChildAnchor = [Vector]
Collide = true|false
Rotation = [Float]
TranslationAxis = [Vector]
MinTranslation = [Float]
MaxTranslation = [Float]
MotorSpeed = [Float]
MaxMotorForce = [Float]
=== Spring Joint ===
[SpringJoint]
Type = spring
ParentAnchor = [Vector]
ChildAnchor = [Vector]
Collide = true|false
Length = [Float]
Frequency = [Float]
Damping = [Float]
=== Rope Joint ===
[RopeJoint]
Type = rope
ParentAnchor = [Vector]
ChildAnchor = [Vector]
Collide = true|false
Length = [Float]
=== Pulley Joint ===
[PulleyJoint]
Type = pulley
ParentAnchor = [Vector]
ChildAnchor = [Vector]
Collide = true|false
ParentGroundAnchor = [Vector]
ChildGroundAnchor = [Vector]
ParentLength = [Float]
MaxParentLength = [Float]
ChildLength = [Float]
MaxChildLength = [Float]
LengthRatio = [Float]
=== Suspension Joint ===
[SuspensionJoint]
Type = suspension;
ParentAnchor = [Vector]
ChildAnchor = [Vector]
Collide = true|false
TranslationAxis = [Vector]
MinTranslation = [Float]
MaxTranslation = [Float]
MotorSpeed = [Float]
MaxMotorForce = [Float]
=== Weld Joint ===
[WeldJoint]
Type = weld;
ParentAnchor = [Vector]
ChildAnchor = [Vector]
Collide = true|false
Rotation = [Float]
=== Friction Joint ===
[FrictionJoint]
Type = friction;
ParentAnchor = [Vector]
ChildAnchor = [Vector]
Collide = true|false
MaxForce = [Float]
MaxTorque = [Float]
=== Gear Joint ===
[GearJoint]
Type = gear
ParentAnchor = [Vector]
ChildAnchor = [Vector]
Collide = true|false
ParentJoint = [String]
ChildJoint = [String]
JointRatio = [Float]
==== Details ====
=== Common ===
Here's a list of common properties for the joints. Note that not all of the joins support these properties.
* ''Type'': Defines the type of the joint. Available types are: revolute, prismatic, spring, rope, pulley, suspension, weld, friction and gear.
* ''ParentAnchor'': The position the parent object is joined at, defined in local parent's space.
* ''ChildAnchor'': The position the child object is joined at, defined in local child's space.
* ''Collide'': Defines if collision between parent and child object is allowed.
* ''Rotation'': Default rotation between parent and child bodies, in degrees. If none is provided, the current rotation difference between both bodies will be used.
* ''MotorSpeed'': Only used if MaxMotorTorque is also defined. In degrees / seconds.
* ''MaxMotorTorque'': Only used if MotorSpeed is also defined.
=== Revolute Joint ===
* ''MinRotation'': Only used if MaxRotation is also defined.
* ''MaxRotation'': Only used if MinRotation is also defined.
=== Prismatic joint ===
* ''TranslationAxis'': Should be normalized.
* ''MinTranslation'': In meters, only used if MaxTranslation is also defined.
* ''MaxTranslation'': In meters, only used if MinTranslation is also defined.
=== Spring Joint ===
* ''Length'': In meters. If not defined, the current distance between parent and child bodies will be used.
* ''Frequency'': In hertz.
* ''Damping'': Between 0 (min) and 1 (max)
=== Rope Joint===
* ''Length'': In meters. If not defined, the current distance between parent and child bodies will be used.
=== Pulley Joint===
* ''ParentGroundAnchor''
* ''ChildGroundAnchor''
* ''ParentLength'': In meters. If not defined, the current distance between parent and its ground anchor will be used;
* ''MaxParentLength'': In meters. If not defined ParentLength + LengthRatio * ChildLength will be used;
* ''ChildLength'': In meters. If not defined, the current distance between child and its ground anchor will be used;
* ''MaxChildLength'': In meters. If not defined ParentLength + LengthRatio * ChildLength will be used;
* ''LengthRatio''
=== Suspension Joint ===
* ''TranslationAxis'': Should be normalized;
* ''MinTranslation'': In meters; Only used if MaxTranslation is also defined;
* ''MaxTranslation'': In meters; Only used if MinTranslation is also defined;
=== Weld Joint ===
Does not have any properties except those defined in the summary.
=== Friction Joint ===
* ''Collide = true|false'': Allows collision between joint's parent and child bodies. Defaults to false;
* ''MaxForce'':
* ''MaxTorque'':
=== Gear Joint ===
* ''ParentJoint'': Should be a revolute or prismatic joint already existing on the parent.
* ''ChildJoint'': Should be a revolute or prismatic joint already existing on the child.
* ''JointRatio''
==== Latest config settings for the Development Version ====
{{section>en:orx:config:developmentversion#&noheader&nofooter&noeditbutton}}