From 19e342b0463a6faf992ac4ed7fb19a0b9e65da0b Mon Sep 17 00:00:00 2001 From: Rudolf Polzer Date: Fri, 30 Mar 2012 15:01:37 +0200 Subject: [PATCH] sv_vote_nospectators, sv_chat_nospectators: treat warmup and gameover state the same. --- qcsrc/server/cl_player.qc | 2 +- qcsrc/server/command/vote.qc | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/qcsrc/server/cl_player.qc b/qcsrc/server/cl_player.qc index 5a1627423..334474966 100644 --- a/qcsrc/server/cl_player.qc +++ b/qcsrc/server/cl_player.qc @@ -979,7 +979,7 @@ float Say(entity source, float teamsay, entity privatesay, string msgin, float f if(source.classname != "player") { if not(intermission_running) - if(teamsay || (autocvar_g_chat_nospectators == 1) || (autocvar_g_chat_nospectators == 2 && !inWarmupStage)) + if(teamsay || (autocvar_g_chat_nospectators == 1) || (autocvar_g_chat_nospectators == 2 && !(inWarmupStage || gameover))) teamsay = -1; // spectators } diff --git a/qcsrc/server/command/vote.qc b/qcsrc/server/command/vote.qc index 4cd4f1156..1e4356400 100644 --- a/qcsrc/server/command/vote.qc +++ b/qcsrc/server/command/vote.qc @@ -191,7 +191,7 @@ void VoteCount(float first_count) vote_accept_count = vote_reject_count = vote_abstain_count = 0; float spectators_allowed = ((autocvar_sv_vote_nospectators != 2) - || ((autocvar_sv_vote_nospectators == 1) && inWarmupStage) + || ((autocvar_sv_vote_nospectators == 1) && (inWarmupStage || gameover)) || (autocvar_sv_vote_nospectators == 0)); float vote_player_count, is_player, notvoters; @@ -997,4 +997,4 @@ void VoteCommand(float request, entity caller, float argc, string vote_command) return; } } -} \ No newline at end of file +} -- 2.39.2