From 9071d3a28b7e6abe7a28a0cf4279dab3480dfb29 Mon Sep 17 00:00:00 2001 From: div0 Date: Mon, 21 Jan 2008 19:36:35 +0000 Subject: [PATCH] minor fixes in onslaught (like, destroyed control point should no longer provide spawns) git-svn-id: svn://svn.icculus.org/nexuiz/trunk@3212 f962a42d-fe04-0410-a3ab-8c8b0445ebaa --- data/qcsrc/server/miscfunctions.qc | 2 +- data/qcsrc/server/mode_onslaught.qc | 10 +++++++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/data/qcsrc/server/miscfunctions.qc b/data/qcsrc/server/miscfunctions.qc index 7fe7e92ef..4c79eadc0 100644 --- a/data/qcsrc/server/miscfunctions.qc +++ b/data/qcsrc/server/miscfunctions.qc @@ -186,7 +186,7 @@ void relocate_spawnpoint() setsize(self, PL_MIN, PL_MAX); droptofloor(); } - if (game == 10/*GAME_ONSLAUGHT*/ || cvar("g_onslaught")) // xavior: game modes should be defined in defs.. leaving this here temp + if (g_onslaught) self.use = onslaught_spawnpoint_use; } diff --git a/data/qcsrc/server/mode_onslaught.qc b/data/qcsrc/server/mode_onslaught.qc index aff20bb37..9cf16691f 100644 --- a/data/qcsrc/server/mode_onslaught.qc +++ b/data/qcsrc/server/mode_onslaught.qc @@ -310,6 +310,7 @@ void() onslaught_generator = void(entity inflictor, entity attacker, float damage, float deathtype, vector hitloc, vector force) onslaught_controlpoint_icon_damage = { + entity oself; if (damage <= 0) return; if (self.owner.isshielded) @@ -345,6 +346,13 @@ void(entity inflictor, entity attacker, float damage, float deathtype, vector hi self.owner.team = 0; self.owner.colormap = 1024; onslaught_updatelinks(); + + // Use targets now (somebody make sure this is in the right place..) + self = self.owner; + activator = self.owner; + SUB_UseTargets (); + self = oself; + remove(self); } }; @@ -566,4 +574,4 @@ void() onslaught_link = void() onslaught_spawnpoint_use = { self.team = activator.team; -}; \ No newline at end of file +}; -- 2.39.2