mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-11-11 07:11:39 +00:00
- adjust elapsedInputTicks
in GetInput()
to be 1000.0 / REALGAMETICSPERSEC
.
* 1000 / 30 = 33.333~. This ensures that if 33.333 is the minimum value, the calculation for scaleAdjust always equals 1.0 (no scaling).
This commit is contained in:
parent
25ca23f2e2
commit
5bb7c7a647
1 changed files with 1 additions and 1 deletions
|
@ -1207,7 +1207,7 @@ void GetInput()
|
|||
auto now = I_msTimeF();
|
||||
// do not let this become too large - it would create overflows resulting in undefined behavior. The very first tic must not use the timer difference at all because the timer has not been set yet.
|
||||
// This really needs to have the timer fixed to be robust, doing it ad-hoc here is not really safe.
|
||||
if (lastCheck > 0) elapsedInputTicks = min(now - lastCheck, (double)(REALGAMETICSPERSEC));
|
||||
if (lastCheck > 0) elapsedInputTicks = min(now - lastCheck, 1000.0 / REALGAMETICSPERSEC);
|
||||
else elapsedInputTicks = 1;
|
||||
lastCheck = now;
|
||||
|
||||
|
|
Loading…
Reference in a new issue