Closed Nicolas-Ferre closed 8 months ago
The reason why the angular velocity is being erased is because your rigid-body doesn’t have any mass/angular inertia, which is a requirement for the new solver (and is more correct physically speaking).
Thank you very much for the explanation, I added an angular inertia and it indeed works well now.
Issue Since version 0.18, when the
angvel
of aRigidBody
is set to a value different than 0, it comes back to 0 after execution ofPhysicsPipeline::step
. This problem is not present in version 0.17.Bug reproduction This code can be used to reproduce the issue:
The code panics in the following conditions:
rapier2d
version: 0.18.0 (only default features are enabled)Additional notes It seems that the angular velocity is erased when the following line is run: https://github.com/dimforge/rapier/blob/da92e5c2837b27433286cf0dd9d887fd44dda254/src/dynamics/solver/velocity_solver.rs#L307