diff options
| author | oy <Tom_Adams@web.de> | 2011-03-27 11:52:16 +0200 |
|---|---|---|
| committer | oy <Tom_Adams@web.de> | 2011-03-27 11:52:16 +0200 |
| commit | d4f2b8de87807ded7b194b2c8b18cc63a6981860 (patch) | |
| tree | 87dffef0484e7b3d72b9da1438f930d579c48ebd | |
| parent | 722644008f05dee4994c955b89be1d2342077d32 (diff) | |
| download | zcatch-d4f2b8de87807ded7b194b2c8b18cc63a6981860.tar.gz zcatch-d4f2b8de87807ded7b194b2c8b18cc63a6981860.zip | |
fixed skin colour of spectators
| -rw-r--r-- | src/game/client/gameclient.cpp | 7 | ||||
| -rw-r--r-- | src/game/server/gamecontroller.cpp | 7 |
2 files changed, 12 insertions, 2 deletions
diff --git a/src/game/client/gameclient.cpp b/src/game/client/gameclient.cpp index 76b51831..fab347e9 100644 --- a/src/game/client/gameclient.cpp +++ b/src/game/client/gameclient.cpp @@ -1015,13 +1015,18 @@ void CGameClient::CClientData::UpdateRenderInfo() // force team colors if(g_GameClient.m_Snap.m_pGameInfoObj && g_GameClient.m_Snap.m_pGameInfoObj->m_GameFlags&GAMEFLAG_TEAMS) { + m_RenderInfo.m_Texture = g_GameClient.m_pSkins->Get(m_SkinID)->m_ColorTexture; const int TeamColors[2] = {65387, 10223467}; if(m_Team >= TEAM_RED && m_Team <= TEAM_BLUE) { - m_RenderInfo.m_Texture = g_GameClient.m_pSkins->Get(m_SkinID)->m_ColorTexture; m_RenderInfo.m_ColorBody = g_GameClient.m_pSkins->GetColorV4(TeamColors[m_Team]); m_RenderInfo.m_ColorFeet = g_GameClient.m_pSkins->GetColorV4(TeamColors[m_Team]); } + else + { + m_RenderInfo.m_ColorBody = g_GameClient.m_pSkins->GetColorV4(12895054); + m_RenderInfo.m_ColorFeet = g_GameClient.m_pSkins->GetColorV4(12895054); + } } } diff --git a/src/game/server/gamecontroller.cpp b/src/game/server/gamecontroller.cpp index c61168f9..c5a96570 100644 --- a/src/game/server/gamecontroller.cpp +++ b/src/game/server/gamecontroller.cpp @@ -367,12 +367,17 @@ void IGameController::OnPlayerInfoChange(class CPlayer *pP) const int aTeamColors[2] = {65387, 10223467}; if(IsTeamplay()) { + pP->m_TeeInfos.m_UseCustomColor = 1; if(pP->GetTeam() >= TEAM_RED && pP->GetTeam() <= TEAM_BLUE) { - pP->m_TeeInfos.m_UseCustomColor = 1; pP->m_TeeInfos.m_ColorBody = aTeamColors[pP->GetTeam()]; pP->m_TeeInfos.m_ColorFeet = aTeamColors[pP->GetTeam()]; } + else + { + pP->m_TeeInfos.m_ColorBody = 12895054; + pP->m_TeeInfos.m_ColorFeet = 12895054; + } } } |