rapier icon indicating copy to clipboard operation
rapier copied to clipboard

Error occurs when changing a body type from dynamic to static if it has attached joints

Open Mr4k opened this issue 3 years ago • 0 comments

Version 0.11.1

Steps to reproduce:

  1. Create two dynamic bodies
  2. Bind them together with a ball joint
  3. Simulate a few steps
  4. Make one of them static
  5. Simulate more steps (should panic with index out of bounds)

My guess to what's happening here is there is some kind of active / dynamic body list and the joint references the dynamic bodies by its index into that. When a body changes to static it's removed from that list but the joint still references so it tries to get a non existent index and crashes.

Mr4k avatar Nov 06 '21 14:11 Mr4k