Merge pull request #1623 from p-mcgowan/issue_1253
Prevent multiple logins with same username, unless allowed in settings
This commit is contained in:
16
src/Root.cpp
16
src/Root.cpp
@@ -643,6 +643,22 @@ bool cRoot::DoWithPlayerByUUID(const AString & a_PlayerUUID, cPlayerListCallback
|
||||
|
||||
|
||||
|
||||
bool cRoot::DoWithPlayer(const AString & a_PlayerName, cPlayerListCallback & a_Callback)
|
||||
{
|
||||
for (auto World : m_WorldsByName)
|
||||
{
|
||||
if (World.second->DoWithPlayer(a_PlayerName, a_Callback))
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
AString cRoot::GetProtocolVersionTextFromInt(int a_ProtocolVersion)
|
||||
{
|
||||
return cProtocolRecognizer::GetVersionTextFromInt(a_ProtocolVersion);
|
||||
|
||||
Reference in New Issue
Block a user