summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/game.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/game.cpp b/src/game.cpp
index a6057d07..e548e1ef 100644
--- a/src/game.cpp
+++ b/src/game.cpp
@@ -389,6 +389,10 @@ void Game::logic()
engine->draw(graphics);
graphics->updateScreen();
mDrawTime += mMinFrameTime;
+
+ // Make sure to wrap mDrawTime, since tick_time will wrap.
+ if (mDrawTime > MAX_TIME * 10)
+ mDrawTime -= MAX_TIME * 10;
}
else
{