]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - sv_phys.c
added more SV_CheckVelocity calls on players for safety sake
[xonotic/darkplaces.git] / sv_phys.c
index 4b2f1a1b9add0f34dc4df16c9f85edca30a80a5d..5847ad5219ac144e77fa01b105918a9a2acca626 100644 (file)
--- a/sv_phys.c
+++ b/sv_phys.c
@@ -1074,6 +1074,8 @@ void SV_Physics_Client (edict_t *ent, int num)
        if (!svs.clients[num-1].active)
                return;         // unconnected slot
 
+       SV_CheckVelocity (ent);
+
        // call standard client pre-think
        pr_global_struct->time = sv.time;
        pr_global_struct->self = EDICT_TO_PROG(ent);
@@ -1124,9 +1126,13 @@ void SV_Physics_Client (edict_t *ent, int num)
                Host_Error ("SV_Physics_client: bad movetype %i", (int)ent->v->movetype);
        }
 
+       SV_CheckVelocity (ent);
+
        // call standard player post-think
        SV_LinkEdict (ent, true);
 
+       SV_CheckVelocity (ent);
+
        pr_global_struct->time = sv.time;
        pr_global_struct->self = EDICT_TO_PROG(ent);
        PR_ExecuteProgram (pr_global_struct->PlayerPostThink, "QC function PlayerPostThink is missing");