DistanceJoint Constructor |
This requires defining an
anchor point on both bodies and the non-zero length of the
distance joint. If you don't supply a length, the local anchor points
is used so that the initial configuration can violate the constraint
slightly. This helps when saving and loading a game.
Warning Do not use a zero or short length.
Namespace: Internal.tainicom.Aether.Physics2D.Dynamics.JointsAssembly: NeoAxis.Core (in NeoAxis.Core.dll) Version: 2026.1.1.0 (2026.1.1.0)
Syntaxpublic DistanceJoint(
Body bodyA,
Body bodyB,
Vector2 anchorA,
Vector2 anchorB,
bool useWorldCoordinates = false
)
Parameters
- bodyA Body
- The first body
- bodyB Body
- The second body
- anchorA Vector2
- The first body anchor
- anchorB Vector2
- The second body anchor
- useWorldCoordinates Boolean (Optional)
- Set to true if you are using world coordinates as anchors.
See Also