Avoid crash that can happen if the first DT is large and event

happens during that time.
This commit is contained in:
hiker 2018-02-14 09:20:45 +11:00
parent df5adbc320
commit 2a30f75b78

View File

@ -243,6 +243,8 @@ void RewindManager::playEventsTill(float time, float *dt)
Physics::getInstance()->getPhysicsWorld()->resetLocalTime();
}
if (m_rewind_queue.isEmpty()) return;
// This is necessary to avoid that rewinding an event will store the
// event again as a seemingly new event.
assert(!m_is_rewinding);