mirror of
https://github.com/DrBeef/Raze.git
synced 2024-11-15 08:52:00 +00:00
- use 1/8 of delta time as initial elapsed time when calculating smoothratio on a new ototalclk.
* Pushes final result closer to 65536 and always ensures smoothratio never starts at 0.
This commit is contained in:
parent
4830989d32
commit
3861064f62
1 changed files with 1 additions and 1 deletions
|
@ -1060,7 +1060,7 @@ int CalcSmoothRatio(const ClockTicks &totalclk, const ClockTicks &ototalclk, int
|
|||
else
|
||||
{
|
||||
lastototalclk = ototalclk;
|
||||
elapsedTime = 0;
|
||||
elapsedTime = lastTime != 0 ? (currentTime - lastTime) / 8 : 0;
|
||||
}
|
||||
lastTime = currentTime;
|
||||
ratio = elapsedTime / gametics;
|
||||
|
|
Loading…
Reference in a new issue