Click or drag to resize

DistanceJoint Class

A distance joint rains two points on two bodies to remain at a fixed distance from each other. You can view this as a massless, rigid rod.
Inheritance Hierarchy
SystemObject
  Internal.tainicom.Aether.Physics2D.Dynamics.JointsJoint
    Internal.tainicom.Aether.Physics2D.Dynamics.JointsDistanceJoint

Namespace:  Internal.tainicom.Aether.Physics2D.Dynamics.Joints
Assembly:  NeoAxis.Core (in NeoAxis.Core.dll) Version: 2024.1.1.0 (2024.1.1.0)
Syntax
C#
public class DistanceJoint : Joint

The DistanceJoint type exposes the following members.

Constructors
  NameDescription
Public methodDistanceJoint
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.
Top
Properties
  NameDescription
Public propertyBodyA
Get the first body attached to this joint.
(Inherited from Joint.)
Public propertyBodyB
Get the second body attached to this joint.
(Inherited from Joint.)
Public propertyBreakpoint
The Breakpoint simply indicates the maximum Value the JointError can be before it breaks. The default value is float.MaxValue, which means it never breaks.
(Inherited from Joint.)
Public propertyCollideConnected
Set this flag to true if the attached bodies should collide.
(Inherited from Joint.)
Public propertyDampingRatio
The damping ratio. 0 = no damping, 1 = critical damping.
Public propertyFrequency
The mass-spring-damper frequency in Hertz. A value of 0 disables softness.
Public propertyJointType
Gets or sets the type of the joint.
(Inherited from Joint.)
Public propertyLength
The natural length between the anchor points. Manipulating the length can lead to non-physical behavior when the frequency is zero.
Public propertyLocalAnchorA
The local anchor point relative to bodyA's origin.
Public propertyLocalAnchorB
The local anchor point relative to bodyB's origin.
Public propertyWorld
Get the parent World of this joint. This is null if the joint is not attached.
(Inherited from Joint.)
Public propertyWorldAnchorA (Overrides JointWorldAnchorA.)
Public propertyWorldAnchorB (Overrides JointWorldAnchorB.)
Top
Methods
  NameDescription
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetReactionForce
Get the reaction force given the inverse time step. Unit is N.
(Overrides JointGetReactionForce(Single).)
Public methodGetReactionTorque
Get the reaction torque given the inverse time step. Unit is N*m. This is always zero for a distance joint.
(Overrides JointGetReactionTorque(Single).)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodIsFixedType
Return true if the joint is a fixed type.
(Inherited from Joint.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Protected methodWakeBodies (Inherited from Joint.)
Top
Events
  NameDescription
Public eventBroke
Fires when the joint is broken.
(Inherited from Joint.)
Top
Fields
  NameDescription
Public fieldEnabled
Indicate if this join is enabled or not. Disabling a joint means it is still in the simulation, but inactive.
(Inherited from Joint.)
Public fieldTag
Set the user data pointer.
(Inherited from Joint.)
Top
Extension Methods
See Also