diff options
| author | Sébastien Crozet <developer@crozet.re> | 2022-01-10 11:38:43 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-01-10 11:38:43 -0800 |
| commit | 0ccd15c4b1f57d6c85a1727a55ed991c835690f5 (patch) | |
| tree | c1e8804e870289f8416f49383f8588974e12f447 /src | |
| parent | 2bfceadf0672572a360af33cf4a78cb42488e684 (diff) | |
| parent | 367fc3405f5b43af90527c9710a47b8b88185001 (diff) | |
| download | rapier-0ccd15c4b1f57d6c85a1727a55ed991c835690f5.tar.gz rapier-0ccd15c4b1f57d6c85a1727a55ed991c835690f5.tar.bz2 rapier-0ccd15c4b1f57d6c85a1727a55ed991c835690f5.zip | |
Merge pull request #270 from tjamaan/fix_RigidBodyVelocity_rotation_center
fix the parameter used for local center of mass
Diffstat (limited to 'src')
| -rw-r--r-- | src/pipeline/physics_pipeline.rs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/pipeline/physics_pipeline.rs b/src/pipeline/physics_pipeline.rs index 125b144..0f3235e 100644 --- a/src/pipeline/physics_pipeline.rs +++ b/src/pipeline/physics_pipeline.rs @@ -426,9 +426,7 @@ impl PhysicsPipeline { let new_pos = rb_vel.integrate( integration_parameters.dt, &rb_pos.position, - // NOTE: we don't use the `world_com` here because it is not - // really updated for kinematic bodies. - &(rb_pos.position * rb_mprops.local_mprops.local_com), + &rb_mprops.local_mprops.local_com, ); bodies.set_internal(handle.0, RigidBodyPosition::from(new_pos)); } |
