From fe03dd6f2b4a9a45433961dca9ab51432da0fe64 Mon Sep 17 00:00:00 2001 From: terencehill Date: Sat, 7 Jan 2012 22:29:29 +0100 Subject: [PATCH] The ca code doesn't use the field spawned so don't check it Also fix a typo in a comment --- qcsrc/server/cl_client.qc | 8 +++----- qcsrc/server/command/cmd.qc | 2 +- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/qcsrc/server/cl_client.qc b/qcsrc/server/cl_client.qc index 7bf685e252..08d513fcf4 100644 --- a/qcsrc/server/cl_client.qc +++ b/qcsrc/server/cl_client.qc @@ -655,7 +655,7 @@ void PutClientInServer (void) WriteByte(MSG_ONE, SVC_SETVIEW); WriteEntity(MSG_ONE, self); } - + // reset player keys self.itemkeys = 0; @@ -667,8 +667,7 @@ void PutClientInServer (void) self.classname = "observer"; } - if(g_arena || (g_ca && !allowed_to_spawn)) - if(!self.spawned) + if((g_arena && !self.spawned) || (g_ca && !allowed_to_spawn)) self.classname = "observer"; if(gameover) @@ -826,13 +825,12 @@ void PutClientInServer (void) self.lastrocket = world; // stop rocket guiding, no revenge from the grave! self.lastteleporttime = time; // prevent insane speeds due to changing origin self.hud = HUD_NORMAL; - + if(g_arena) { Spawnqueue_Remove(self); Spawnqueue_Mark(self); } - else if(g_ca) self.caplayer = 1; diff --git a/qcsrc/server/command/cmd.qc b/qcsrc/server/command/cmd.qc index 5a7eb03ff6..4f2a7456cc 100644 --- a/qcsrc/server/command/cmd.qc +++ b/qcsrc/server/command/cmd.qc @@ -445,7 +445,7 @@ void ClientCommand_spectate(float request) if(self.classname == "player" && autocvar_sv_spectate == 1) ClientKill_TeamChange(-2); // observe - // in CA, allow a dead player to move to spectatators (without that, caplayer!=0 will be moved back to the player list) + // in CA, allow a dead player to move to spectators (without that, caplayer!=0 will be moved back to the player list) // note: if arena game mode is ever done properly, this needs to be removed. if(g_ca && self.caplayer && (self.classname == "spectator" || self.classname == "observer")) { -- 2.39.2