Basics
Guides
API Reference
Basics
Guides
API Reference
[18:7] extends: Joint
Wraps jbox2d's PulleyJoint (com.almasb.fxgl.physics.box2d.dynamics.joints.PulleyJoint). Connects two bodies and two fixed ground anchors with a length1 + ratio * length2 = constant constraint. Pulley joints can be unstable on their own; combining with prismatic joints and using static cover shapes at the anchors helps.
PulleyJoint ()
Empty default constructor; populated by adopt.
adopt (object Ajo)
Wraps an existing PulleyJoint AussomJavaObject.
getLengthA ()
Returns the reference length for the bodyA segment.
getLengthB ()
Returns the reference length for the bodyB segment.
getCurrentLengthA ()
Returns the current length of the bodyA segment.
getCurrentLengthB ()
Returns the current length of the bodyB segment.
getLocalAnchorA ()
Returns the local anchor on body A as a Vec2 wrapper.
getLocalAnchorB ()
Returns the local anchor on body B as a Vec2 wrapper.
getGroundAnchorA ()
Returns the world-space ground anchor A as a Vec2 wrapper.
getGroundAnchorB ()
Returns the world-space ground anchor B as a Vec2 wrapper.
getLength1 ()
Returns the current length of segment 1 (bodyA side).
getLength2 ()
Returns the current length of segment 2 (bodyB side).
getRatio ()
Returns the pulley ratio.

Aussom
Write once. Embed everywhere.
Copyright 2026 Austin Lehman. All rights reserved.