about summary refs log tree commit diff
path: root/src/engine
diff options
context:
space:
mode:
authoroy <Tom_Adams@web.de>2011-03-20 11:15:24 +0100
committeroy <Tom_Adams@web.de>2011-03-20 11:15:24 +0100
commit79aa9d640e5b258e6698d5d86adf190e02dcf866 (patch)
tree18e5009fe3adf888a8c261569c2ebc2b7e4f9e1f /src/engine
parent3a7d93e182a518e9cc89aec72e9975bfae762ebb (diff)
downloadzcatch-79aa9d640e5b258e6698d5d86adf190e02dcf866.tar.gz
zcatch-79aa9d640e5b258e6698d5d86adf190e02dcf866.zip
fixed that server browser shows the correct country flag
Diffstat (limited to 'src/engine')
-rw-r--r--src/engine/client.h1
-rw-r--r--src/engine/client/client.cpp2
2 files changed, 2 insertions, 1 deletions
diff --git a/src/engine/client.h b/src/engine/client.h
index 31b6f794..870c355d 100644
--- a/src/engine/client.h
+++ b/src/engine/client.h
@@ -159,6 +159,7 @@ public:
 	virtual int OnSnapInput(int *pData) = 0;
 	
 	virtual const char *GetItemName(int Type) = 0;
+	virtual int GetCountryIndex(int Code) = 0;
 	virtual const char *Version() = 0;
 	virtual const char *NetVersion() = 0;
 
diff --git a/src/engine/client/client.cpp b/src/engine/client/client.cpp
index 7277cecd..723b8791 100644
--- a/src/engine/client/client.cpp
+++ b/src/engine/client/client.cpp
@@ -1119,7 +1119,7 @@ void CClient::ProcessConnlessPacket(CNetChunk *pPacket)
 		{
 			str_copy(Info.m_aPlayers[i].m_aName, Up.GetString(CUnpacker::SANITIZE_CC|CUnpacker::SKIP_START_WHITESPACES), sizeof(Info.m_aPlayers[i].m_aName));
 			str_copy(Info.m_aPlayers[i].m_aClan, Up.GetString(CUnpacker::SANITIZE_CC|CUnpacker::SKIP_START_WHITESPACES), sizeof(Info.m_aPlayers[i].m_aClan));
-			Info.m_aPlayers[i].m_Country = str_toint(Up.GetString());
+			Info.m_aPlayers[i].m_Country = GameClient()->GetCountryIndex(str_toint(Up.GetString()));
 			Info.m_aPlayers[i].m_Score = str_toint(Up.GetString());
 		}