HughPH.Box2D
Organised dotnet bindings for Box2D 3.1.0
Loading...
Searching...
No Matches
Public Member Functions | Properties | List of all members
Box2D.RevoluteJoint Class Referencesealed

A revolute joint allows for relative rotation in the 2D plane with no relative translation. More...

Inheritance diagram for Box2D.RevoluteJoint:
Inheritance graph
[legend]
Collaboration diagram for Box2D.RevoluteJoint:
Collaboration graph
[legend]

Public Member Functions

void EnableSpring (bool enableSpring)
 Enables/disables the revolute joint spring.
 
void SetLimits (float lower, float upper)
 Sets the revolute joint limits in radians.
 
- Public Member Functions inherited from Box2D.Joint
void Destroy ()
 Destroys this joint.
 
void WakeBodies ()
 Wakes the bodies connected to this joint.
 

Properties

bool SpringEnabled [get, set]
 The revolute joint spring enabled state.
 
float SpringHertz [get, set]
 The revolute joint spring stiffness in Hertz.
 
float SpringDampingRatio [get, set]
 The revolute joint spring damping ratio.
 
float Angle [get]
 The current joint angle in radians.
 
bool LimitEnabled [get, set]
 The revolute joint limit enabled state.
 
float LowerLimit [get]
 The lower joint limit of this revolute joint in radians.
 
float UpperLimit [get]
 The upper joint limit of this revolute joint in radians.
 
bool MotorEnabled [get, set]
 The revolute joint motor enabled state.
 
float MotorSpeed [get, set]
 The revolute joint motor speed in radians per second.
 
float MotorTorque [get]
 The revolute joint current motor torque, usually in newton-meters.
 
float MaxMotorTorque [get, set]
 The revolute joint maximum motor torque, usually in newton-meters.
 
- Properties inherited from Box2D.Joint
bool Valid [get]
 Checks if this joint is valid.
 
JointType Type [get]
 Gets the joint type.
 
Body BodyA [get]
 Gets body A on this joint.
 
Body BodyB [get]
 Gets body B on this joint.
 
World World [get]
 Gets the world that owns this joint.
 
Vec2 LocalAnchorA [get]
 Gets the local anchor on body A.
 
Vec2 LocalAnchorB [get]
 Gets the local anchor on body B.
 
bool CollideConnected [get, set]
 Set this flag to true if the attached bodies should collide.
 
object? UserData [get, set]
 The user data object for this joint.
 
Vec2 ConstraintForce [get]
 Gets the current constraint force for this joint.
 
float ConstraintTorque [get]
 Gets the current constraint torque for this joint.
 

Detailed Description

A revolute joint allows for relative rotation in the 2D plane with no relative translation.

The revolute joint is probably the most common joint. It can be used for ragdolls and chains. Also called a hinge or pin joint.

Member Function Documentation

◆ EnableSpring()

void Box2D.RevoluteJoint.EnableSpring ( bool  enableSpring)

Enables/disables the revolute joint spring.

Parameters
enableSpringTrue to enable the spring, false to disable the spring

◆ SetLimits()

void Box2D.RevoluteJoint.SetLimits ( float  lower,
float  upper 
)

Sets the revolute joint limits in radians.

Parameters
lowerThe lower limit in radians
upperThe upper limit in radians

The documentation for this class was generated from the following file: