mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 01:58:19 +00:00
Merge #1691
1691: Persist show_ips setting on map changes r=Learath2 a=def- @12pm Co-authored-by: def <dennis@felsin9.de>
This commit is contained in:
commit
9bca330a73
|
@ -257,7 +257,6 @@ void CServer::CClient::Reset()
|
|||
m_Score = 0;
|
||||
m_NextMapChunk = 0;
|
||||
m_Flags = 0;
|
||||
m_ShowIps = false;
|
||||
}
|
||||
|
||||
CServer::CServer()
|
||||
|
@ -472,6 +471,7 @@ int CServer::Init()
|
|||
m_aClients[i].m_Snapshots.Init();
|
||||
m_aClients[i].m_Traffic = 0;
|
||||
m_aClients[i].m_TrafficSince = 0;
|
||||
m_aClients[i].m_ShowIps = false;
|
||||
m_aClients[i].m_AuthKey = -1;
|
||||
}
|
||||
|
||||
|
@ -847,6 +847,7 @@ int CServer::NewClientNoAuthCallback(int ClientID, void *pUser)
|
|||
pThis->m_aClients[ClientID].m_AuthKey = -1;
|
||||
pThis->m_aClients[ClientID].m_AuthTries = 0;
|
||||
pThis->m_aClients[ClientID].m_pRconCmdToSend = 0;
|
||||
pThis->m_aClients[ClientID].m_ShowIps = false;
|
||||
pThis->m_aClients[ClientID].Reset();
|
||||
|
||||
pThis->SendMap(ClientID);
|
||||
|
@ -871,6 +872,7 @@ int CServer::NewClientCallback(int ClientID, void *pUser)
|
|||
pThis->m_aClients[ClientID].m_pRconCmdToSend = 0;
|
||||
pThis->m_aClients[ClientID].m_Traffic = 0;
|
||||
pThis->m_aClients[ClientID].m_TrafficSince = 0;
|
||||
pThis->m_aClients[ClientID].m_ShowIps = false;
|
||||
memset(&pThis->m_aClients[ClientID].m_Addr, 0, sizeof(NETADDR));
|
||||
pThis->m_aClients[ClientID].Reset();
|
||||
pThis->GameServer()->OnClientEngineJoin(ClientID);
|
||||
|
@ -950,6 +952,7 @@ int CServer::DelClientCallback(int ClientID, const char *pReason, void *pUser)
|
|||
pThis->m_aClients[ClientID].m_pRconCmdToSend = 0;
|
||||
pThis->m_aClients[ClientID].m_Traffic = 0;
|
||||
pThis->m_aClients[ClientID].m_TrafficSince = 0;
|
||||
pThis->m_aClients[ClientID].m_ShowIps = false;
|
||||
pThis->m_aPrevStates[ClientID] = CClient::STATE_EMPTY;
|
||||
pThis->m_aClients[ClientID].m_Snapshots.PurgeAll();
|
||||
|
||||
|
|
Loading…
Reference in a new issue