From: Samual Date: Wed, 28 Mar 2012 01:03:03 +0000 (-0400) Subject: Make the flag respawn when it touches lava/slime X-Git-Tag: xonotic-v0.7.0~240^2~166 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=813189df5306eba08834471c030bc49240e97989;p=xonotic%2Fxonotic-data.pk3dir.git Make the flag respawn when it touches lava/slime --- diff --git a/qcsrc/server/mutators/gamemode_ctf.qc b/qcsrc/server/mutators/gamemode_ctf.qc index 3cfff880f..df151f64b 100644 --- a/qcsrc/server/mutators/gamemode_ctf.qc +++ b/qcsrc/server/mutators/gamemode_ctf.qc @@ -436,8 +436,8 @@ void ctf_FlagTouch() { if(gameover) { return; } if(!self) { return; } - if(trace_dphitq3surfaceflags & Q3SURFACEFLAG_NOIMPACT) - { // The flag fell off the map, respawn it since players can't get to it + if((trace_dphitq3surfaceflags & Q3SURFACEFLAG_NOIMPACT) || (trace_dphitcontents & (DPCONTENTS_SLIME | DPCONTENTS_LAVA))) + { // The flag fell off the map or into lava/slime, respawn it since players can't get to it ctf_RespawnFlag(self); return; } @@ -508,6 +508,7 @@ void ctf_Reset() ctf_Handle_Drop(self.owner); ctf_RespawnFlag(self); + print("ctf reset\n"); } void ctf_SetupFlag(float teamnumber, entity flag) // called when spawning a flag entity on the map as a spawnfunc