1
0

Tentative fix for player-limit race condition (#3862)

* Attempts to fix #2257

Derived from d233e9843148313c71fbaba96ccff660e47b07b1

* Changed player count type to int

* Clarified certain actions
This commit is contained in:
Tiger Wang
2017-07-28 17:54:40 +01:00
committed by GitHub
parent e0a44fb3bc
commit eb4432bb62
12 changed files with 61 additions and 95 deletions

View File

@@ -146,8 +146,6 @@ cPlayer::cPlayer(cClientHandlePtr a_Client, const AString & a_PlayerName) :
m_IsFlying = true;
m_bVisible = false;
}
cRoot::Get()->GetServer()->PlayerCreated(this);
}
@@ -183,9 +181,6 @@ cPlayer::~cPlayer(void)
LOGD("Deleting cPlayer \"%s\" at %p, ID %d", GetName().c_str(), static_cast<void *>(this), GetUniqueID());
// Notify the server that the player is being destroyed
cRoot::Get()->GetServer()->PlayerDestroying(this);
SaveToDisk();
m_ClientHandle = nullptr;