[nexuiz-commits] r7613 - trunk/data/qcsrc/server

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Thu Sep 3 13:01:38 EDT 2009


Author: lordhavoc
Date: 2009-09-03 13:01:38 -0400 (Thu, 03 Sep 2009)
New Revision: 7613

Modified:
   trunk/data/qcsrc/server/g_triggers.qc
Log:
rewrote acceleration/damping mode in trigger_impulse to work properly
with ticrates other than 0.05


Modified: trunk/data/qcsrc/server/g_triggers.qc
===================================================================
--- trunk/data/qcsrc/server/g_triggers.qc	2009-09-03 16:27:41 UTC (rev 7612)
+++ trunk/data/qcsrc/server/g_triggers.qc	2009-09-03 17:01:38 UTC (rev 7613)
@@ -1173,8 +1173,9 @@
     other.lastpushtime = time;
     if(!pushdeltatime) return;
 
+    // LordHavoc: rewrote this velocity math (was * self.strength * pushdeltatime) to make it less ticrate dependent
     //if(self.strength > 1)
-        other.velocity = other.velocity * (self.strength * pushdeltatime);
+        other.velocity = other.velocity * (1 + (self.strength - 20) * pushdeltatime);
     //else
     //    other.velocity = other.velocity - (other.velocity * self.strength * pushdeltatime);
 }



More information about the nexuiz-commits mailing list