Base node for all joint constraints in 2D physics.
    public abstract class Joint2D : Node2D

Base node for all joint constraints in 2D physics. Joints take 2 bodies and apply a custom constraint.

Inheritance Chain

Derived Classes

Properties

    public float Bias { get; set; }

When NodeA and NodeB move in different directions the bias controls how fast the joint pulls them back to their original position. The lower the bias the more the two bodies can pull on the joint.

    public bool DisableCollision { get; set; }

If true, NodeA and NodeB can collide.

    public NodePath NodeA { get; set; }

The first body attached to the joint. Must derive from PhysicsBody2D.

    public NodePath NodeB { get; set; }

The second body attached to the joint. Must derive from PhysicsBody2D.

Methods

    [Obsolete("GetBias is deprecated. Use the Bias property instead.")]
    public float GetBias()

Getter for Bias

    [Obsolete("GetExcludeNodesFromCollision is deprecated. Use the DisableCollision property instead.")]
    public bool GetExcludeNodesFromCollision()

Getter for DisableCollision

    [Obsolete("GetNodeA is deprecated. Use the NodeA property instead.")]
    public NodePath GetNodeA()

Getter for NodeA

    [Obsolete("GetNodeB is deprecated. Use the NodeB property instead.")]
    public NodePath GetNodeB()

Getter for NodeB

    [Obsolete("SetBias is deprecated. Use the Bias property instead.")]
    public void SetBias(float bias)

Setter for Bias

    [Obsolete("SetExcludeNodesFromCollision is deprecated. Use the DisableCollision property instead.")]
    public void SetExcludeNodesFromCollision(bool enable)

Setter for DisableCollision

    [Obsolete("SetNodeA is deprecated. Use the NodeA property instead.")]
    public void SetNodeA(NodePath node)

Setter for NodeA

    [Obsolete("SetNodeB is deprecated. Use the NodeB property instead.")]
    public void SetNodeB(NodePath node)

Setter for NodeB

Tags: