mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-10 15:22:04 +00:00
Limit the amount of time that MVDs can skip.
Trying to cover very long times will probably cause more problems than it fixes, so limit the length of time. Two seconds aught to be enough for now. Need to look into proper handling of prevtime.
This commit is contained in:
parent
c416e15cd7
commit
532e79bca6
1 changed files with 2 additions and 0 deletions
|
@ -165,6 +165,8 @@ write_msg (sizebuf_t *msg, int type, int to, float time, sizebuf_t *dst)
|
|||
|
||||
msec = (time - prevtime) * 1000;
|
||||
prevtime += msec * 0.001;
|
||||
if (msec > 2000)
|
||||
msec = 2000;
|
||||
while (msec > 250) {
|
||||
//the maximum interval we can send is 255ms, but that's nasty with
|
||||
//floats, so keep things to a nice round number of 250ms (0.25 is float
|
||||
|
|
Loading…
Reference in a new issue