RobustToolbox icon indicating copy to clipboard operation
RobustToolbox copied to clipboard

Physics broadphase displacement

Open metalgearsloth opened this issue 3 years ago • 0 comments
trafficstars

Forgor what issue I put this under.

tl;dr is that

  1. Sleeping bodies should use the displacement as is (Vector2.Zero). Same with bodies that have their position directly outside of physics.
  2. Moving physics bodies should use displacement from last position to current position when updating broadphase.

You can probably just add a flag to the broadphase or something and toggle it on when physics starts and off when it's off. Then any moveevents captured during this time consider the oldposition and newposition.

metalgearsloth avatar Aug 09 '22 09:08 metalgearsloth