From: MirceaKitsune Date: Sat, 9 Jul 2011 19:13:52 +0000 (+0300) Subject: Apply weight based speed reduction in a different area of the code. Much smoother... X-Git-Url: http://de.git.xonotic.org/?p=voretournament%2Fvoretournament.git;a=commitdiff_plain;h=54c486005eb8d590baa3bc207627f74df19670c2 Apply weight based speed reduction in a different area of the code. Much smoother and more realistic, now affecting actual acceleration as well --- diff --git a/data/qcsrc/server/cl_physics.qc b/data/qcsrc/server/cl_physics.qc index 6b41a2cf..1f3a6d65 100644 --- a/data/qcsrc/server/cl_physics.qc +++ b/data/qcsrc/server/cl_physics.qc @@ -509,6 +509,8 @@ void PM_Accelerate(vector wishdir, float wishspeed, float wishspeed0, float acce wishspeed *= (1 - cvar("g_healthsize_movementfactor")) + cvar("g_healthsize_movementfactor") * self.scale; if(self.swallow_progress_prey) // cut speed based on swallow progress wishspeed *= 1 - (self.swallow_progress_prey * cvar("g_balance_vore_swallow_speed_cutspd")); + if(cvar("g_balance_vore_weight_gravity") > 0) + wishspeed *= 1 - bound(0, self.stomach_load * cvar("g_balance_vore_weight_speed"), 1); // apply stomach weight if(cvar("sv_gameplayfix_q2airaccelerate")) wishspeed0 = wishspeed; @@ -827,8 +829,6 @@ void SV_PlayerPhysics() } maxspd_mod *= swampspd_mod; // only one common speed modder please! - if(cvar("g_balance_vore_weight_gravity") > 0) - maxspd_mod *= 1 - bound(0, self.stomach_load * cvar("g_balance_vore_weight_speed"), 1); // apply stomach weight swampspd_mod = 1; // if dead, behave differently