Fix clan nameplate alignment

This commit is contained in:
KebsCS 2024-09-15 02:32:58 +02:00
parent 0feee9aa3e
commit 8aa8c4ee01
No known key found for this signature in database
GPG key ID: 5A8C0761A75E7309

View file

@ -172,9 +172,11 @@ void CNamePlates::RenderNameplate(vec2 Position, const CNetObj_PlayerInfo *pPlay
if(g_Config.m_ClNameplatesClan) if(g_Config.m_ClNameplatesClan)
{ {
YOffset -= FontSizeClan;
if(NamePlate.m_ClanTextContainerIndex.Valid()) if(NamePlate.m_ClanTextContainerIndex.Valid())
{
YOffset -= FontSizeClan;
TextRender()->RenderTextContainer(NamePlate.m_ClanTextContainerIndex, TColor, TOutlineColor, Position.x - TextRender()->GetBoundingBoxTextContainer(NamePlate.m_ClanTextContainerIndex).m_W / 2.0f, YOffset); TextRender()->RenderTextContainer(NamePlate.m_ClanTextContainerIndex, TColor, TOutlineColor, Position.x - TextRender()->GetBoundingBoxTextContainer(NamePlate.m_ClanTextContainerIndex).m_W / 2.0f, YOffset);
}
} }
if(g_Config.m_ClNameplatesFriendMark && ClientData.m_Friend) if(g_Config.m_ClNameplatesFriendMark && ClientData.m_Friend)