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

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Mon Jun 22 02:33:16 EDT 2009


Author: div0
Date: 2009-06-22 02:33:16 -0400 (Mon, 22 Jun 2009)
New Revision: 7075

Modified:
   trunk/data/qcsrc/server/cl_weaponsystem.qc
   trunk/data/qcsrc/server/g_subs.qc
Log:
fix teleport bit handling: only when restarting the SAME anim


Modified: trunk/data/qcsrc/server/cl_weaponsystem.qc
===================================================================
--- trunk/data/qcsrc/server/cl_weaponsystem.qc	2009-06-21 20:23:07 UTC (rev 7074)
+++ trunk/data/qcsrc/server/cl_weaponsystem.qc	2009-06-22 06:33:16 UTC (rev 7075)
@@ -1137,11 +1137,6 @@
 			a_z *= g_weaponspeedfactor;
 			setanim(self.weaponentity, a, restartanim == FALSE, restartanim, restartanim);
 		}
-
-		if(restartanim)
-		{
-			BITXOR_ASSIGN(self.weaponentity.effects, EF_TELEPORT_BIT);
-		}
 	}
 
 	v_forward = of;

Modified: trunk/data/qcsrc/server/g_subs.qc
===================================================================
--- trunk/data/qcsrc/server/g_subs.qc	2009-06-21 20:23:07 UTC (rev 7074)
+++ trunk/data/qcsrc/server/g_subs.qc	2009-06-22 06:33:16 UTC (rev 7075)
@@ -16,11 +16,18 @@
 
 void setanim(entity e, vector anim, float looping, float override, float restart)
 {
-	if (!restart)
 	if (anim_x == e.animstate_startframe)
 	if (anim_y == e.animstate_numframes)
 	if (anim_z == e.animstate_framerate)
-		return;
+	{
+		if(restart)
+		{
+			if(anim_y == 1) // ZYM animation
+				BITXOR_ASSIGN(e.effects, EF_TELEPORT_BIT);
+		}
+		else
+			return;
+	}
 	e.animstate_startframe = anim_x;
 	e.animstate_numframes = anim_y;
 	e.animstate_framerate = anim_z;



More information about the nexuiz-commits mailing list