diff options
author | PouleyKetchoupp <pouleyketchoup@gmail.com> | 2021-11-25 08:26:38 -0700 |
---|---|---|
committer | PouleyKetchoupp <pouleyketchoup@gmail.com> | 2021-11-25 09:51:57 -0700 |
commit | 7032cf06378c81a16407cba78e5c50851cac60e8 (patch) | |
tree | b6b697cbf36300aadcf3b9a621cddfa248645610 /thirdparty/recastnavigation/Recast/Source/Recast.cpp | |
parent | b3ec5a16ea3a9d8ae95b2d1686eb36f71c5f70f5 (diff) |
Fix RigidDynamicBody gaining momentum with bounce
Bounce calculation now uses the previous frame's velocity, so it's
consistent with the actual motion of the bodies involved and not the
yet-to-be-applied forces.
When bounce is 1, using the current velocity was causing the new forces
(including gravity) to be taken into account, which lead to the bounce
velocity to be higher than the falling velocity at the moment of impact,
adding more and more energy over time.
Diffstat (limited to 'thirdparty/recastnavigation/Recast/Source/Recast.cpp')
0 files changed, 0 insertions, 0 deletions