Adaptive Timestepping PrismaticConstraints not reaching target

This bug occured a few weeks ago, where PrismaticConstraints with low LinearResponsiveness do not reach their target when moving from a higher target to a lower one:

I’m assuming the flag that caused this has been re-enabled, but the issue still persists.

Expected behavior

I expect the constraint to stop at the target

Aplogies for the issue :smiling_face_with_tear: We have disabled the offending flag and will take a close look.


Hello! Bumping an old convo but was wondering if this is fixed.

Yes and no - it has been fixed in the sense that the behaviour now appears to be consistent whether adaptive or fixed timestepping is used. However, using very low values of LinearResponsiveness still seems to result in the constraint not reaching its target.

Is LinearResponsiveness supposed to impact the precision to which PrismaticConstraints reach their targets? The documentation only mentions that it affects the “sharpness” of the servo motor.

Hi! The reason your PrismaticConstraint doesn’t reach its target might be a result of the sleep system. When the part is moving very slowly (which will happen if you set LinearResponsiveness to a low value), the sleep system will consider this part to be visually non-moving and put it to sleep.

You can check if this is the case by disabling sleep in studio (Studio Settings → Physics → Allow Sleep), and testing your mechanism. Just make sure sure to enable sleep when you’re done testing :slight_smile:

We are working on more thorough documentation of the sleep system which will also provide additional guidance for developers, stay tuned!