mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 10:08:18 +00:00
Merge #3105
3105: Optimize nameplate rendering. Fix #3103 r=def- a=Learath2 Removes the unnecessary `SnapFindItem` (which is a linear search, ew) Co-authored-by: Learath <learath2@gmail.com>
This commit is contained in:
commit
5a8fe3d2b4
|
@ -216,8 +216,7 @@ void CNamePlates::OnRender()
|
|||
|
||||
for(int i = 0; i < MAX_CLIENTS; i++)
|
||||
{
|
||||
const void *pInfoRaw = Client()->SnapFindItem(IClient::SNAP_CURRENT, NETOBJTYPE_PLAYERINFO, i);
|
||||
const CNetObj_PlayerInfo *pInfo = (CNetObj_PlayerInfo *)pInfoRaw;
|
||||
const CNetObj_PlayerInfo *pInfo = m_pClient->m_Snap.m_paPlayerInfos[i];
|
||||
if(!pInfo)
|
||||
{
|
||||
continue;
|
||||
|
|
Loading…
Reference in a new issue