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

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Thu Aug 20 20:06:47 EDT 2009


Author: mand1nga
Date: 2009-08-20 20:06:46 -0400 (Thu, 20 Aug 2009)
New Revision: 7481

Modified:
   trunk/data/qcsrc/server/miscfunctions.qc
   trunk/data/qcsrc/server/t_items.qc
   trunk/data/qcsrc/server/w_minstanex.qc
Log:
Minstanex fixes by terencehil (#484)

Modified: trunk/data/qcsrc/server/miscfunctions.qc
===================================================================
--- trunk/data/qcsrc/server/miscfunctions.qc	2009-08-20 20:02:45 UTC (rev 7480)
+++ trunk/data/qcsrc/server/miscfunctions.qc	2009-08-21 00:06:46 UTC (rev 7481)
@@ -1525,6 +1525,7 @@
     precache_sound ("announcer/robotic/1fragleft.wav");
     precache_sound ("announcer/robotic/2fragsleft.wav");
     precache_sound ("announcer/robotic/3fragsleft.wav");
+    precache_sound ("announcer/robotic/terminated.wav");
     if (g_minstagib)
     {
         precache_sound ("announcer/robotic/lastsecond.wav");

Modified: trunk/data/qcsrc/server/t_items.qc
===================================================================
--- trunk/data/qcsrc/server/t_items.qc	2009-08-20 20:02:45 UTC (rev 7480)
+++ trunk/data/qcsrc/server/t_items.qc	2009-08-21 00:06:46 UTC (rev 7481)
@@ -175,10 +175,13 @@
 			pickedup = TRUE;
 			// play some cool sounds ;)
 			centerprint(player, "\n");
-			if(player.health <= 5)
-				announce(player, "announcer/robotic/lastsecond.wav");
-			else if(player.health < 50)
-				announce(player, "announcer/robotic/narrowly.wav");
+			if (clienttype(player) == CLIENTTYPE_REAL)
+			{
+				if(player.health <= 5)
+					play2(player, "announcer/robotic/lastsecond.wav");
+				else if(player.health < 50)
+					play2(player, "announcer/robotic/narrowly.wav");
+			}
 			// sound not available
 			// else if(item.items == IT_CELLS)
 			//	play2(player, "announce/robotic/ammo.wav");

Modified: trunk/data/qcsrc/server/w_minstanex.qc
===================================================================
--- trunk/data/qcsrc/server/w_minstanex.qc	2009-08-20 20:02:45 UTC (rev 7480)
+++ trunk/data/qcsrc/server/w_minstanex.qc	2009-08-21 00:06:46 UTC (rev 7481)
@@ -99,65 +99,66 @@
 			Damage(self, self, self, 5, DEATH_NOAMMO, self.origin, '0 0 0');
 			announce(self, "announcer/robotic/terminated.wav");
 		}
-		if (self.health == 10)
+		else if (self.health == 10)
 		{
 			centerprint(self, "^11^7 second left to find some ammo\n");
 			Damage(self, self, self, 5, DEATH_NOAMMO, self.origin, '0 0 0');
 			announce(self, "announcer/robotic/1.wav");
 		}
-		if (self.health == 20)
+		else if (self.health == 20)
 		{
 			centerprint(self, "^12^7 seconds left to find some ammo\n");
 			Damage(self, self, self, 10, DEATH_NOAMMO, self.origin, '0 0 0');
 			announce(self, "announcer/robotic/2.wav");
 		}
-		if (self.health == 30)
+		else if (self.health == 30)
 		{
 			centerprint(self, "^13^7 seconds left to find some ammo\n");
 			Damage(self, self, self, 10, DEATH_NOAMMO, self.origin, '0 0 0');
 			announce(self, "announcer/robotic/3.wav");
 		}
-		if (self.health == 40)
+		else if (self.health == 40)
 		{
 			centerprint(self, "^14^7 seconds left to find some ammo\n");
 			Damage(self, self, self, 10, DEATH_NOAMMO, self.origin, '0 0 0');
 			announce(self, "announcer/robotic/4.wav");
 		}
-		if (self.health == 50)
+		else if (self.health == 50)
 		{
 			centerprint(self, "^15^7 seconds left to find some ammo\n");
 			Damage(self, self, self, 10, DEATH_NOAMMO, self.origin, '0 0 0');
 			announce(self, "announcer/robotic/5.wav");
 		}
-		if (self.health == 60)
+		else if (self.health == 60)
 		{
 			centerprint(self, "^36^7 seconds left to find some ammo\n");
 			Damage(self, self, self, 10, DEATH_NOAMMO, self.origin, '0 0 0');
 			announce(self, "announcer/robotic/6.wav");
 		}
-		if (self.health == 70)
+		else if (self.health == 70)
 		{
 			centerprint(self, "^37^7 seconds left to find some ammo\n");
 			Damage(self, self, self, 10, DEATH_NOAMMO, self.origin, '0 0 0');
 			announce(self, "announcer/robotic/7.wav");
 		}
-		if (self.health == 80)
+		else if (self.health == 80)
 		{
 			centerprint(self, "^38^7 seconds left to find some ammo\n");
 			Damage(self, self, self, 10, DEATH_NOAMMO, self.origin, '0 0 0');
 			announce(self, "announcer/robotic/8.wav");
 		}
-		if (self.health == 90)
+		else if (self.health == 90)
 		{
 			centerprint(self, "^39^7 seconds left to find some ammo\n");
 			Damage(self, self, self, 10, DEATH_NOAMMO, self.origin, '0 0 0');
 			announce(self, "announcer/robotic/9.wav");
 		}
-		if (self.health == 100)
+		else if (self.health == 100)
 		{
 			centerprint(self, "get some ammo or\nyou'll be dead in ^310^7 seconds...");
 			Damage(self, self, self, 10, DEATH_NOAMMO, self.origin, '0 0 0');
-			announce(self, "announcer/robotic/10.wav");
+			if not(self.flags & FL_GODMODE)
+				announce(self, "announcer/robotic/10.wav");
 		}
 	}
 	self.minstagib_nextthink = time + 1;



More information about the nexuiz-commits mailing list