summaryrefslogtreecommitdiffstats
path: root/src/Server.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/Server.cpp18
1 files changed, 18 insertions, 0 deletions
diff --git a/src/Server.cpp b/src/Server.cpp
index d6163df7e..3eaf6e096 100644
--- a/src/Server.cpp
+++ b/src/Server.cpp
@@ -196,6 +196,7 @@ bool cServer::InitServer(cIniFile & a_SettingsIni, bool a_ShouldAuth)
m_Description = a_SettingsIni.GetValueSet("Server", "Description", "MCServer - in C++!");
m_MaxPlayers = a_SettingsIni.GetValueSetI("Server", "MaxPlayers", 100);
m_bIsHardcore = a_SettingsIni.GetValueSetB("Server", "HardcoreEnabled", false);
+ m_bAllowMultiLogin = a_SettingsIni.GetValueSetB("Server", "AllowMultiLogin", false);
m_PlayerCount = 0;
m_PlayerCountDiff = 0;
@@ -298,6 +299,23 @@ int cServer::GetNumPlayers(void) const
+bool cServer::IsPlayerInQueue(AString a_Username)
+{
+ cCSLock Lock(m_CSClients);
+ for (auto client : m_Clients)
+ {
+ if ((client->GetUsername()).compare(a_Username) == 0)
+ {
+ return true;
+ }
+ }
+ return false;
+}
+
+
+
+
+
void cServer::PrepareKeys(void)
{
LOGD("Generating protocol encryption keypair...");