]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Merge branch 'Mario/casing_disconect_fix' into 'master'
authorterencehill <piuntn@gmail.com>
Sun, 24 May 2020 18:17:24 +0000 (18:17 +0000)
committerterencehill <piuntn@gmail.com>
Sun, 24 May 2020 18:17:24 +0000 (18:17 +0000)
Possibly fixes #1925, seeing as the disconnect is rare it is unknown whether this fix truly solves it, needs testing.

See merge request xonotic/xonotic-data.pk3dir!816

qcsrc/common/physics/movetypes/movetypes.qc

index 63aa3dd955716971d60c1c7c794cf7ee5a4ad6b1..7894d14fd856bb1a8e09a4401fd88259ee940320 100644 (file)
@@ -747,7 +747,7 @@ void Movetype_Physics_MatchTicrate(entity this, float tr, bool sloppy)  // SV_Ph
 
        float dt = time - this.move_time;
 
-       int n = max(0, floor(dt / tr));
+       int n = bound(0, floor(dt / tr), 32); // limit the number of frames to 32 (CL_MAX_USERCMDS, using DP_SMALLMEMORY value for consideration of QC's limitations)
        dt -= n * tr;
        this.move_time += n * tr;