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

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Mon Feb 15 12:30:24 EST 2010


Author: div0
Date: 2010-02-15 12:30:24 -0500 (Mon, 15 Feb 2010)
New Revision: 8648

Modified:
   trunk/data/qcsrc/server/t_items.qc
Log:
fix glowmod use (we can't use that before 2.6)

Modified: trunk/data/qcsrc/server/t_items.qc
===================================================================
--- trunk/data/qcsrc/server/t_items.qc	2010-02-14 20:11:37 UTC (rev 8647)
+++ trunk/data/qcsrc/server/t_items.qc	2010-02-15 17:30:24 UTC (rev 8648)
@@ -47,7 +47,9 @@
 		return TRUE;
 	if(self.weapons != (self.weapons & other.weapons))
 	{
-		self.colormod = self.glowmod = stov(cvar_string("g_ghost_items_color"));
+		self.colormod = '0 0 0';
+		if(cvar("gameversion") >= 20600) // only do this for 2.6 and above FIXME remove this check when making 2.6
+			self.glowmod = self.colormod;
 		self.alpha = 0.5 + 0.5 * g_ghost_items; // halfway more alpha
 		return TRUE;
 	}
@@ -55,7 +57,9 @@
 	{
 		if(g_ghost_items)
 		{
-			self.colormod = self.glowmod = stov(cvar_string("g_ghost_items_color"));
+			self.colormod = stov(cvar_string("g_ghost_items_color"));
+			if(cvar("gameversion") >= 20600) // only do this for 2.6 and above FIXME remove this check when making 2.6
+				self.glowmod = self.colormod;
 			self.alpha = g_ghost_items;
 			return TRUE;
 		}
@@ -72,7 +76,9 @@
 		// make the item look normal, and be touchable
 		e.model = e.mdl;
 		e.solid = SOLID_TRIGGER;
-		e.colormod = e.glowmod = '0 0 0';
+		e.colormod = '0 0 0';
+		if(cvar("gameversion") >= 20600) // only do this for 2.6 and above FIXME remove this check when making 2.6
+			self.glowmod = self.colormod;
 		e.alpha = 0;
 		e.customizeentityforclient = func_null;
 
@@ -83,7 +89,9 @@
 		// hide the item completely
 		e.model = string_null;
 		e.solid = SOLID_NOT;
-		//e.colormod = '0 0 0';
+		e.colormod = '0 0 0';
+		if(cvar("gameversion") >= 20600) // only do this for 2.6 and above FIXME remove this check when making 2.6
+			self.glowmod = self.colormod;
 		e.alpha = 0;
 		e.customizeentityforclient = func_null;
 
@@ -94,9 +102,10 @@
 		// make the item translucent green and not touchable
 		e.model = e.mdl;
 		e.solid = SOLID_TRIGGER; // can STILL be picked up!
+		e.colormod = '0 0 0';
+		if(cvar("gameversion") >= 20600) // only do this for 2.6 and above FIXME remove this check when making 2.6
+			self.glowmod = self.colormod;
 		e.effects |= EF_STARDUST;
-		//e.colormod = '0.2 1 0.2';
-		//e.alpha = 0.5; // will be overridden by CEFC though...
 		e.customizeentityforclient = Item_Customize;
 
 		e.spawnshieldtime = 0; // field indicates whether picking it up may give you anything other than the weapon
@@ -106,7 +115,9 @@
 		// make the item translucent green and not touchable
 		e.model = e.mdl;
 		e.solid = SOLID_NOT;
-		e.colormod = e.glowmod = stov(cvar_string("g_ghost_items_color"));
+		e.colormod = stov(cvar_string("g_ghost_items_color"));
+		if(cvar("gameversion") >= 20600) // only do this for 2.6 and above FIXME remove this check when making 2.6
+			self.glowmod = self.colormod;
 		e.alpha = g_ghost_items;
 		e.customizeentityforclient = func_null;
 
@@ -117,7 +128,9 @@
 		// hide the item completely
 		e.model = string_null;
 		e.solid = SOLID_NOT;
-		//e.colormod = '0 0 0';
+		e.colormod = stov(cvar_string("g_ghost_items_color"));
+		if(cvar("gameversion") >= 20600) // only do this for 2.6 and above FIXME remove this check when making 2.6
+			self.glowmod = self.colormod;
 		e.alpha = 0;
 		e.customizeentityforclient = func_null;
 



More information about the nexuiz-commits mailing list