mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-11-20 09:29:44 +00:00
ServerMainloop slept the rest of the tick and then restarted counting from the moment it woke up, so every sleep overshoot made the tick longer. With a coarse timer (a VirtualBox guest of a Windows host) --tps 20 gave 12-17 ticks per second. Ticks now follow absolute deadlines on steady_clock; after falling more than 5 ticks behind the schedule is reset instead of running a burst of ticks. The time of a tick is its scheduled time, so delta is exactly 1 / tps while the loop keeps up, as in test mode. With the wake-up time deltas jitter around 1 / tps, and the world tick clock, which calls on_world_tick at most once per update, skipped every few ticks. |
||
|---|---|---|
| .. | ||
| AssetsManagement.cpp | ||
| AssetsManagement.hpp | ||
| CoreParameters.hpp | ||
| Engine.cpp | ||
| Engine.hpp | ||
| EnginePaths.cpp | ||
| EnginePaths.hpp | ||
| Mainloop.cpp | ||
| Mainloop.hpp | ||
| PostRunnables.hpp | ||
| ServerMainloop.cpp | ||
| ServerMainloop.hpp | ||
| Time.hpp | ||
| WindowControl.cpp | ||
| WindowControl.hpp | ||