Add server identification packet

This commit is contained in:
Tixx committed 2024-10-14 00:39:12 +02:00
1 parent 4f052a3e0a
commit 6aeb2eb736
3 files changed
+8 -2

No files matched your search

+3 -2
View File
@@ -140,8 +140,7 @@ void THeartbeatThread::operator()() {
std::string THeartbeatThread::GenerateCall() {
std::stringstream Ret;
Ret << "uuid=" << Application::Settings.getAsString(Settings::Key::General_AuthKey)
<< "&players=" << mServer.ClientCount()
Ret << "players=" << mServer.ClientCount()
<< "&maxplayers=" << Application::Settings.getAsInt(Settings::Key::General_MaxPlayers)
<< "&port=" << Application::Settings.getAsInt(Settings::Key::General_Port)
<< "&map=" << Application::Settings.getAsString(Settings::Key::General_Map)
@@ -156,6 +155,8 @@ std::string THeartbeatThread::GenerateCall() {
<< "&modstotal=" << mResourceManager.ModsLoaded()
<< "&playerslist=" << GetPlayers()
<< "&desc=" << Application::Settings.getAsString(Settings::Key::General_Description);
lastCall = Ret.str();
Ret << "&uuid=" << Application::Settings.getAsString(Settings::Key::General_AuthKey);
return Ret.str();
}
THeartbeatThread::THeartbeatThread(TResourceManager& ResourceManager, TServer& Server)