1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-07-13 02:11:46 +00:00

Physics is not running while paused, so zero the stats for the async

thread instead of keeping whatever value was before the pause.
This commit is contained in:
fredzio 2021-02-12 19:33:08 +01:00
parent bc4047d815
commit 9d90e250cf

View file

@ -1861,6 +1861,13 @@ namespace MWWorld
{
doPhysics (duration, frameStart, frameNumber, stats);
}
else
{
// zero the async stats if we are paused
stats.setAttribute(frameNumber, "physicsworker_time_begin", 0);
stats.setAttribute(frameNumber, "physicsworker_time_taken", 0);
stats.setAttribute(frameNumber, "physicsworker_time_end", 0);
}
}
void World::updatePlayer()