You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hallo,
I'm using a DistanceJoint to attract a DynamicBody to a static center Body. The original Box2D implementation allows setting the length of the DistanceJoint through DistanceJointDef. In planck-js the length is automatically calculated as the distance between the two anchors:
this.m_length = Vec2.distance(anchorB, anchorA);
Currently I'm overwriting m_length after creating the joint. It would be nice if the length could be specified in the definition.
The text was updated successfully, but these errors were encountered:
Hallo,
I'm using a
DistanceJoint
to attract aDynamicBody
to a static centerBody
. The original Box2D implementation allows setting the length of theDistanceJoint
throughDistanceJointDef
. In planck-js the length is automatically calculated as the distance between the two anchors:this.m_length = Vec2.distance(anchorB, anchorA);
Currently I'm overwriting
m_length
after creating the joint. It would be nice if the length could be specified in the definition.The text was updated successfully, but these errors were encountered: