Skip to content
Work in progress. These docs describe Spawnite at launch, and some parts are still being built.

setJoint

setJoint(authority, joint, changes): JointRefusal | null

Changes joint, a joint’s entity, in place on the world authority decides for: a crane’s motor target follows its operator’s lever. A spring’s lengths and a rope’s length make the joint again, which Rapier’s bindings cannot change. The change streams. A setting the joint’s type has none of, or a value out of what the solver holds, throws in development, and is refused deployed, returning the reason and leaving the joint as it was.

Parameter Type
authority EntityAuthority
joint Entity
changes JointChanges

JointRefusal | null

setJoint(step, crane, { motor: { targetPosition: lever * 1.2 } });