PulleyJoint class

The pulley joint is connected to two bodies and two fixed ground points. The pulley supports a ratio such that: length1 + ratio * length2 <= constant Yes, the force transmitted is scaled by the ratio. Warning: the pulley joint can get a bit squirrelly by itself. They often work better when combined with prismatic joints. You should also cover the the anchor points with static shapes to prevent one side from going to zero length.

@author Daniel Murphy

Inheritance

Constructors

PulleyJoint(IWorldPool argWorldPool, PulleyJointDef def)

Properties

hashCode int
The hash code for this object. [...]
read-only, inherited
pool IWorldPool
read / write, inherited
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

getAnchorA(Vector2 argOut) → void
get the anchor point on bodyA in world coordinates. [...]
override
getAnchorB(Vector2 argOut) → void
get the anchor point on bodyB in world coordinates. [...]
override
getCurrentLengthA() double
getCurrentLengthB() double
getGroundAnchorA() Vector2
getGroundAnchorB() Vector2
getLength1() double
getLength2() double
getLengthA() double
getLengthB() double
getLocalAnchorA() Vector2
getLocalAnchorB() Vector2
getRatio() double
getReactionForce(double inv_dt, Vector2 argOut) → void
get the reaction force on body2 at the joint anchor in Newtons. [...]
override
getReactionTorque(double inv_dt) double
get the reaction torque on body2 in N*m. [...]
override
initVelocityConstraints(SolverData data) → void
Internal
override
solvePositionConstraints(SolverData data) bool
This returns true if the position errors are within tolerance. Internal.
override
solveVelocityConstraints(SolverData data) → void
Internal
override
destructor() → void
Override to handle destruction of joint
inherited
getBodyA() Body
get the first body attached to this joint.
inherited
getBodyB() Body
get the second body attached to this joint. [...]
inherited
getCollideConnected() bool
Get collide connected. Note: modifying the collide connect flag won't work correctly because the flag is only checked when fixture AABBs begin to overlap.
inherited
getNext() Joint
get the next joint the world joint list.
inherited
getType() JointType
get the type of the concrete joint. [...]
inherited
isActive() bool
Short-cut function to determine if either body is inactive. [...]
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() String
Returns a string representation of this object.
inherited

Operators

operator ==(dynamic other) bool
The equality operator. [...]
inherited

Constants

MIN_PULLEY_LENGTH → const double
2.0