fix: workaround high frame skip when loading resources

It'll need a proper fix, but if the game is going under 15FPS,
make delta time to 1/15 second, in order to be sure that it'll simply slow
that frame and not skip a whole transition for instance
This commit is contained in:
Kazhnuz 2021-04-10 11:09:38 +02:00
parent 7b97b1d82a
commit b1eb30ed6c

View file

@ -89,6 +89,8 @@ end
-- Load every sytem every update functions of the scene and objects
function CoreSystem:update(dt)
-- If the frameskip is to high, prefer slowdown to frameskip
local dt = math.min(dt, 1/15)
self.debug:update(dt)
self.input:update(dt)