MCPcopy Create free account
hub / github.com/TombEngine/TombEngine / Synced

Method Synced

TombEngine/Specific/clock.cpp:55–74  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

53}
54
55bool HighFramerateSynchronizer::Synced()
56{
57#if _DEBUG
58 if (_controlDelay >= DEBUG_SKIP_FRAME_TIME)
59 {
60 TENLog("Game loop is running too slow.", LogLevel::Warning);
61 App.ResetClock = true;
62 return false;
63 }
64#endif
65
66 // If frameskip is in action, lock flag will remain set until synchronizer is
67 // about to break out from it. This flag is later reused in input polling to
68 // prevent engine from de-registering input events prematurely.
69
70 if (_controlDelay > CONTROL_FRAME_TIME && _controlDelay <= CONTROL_FRAME_TIME * 2)
71 _locked = false;
72
73 return (_controlDelay >= CONTROL_FRAME_TIME);
74}
75
76void HighFramerateSynchronizer::Step()
77{

Callers 4

CallPauseMethod · 0.80
CallInventoryMethod · 0.80
DoGameLoopFunction · 0.80

Calls 1

TENLogFunction · 0.85

Tested by

no test coverage detected