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

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Wed Oct 21 12:27:13 EDT 2009


Author: div0
Date: 2009-10-21 12:27:12 -0400 (Wed, 21 Oct 2009)
New Revision: 8164

Modified:
   trunk/data/qcsrc/server/movelib.qc
Log:
fix warning


Modified: trunk/data/qcsrc/server/movelib.qc
===================================================================
--- trunk/data/qcsrc/server/movelib.qc	2009-10-20 20:16:31 UTC (rev 8163)
+++ trunk/data/qcsrc/server/movelib.qc	2009-10-21 16:27:12 UTC (rev 8164)
@@ -53,7 +53,7 @@
 }
 
 .float  movelib_lastupdate;
-void movelib_move(vector force,float max_velocity,float drag,float mass,float breakforce)
+void movelib_move(vector force,float max_velocity,float drag,float theMass,float breakforce)
 {
     float deltatime;
     float acceleration;
@@ -67,8 +67,8 @@
 
     mspeed = vlen(self.velocity);
 
-    if (mass)
-        acceleration = vlen(force) / mass;
+    if (theMass)
+        acceleration = vlen(force) / theMass;
     else
         acceleration = vlen(force);
 
@@ -76,7 +76,7 @@
     {
         if (breakforce)
         {
-            breakvec = (normalize(self.velocity) * (breakforce / mass) * deltatime);
+            breakvec = (normalize(self.velocity) * (breakforce / theMass) * deltatime);
             self.velocity = self.velocity - breakvec;
         }
 
@@ -102,7 +102,7 @@
 }
 
 /*
-.float mass;
+.float theMass;
 .float side_friction;
 .float ground_friction;
 .float air_friction;
@@ -137,9 +137,9 @@
     old_speed    = vlen(self.velocity);
     old_dir      = normalize(self.velocity);
 
-    //ggravity      =  (sv_gravity / self.mass) * '0 0 100';
-    acceleration =  (force / self.mass) * dir;
-    //acceleration -= old_dir * (old_speed / self.mass);
+    //ggravity      =  (sv_gravity / self.theMass) * '0 0 100';
+    acceleration =  (force / self.theMass) * dir;
+    //acceleration -= old_dir * (old_speed / self.theMass);
     acceleration -= ggravity;
 
     if(self.waterlevel > 1)



More information about the nexuiz-commits mailing list