[nexuiz-commits] r8204 - in trunk/data/qcsrc: common server

DONOTREPLY at icculus.org DONOTREPLY at icculus.org
Wed Nov 4 08:03:03 EST 2009


Author: tzork
Date: 2009-11-04 08:03:02 -0500 (Wed, 04 Nov 2009)
New Revision: 8204

Modified:
   trunk/data/qcsrc/common/constants.qh
   trunk/data/qcsrc/server/g_damage.qc
Log:
New DEATH_'s

Modified: trunk/data/qcsrc/common/constants.qh
===================================================================
--- trunk/data/qcsrc/common/constants.qh	2009-11-03 20:39:30 UTC (rev 8203)
+++ trunk/data/qcsrc/common/constants.qh	2009-11-04 13:03:02 UTC (rev 8204)
@@ -272,7 +272,16 @@
 const float STAT_HUD = 50;
 const float HUD_NORMAL = 0;
 const float HUD_SPIDERBOT = 10;
+const float HUD_WAKIZASHI = 11;
 
+const float STAT_VEHICLESTAT_HEALTH  = 60;
+const float STAT_VEHICLESTAT_SHIELD  = 61;
+const float STAT_VEHICLESTAT_ENERGY  = 62;
+const float STAT_VEHICLESTAT_AMMO1   = 63;
+const float STAT_VEHICLESTAT_RELOAD1 = 64;
+const float STAT_VEHICLESTAT_AMMO2   = 65;
+const float STAT_VEHICLESTAT_RELOAD2 = 66;
+
 const float STAT_SPIDERBOT_HEALTH  = 60;
 const float STAT_SPIDERBOT_ROCKETS = 61;
 const float STAT_SPIDERBOT_HEAT    = 62;
@@ -281,7 +290,6 @@
 const float STAT_SPIDERBOT_SHIELD  = 65;
 
 //const float STAT_SPIDERBOT_AIM     53 // compressShotOrigin
-
 //const float STAT_SPIDERBOT_TARGET  54 // compressShotOrigin
 
 
@@ -441,8 +449,20 @@
 float DEATH_TOUCHEXPLODE = 10015;
 float DEATH_CHEAT = 10016;
 float DEATH_FIRE = 10017;
-float DEATH_TURRET = 10100;
+float DEATH_TURRET = 10020;
 
+float DEATH_SBMINIGUN = 10030;
+float DEATH_SBROCKET  = 10031;
+float DEATH_SBCRUSH   = 10032;
+float DEATH_SBBLOWUP  = 10033;
+
+float DEATH_WAKIGUN    = 10040;
+float DEATH_WAKIROCKET = 10041;
+float DEATH_WAKIBLOWUP = 10042;
+
+float DEATH_CUSTOM = 10300;
+
+
 float DEATH_WEAPONMASK = 0xFF;
 float DEATH_HITTYPEMASK = 0x1F00; // which is WAY below 10000 used for normal deaths
 float HITTYPE_SECONDARY = 0x100;

Modified: trunk/data/qcsrc/server/g_damage.qc
===================================================================
--- trunk/data/qcsrc/server/g_damage.qc	2009-11-03 20:39:30 UTC (rev 8203)
+++ trunk/data/qcsrc/server/g_damage.qc	2009-11-04 13:03:02 UTC (rev 8204)
@@ -236,6 +236,7 @@
 			s = "A corpse";
 		else
 			s = targ.netname;
+
 		a = attacker.netname;
 
 		if (targ == attacker)
@@ -376,7 +377,7 @@
 					if((cvar("sv_fragmessage_information_typefrag")) && (targ.BUTTON_CHAT)) {
 						centerprint(attacker, strcat(DAMAGE_CENTERPRINT_SPACER, blood_message, "^1You typefragged ^7", s, GetAdvancedDeathReports(targ)));
 						centerprint(targ, strcat(DAMAGE_CENTERPRINT_SPACER, victim_message, "^1You were typefragged by ^7", a, GetAdvancedDeathReports(attacker)));
-					} else { 
+					} else {
 						centerprint(attacker, strcat(DAMAGE_CENTERPRINT_SPACER, blood_message, "^4You fragged ^7", s, GetAdvancedDeathReports(targ)));
 						centerprint(targ, strcat(DAMAGE_CENTERPRINT_SPACER, victim_message, "^1You were fragged by ^7", a, GetAdvancedDeathReports(attacker)));
 					}
@@ -420,6 +421,22 @@
 						else
 							bprint("^1", s, "^1 ", substring(inflictor.message2, 0, p), a, "^1", substring(inflictor.message2, p+1, strlen(inflictor.message2) - (p+1)), "\n");
 					}
+					else if(deathtype == DEATH_SBCRUSH)
+                        bprint ("^1",s, "^1 was crushed by ^1", a, "\n");
+					else if(deathtype == DEATH_SBMINIGUN)
+                        bprint ("^1",s, "^1 got shredded by ^1", a, "\n");
+					else if(deathtype == DEATH_SBROCKET)
+                        bprint ("^1",s, "^1 was blased to bits by ^1", a, "\n");
+					else if(deathtype == DEATH_SBBLOWUP)
+                        bprint ("^1",s, "^1 got cought in the destruction of ^1", a, "'s vehicle\n");
+
+					else if(deathtype == DEATH_WAKIGUN)
+                        bprint ("^1",s, "^1 was bolted down by ^1", a, "\n");
+					else if(deathtype == DEATH_WAKIROCKET)
+                        bprint ("^1",s, "^1 could find no shelter from ^1", a, "'s rockets\n");
+					else if(deathtype == DEATH_WAKIBLOWUP)
+                        bprint ("^1",s, "^1 dies when ^1", a, "'s wakizashi dies.\n");
+
 					else if(deathtype == DEATH_TURRET)
 						bprint ("^1",s, "^1 was pushed into the line of fire by ^1", a, "\n");
 					else if(deathtype == DEATH_TOUCHEXPLODE)
@@ -427,7 +444,9 @@
 					else if(deathtype == DEATH_CHEAT)
 						bprint ("^1",s, "^1 was unfairly eliminated by ^1", a, "\n");
 					else if (deathtype == DEATH_FIRE)
-						bprint ("^1",s, "^1 was burnt to death by ^1", a, "\n");
+					bprint ("^1",s, "^1 was burnt to death by ^1", a, "\n");
+					else if (deathtype == DEATH_CUSTOM)
+						bprint ("^1",s, "^1 ", deathmessage, " by ^1", a, "\n");
 					else
 						bprint ("^1",s, "^1 was fragged by ", a, "\n");
 				}
@@ -555,6 +574,8 @@
 					bprint ("^1",s, "^1 is now conserved for centuries to come\n");
 			else if(deathtype == DEATH_TURRET)
 				bprint ("^1",s, "^1 was mowed down by a turret \n");
+            else if (deathtype == DEATH_CUSTOM)
+                bprint ("^1",s, "^1 ", deathmessage, "\n");
 			else if(deathtype == DEATH_TOUCHEXPLODE)
 				bprint ("^1",s, "^1 died in an accident\n");
 			else if(deathtype == DEATH_CHEAT)
@@ -582,9 +603,11 @@
 
 			LogDeath("accident", deathtype, targ, targ);
 		}
+
 		targ.death_origin = targ.origin;
 		if(targ != attacker)
 			targ.killer_origin = attacker.origin;
+
 		// FIXME: this should go in PutClientInServer
 		if (targ.killcount)
 			targ.killcount = 0;



More information about the nexuiz-commits mailing list