From 47c55655ac8044e901e5ce3b3b34597982724f43 Mon Sep 17 00:00:00 2001 From: Teetime Date: Fri, 3 Aug 2012 21:28:12 +0200 Subject: Teamchat works now properly with caught and living players and those who are explicit in spectators --- src/game/server/gamecontext.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/game/server/gamecontext.cpp b/src/game/server/gamecontext.cpp index 96d8364b..3967f49d 100644 --- a/src/game/server/gamecontext.cpp +++ b/src/game/server/gamecontext.cpp @@ -261,7 +261,8 @@ void CGameContext::SendChat(int ChatterClientID, int Team, const char *pText) // send to the clients for(int i = 0; i < MAX_CLIENTS; i++) { - if(m_apPlayers[i] && m_apPlayers[i]->GetTeam() == Team) + //if(m_apPlayers[i] && m_apPlayers[i]->GetTeam() == Team) + if(m_apPlayers[i] && ChatterClientID >= 0 && ChatterClientID < MAX_CLIENTS && m_apPlayers[ChatterClientID] && m_apPlayers[ChatterClientID]->m_SpecExplicit == m_apPlayers[i]->m_SpecExplicit) Server()->SendPackMsg(&Msg, MSGFLAG_VITAL|MSGFLAG_NORECORD, i); } } -- cgit 1.4.1