From: MirceaKitsune Date: Sun, 18 Mar 2012 13:26:10 +0000 (+0200) Subject: Fix a major bug causing darkplaces to crash during the campaign (and possibly other... X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=a33705c42fba10fbbd5947821f2e55e9c276451b;p=voretournament%2Fvoretournament.git Fix a major bug causing darkplaces to crash during the campaign (and possibly other cases). Seems like a fteqcc bug is causing this, so word the code differently which seems to fix the problem. --- diff --git a/data/qcsrc/server/t_items.qc b/data/qcsrc/server/t_items.qc index b363e337..0c02da26 100644 --- a/data/qcsrc/server/t_items.qc +++ b/data/qcsrc/server/t_items.qc @@ -407,7 +407,7 @@ void Item_DroppedConsumable_Spawn(entity e) item.angles_y = e.predator.angles_y; makevectors(e.predator.v_angle); item.velocity = v_forward * cvar("g_balance_vore_regurgitate_force") * scalediff; - e.predator.velocity += -v_forward * cvar("g_balance_vore_regurgitate_predatorforce") * scalediff; + e.predator.velocity = e.predator.velocity + (-v_forward * cvar("g_balance_vore_regurgitate_predatorforce") * scalediff); // don't use += here to avoid a fteqcc bug item.touch = Item_DroppedConsumable_Touch; item.cnt = time + 1; // 1 second delay SUB_SetFade(item, time + 20, 1); diff --git a/data/qcsrc/server/vore.qc b/data/qcsrc/server/vore.qc index 79fcc210..b88e2802 100644 --- a/data/qcsrc/server/vore.qc +++ b/data/qcsrc/server/vore.qc @@ -409,7 +409,7 @@ void Vore_Regurgitate(entity e) // apply velocities makevectors(e.predator.v_angle); e.velocity = v_forward * cvar("g_balance_vore_regurgitate_force") * scalediff; - e.predator.velocity += -v_forward * cvar("g_balance_vore_regurgitate_predatorforce") * scalediff; + e.predator.velocity = e.predator.velocity + (-v_forward * cvar("g_balance_vore_regurgitate_predatorforce") * scalediff); // don't use += here to avoid a fteqcc bug e.pusher = e.predator; // allows us to frag players by regurgitating them in deadly pits e.pushltime = time + cvar("g_maxpushtime");