diff --git a/src/game/client/components/menus_browser.cpp b/src/game/client/components/menus_browser.cpp index 9c95931d6a1..b68b1ed6926 100644 --- a/src/game/client/components/menus_browser.cpp +++ b/src/game/client/components/menus_browser.cpp @@ -519,23 +519,27 @@ void CMenus::RenderServerbrowserStatusBox(CUIRect StatusBox, bool WasListboxItem } // render status - char aBufSvr[128]; - char aBufPyr[128]; - if(ServerBrowser()->NumServers() != 1) - str_format(aBufSvr, sizeof(aBufSvr), Localize("%d of %d servers"), ServerBrowser()->NumSortedServers(), ServerBrowser()->NumServers()); - else - str_format(aBufSvr, sizeof(aBufSvr), Localize("%d of %d server"), ServerBrowser()->NumSortedServers(), ServerBrowser()->NumServers()); - if(NumPlayers != 1) - str_format(aBufPyr, sizeof(aBufPyr), Localize("%d players"), NumPlayers); - else - str_format(aBufPyr, sizeof(aBufPyr), Localize("%d player"), NumPlayers); - - CUIRect SvrsOnline, PlysOnline; - Status3.HSplitTop(20.f, &PlysOnline, &SvrsOnline); - PlysOnline.VSplitRight(TextRender()->TextWidth(12.0f, aBufPyr, -1, -1.0f), 0, &PlysOnline); - UI()->DoLabel(&PlysOnline, aBufPyr, 12.0f, TEXTALIGN_LEFT); - SvrsOnline.VSplitRight(TextRender()->TextWidth(12.0f, aBufSvr, -1, -1.0f), 0, &SvrsOnline); - UI()->DoLabel(&SvrsOnline, aBufSvr, 12.0f, TEXTALIGN_LEFT); + { + CUIRect ServersOnline, PlayersOnline; + ServersPlayersOnline.HSplitMid(&PlayersOnline, &ServersOnline); + + char aBuf[128]; + if(ServerBrowser()->NumServers() != 1) + str_format(aBuf, sizeof(aBuf), Localize("%d of %d servers"), ServerBrowser()->NumSortedServers(), ServerBrowser()->NumServers()); + else + str_format(aBuf, sizeof(aBuf), Localize("%d of %d server"), ServerBrowser()->NumSortedServers(), ServerBrowser()->NumServers()); + UI()->DoLabel(&ServersOnline, aBuf, 12.0f, TEXTALIGN_MR); + + int NumPlayers = 0; + for(int i = 0; i < ServerBrowser()->NumSortedServers(); i++) + NumPlayers += ServerBrowser()->SortedGet(i)->m_NumFilteredPlayers; + + if(NumPlayers != 1) + str_format(aBuf, sizeof(aBuf), Localize("%d players"), NumPlayers); + else + str_format(aBuf, sizeof(aBuf), Localize("%d player"), NumPlayers); + UI()->DoLabel(&PlayersOnline, aBuf, 12.0f, TEXTALIGN_MR); + } // status box { diff --git a/src/game/client/components/menus_settings.cpp b/src/game/client/components/menus_settings.cpp index adf2b9d51a0..45a67eaec69 100644 --- a/src/game/client/components/menus_settings.cpp +++ b/src/game/client/components/menus_settings.cpp @@ -3477,11 +3477,11 @@ void CMenus::RenderSettingsTClient(CUIRect MainView) Button.VSplitLeft(120.0f, &KeyLabel, &Button); Button.VSplitLeft(100, &Button, 0); char aBuf[64]; - str_format(aBuf, sizeof(aBuf), "%s:", Localize((const char *)Key.m_Name)); + str_format(aBuf, sizeof(aBuf), "%s:", Localize((const char *)Key.m_pName)); UI()->DoLabel(&KeyLabel, aBuf, 20.0f, TEXTALIGN_LEFT); int OldId = Key.m_KeyId, OldModifierCombination = Key.m_ModifierCombination, NewModifierCombination; - int NewId = DoKeyReader((void *)&Key.m_Name, &Button, OldId, OldModifierCombination, &NewModifierCombination); + int NewId = DoKeyReader((void *)&Key.m_pName, &Button, OldId, OldModifierCombination, &NewModifierCombination); if(NewId != OldId || NewModifierCombination != OldModifierCombination) { if(OldId != 0 || NewId == 0) @@ -3612,11 +3612,11 @@ void CMenus::RenderSettingsTClient(CUIRect MainView) Button.VSplitLeft(120.0f, &KeyLabel, &Button); Button.VSplitLeft(100, &Button, 0); char aBuf[64]; - str_format(aBuf, sizeof(aBuf), "%s:", Localize((const char *)Key.m_Name)); + str_format(aBuf, sizeof(aBuf), "%s:", Localize((const char *)Key.m_pName)); UI()->DoLabel(&KeyLabel, aBuf, 13.0f, TEXTALIGN_LEFT); int OldId = Key.m_KeyId, OldModifierCombination = Key.m_ModifierCombination, NewModifierCombination; - int NewId = DoKeyReader((void *)&Key.m_Name, &Button, OldId, OldModifierCombination, &NewModifierCombination); + int NewId = DoKeyReader((void *)&Key.m_pName, &Button, OldId, OldModifierCombination, &NewModifierCombination); if(NewId != OldId || NewModifierCombination != OldModifierCombination) { if(OldId != 0 || NewId == 0) diff --git a/src/game/client/components/outlines.cpp b/src/game/client/components/outlines.cpp index 8ef6261596f..c7a54ca6024 100644 --- a/src/game/client/components/outlines.cpp +++ b/src/game/client/components/outlines.cpp @@ -13,7 +13,7 @@ void COutlines::OnRender() { - if(GameClient()->m_MapLayersBackGround.m_OnlineOnly && Client()->State() != IClient::STATE_ONLINE && Client()->State() != IClient::STATE_DEMOPLAYBACK) + if(GameClient()->m_MapLayersBackground.m_OnlineOnly && Client()->State() != IClient::STATE_ONLINE && Client()->State() != IClient::STATE_DEMOPLAYBACK) return; if(!g_Config.m_ClOverlayEntities && g_Config.m_ClOutlineEntities) return; diff --git a/src/game/client/components/players.cpp b/src/game/client/components/players.cpp index 412ec154804..ca9526b3ab9 100644 --- a/src/game/client/components/players.cpp +++ b/src/game/client/components/players.cpp @@ -1261,8 +1261,9 @@ void CPlayers::OnRender() m_aRenderInfo[i].m_TeeRenderFlags |= TEE_EFFECT_FROZEN; const CGameClient::CSnapState::CCharacterInfo &CharacterInfo = m_pClient->m_Snap.m_aCharacters[i]; - if (((CharacterInfo.m_Cur.m_Weapon == WEAPON_NINJA || Frozen) && g_Config.m_ClShowNinja) || (g_Config.m_ClAmIFrozen && g_Config.m_ClFreezeUpdateFix - && m_pClient->m_Snap.m_LocalClientID == i && g_Config.m_ClShowNinja) || (Frozen && !m_pClient->m_GameInfo.m_NoSkinChangeForFrozen && g_Config.m_ClShowNinja)) + const bool Frozen = CharacterInfo.m_HasExtendedData && CharacterInfo.m_ExtendedData.m_FreezeEnd != 0; + + if(((CharacterInfo.m_Cur.m_Weapon == WEAPON_NINJA || Frozen) && g_Config.m_ClShowNinja) || (g_Config.m_ClAmIFrozen && g_Config.m_ClFreezeUpdateFix && m_pClient->m_Snap.m_LocalClientID == i && g_Config.m_ClShowNinja) || (Frozen && !m_pClient->m_GameInfo.m_NoSkinChangeForFrozen && g_Config.m_ClShowNinja)) { // change the skin for the player to the ninja const auto *pSkin = m_pClient->m_Skins.FindOrNullptr("x_ninja");