about summary refs log tree commit diff
path: root/src/game/server
diff options
context:
space:
mode:
authoroy <Tom_Adams@web.de>2011-06-09 22:31:55 +0200
committeroy <Tom_Adams@web.de>2011-06-09 22:31:55 +0200
commit348806d993598a26025fc90dbfa022f495232420 (patch)
treee9fdbc40be2a14919ac5e1eb1531a4ce89e06140 /src/game/server
parent2cc10fd6f02696f9657ffcde27be076942bf443b (diff)
downloadzcatch-348806d993598a26025fc90dbfa022f495232420.tar.gz
zcatch-348806d993598a26025fc90dbfa022f495232420.zip
abort "move to spectator"-vote when the player disconnects
Diffstat (limited to 'src/game/server')
-rw-r--r--src/game/server/gamecontext.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/game/server/gamecontext.cpp b/src/game/server/gamecontext.cpp
index f71bc6fc..5fe25f2c 100644
--- a/src/game/server/gamecontext.cpp
+++ b/src/game/server/gamecontext.cpp
@@ -343,7 +343,8 @@ void CGameContext::SendVoteStatus(int ClientID, int Total, int Yes, int No)
 
 void CGameContext::AbortVoteKickOnDisconnect(int ClientID)
 {
-	if(m_VoteCloseTime && !str_comp_num(m_aVoteCommand, "kick ", 5) && str_toint(&m_aVoteCommand[5]) == ClientID)
+	if(m_VoteCloseTime && ((!str_comp_num(m_aVoteCommand, "kick ", 5) && str_toint(&m_aVoteCommand[5]) == ClientID) ||
+		(!str_comp_num(m_aVoteCommand, "set_team ", 9) && str_toint(&m_aVoteCommand[9]) == ClientID)))
 		m_VoteCloseTime = -1;
 }