mirror of
https://github.com/BeamMP/BeamMP-Server.git
synced 2026-02-16 10:41:01 +00:00
update players info
This commit is contained in:
committed by
Anonymous275
parent
bca4b3f140
commit
13f8be5d39
@@ -56,7 +56,7 @@ private:
|
||||
static inline std::deque<TShutdownHandler> mShutdownHandlers {};
|
||||
};
|
||||
|
||||
/*
|
||||
#ifndef DEBUG
|
||||
static inline void warn(const std::string& str) {
|
||||
Application::Console().Write(std::string("[WARN] ") + str);
|
||||
}
|
||||
@@ -72,9 +72,9 @@ static inline void debug(const std::string& str) {
|
||||
}
|
||||
}
|
||||
static inline void luaprint(const std::string& str) {
|
||||
Application::Console().Write(std::string("[LUA] ") + str);
|
||||
Application::Console().WriteRaw(str);
|
||||
}
|
||||
*/
|
||||
#else // DEBUG
|
||||
|
||||
#define warn(x) Application::Console().Write(std::string(__PRETTY_FUNCTION__) + ":" + std::to_string(__LINE__) + std::string(" [WARN] ") + (x))
|
||||
#define info(x) Application::Console().Write(std::string(__PRETTY_FUNCTION__) + ":" + std::to_string(__LINE__) + std::string(" [INFO] ") + (x))
|
||||
@@ -86,6 +86,7 @@ static inline void luaprint(const std::string& str) {
|
||||
Application::Console().Write(std::string(__PRETTY_FUNCTION__) + ":" + std::to_string(__LINE__) + std::string(" [DEBUG] ") + (x)); \
|
||||
} \
|
||||
} while (false)
|
||||
#endif // DEBUG
|
||||
|
||||
#define Biggest 30000
|
||||
std::string Comp(std::string Data);
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
#pragma once
|
||||
|
||||
#include "TLuaFile.h"
|
||||
#include "commandline/commandline.h"
|
||||
#include <atomic>
|
||||
#include <fstream>
|
||||
@@ -9,7 +10,10 @@ public:
|
||||
TConsole();
|
||||
|
||||
void Write(const std::string& str);
|
||||
void WriteRaw(const std::string& str);
|
||||
void InitializeLuaConsole(TLuaEngine& Engine);
|
||||
|
||||
private:
|
||||
std::unique_ptr<TLuaFile> mLuaConsole { nullptr };
|
||||
Commandline mCommandline;
|
||||
};
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
#ifndef TLUAENGINE_H
|
||||
#define TLUAENGINE_H
|
||||
#pragma once
|
||||
|
||||
#include "Common.h"
|
||||
#include "IThreaded.h"
|
||||
@@ -12,6 +11,7 @@
|
||||
class TLuaEngine : public IThreaded {
|
||||
public:
|
||||
explicit TLuaEngine(TServer& Server, TTCPServer& TCPServer, TUDPServer& UDPServer);
|
||||
~TLuaEngine();
|
||||
|
||||
using TSetOfLuaFile = std::set<std::unique_ptr<TLuaFile>>;
|
||||
|
||||
@@ -38,5 +38,3 @@ private:
|
||||
bool mShutdown { false };
|
||||
TSetOfLuaFile mLuaFiles;
|
||||
};
|
||||
|
||||
#endif // TLUAENGINE_H
|
||||
|
||||
@@ -11,6 +11,7 @@ class TResourceManager;
|
||||
class TTCPServer : public IThreaded {
|
||||
public:
|
||||
explicit TTCPServer(TServer& Server, TPPSMonitor& PPSMonitor, TResourceManager& ResourceManager);
|
||||
~TTCPServer();
|
||||
|
||||
void operator()() override;
|
||||
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
class TUDPServer : public IThreaded {
|
||||
public:
|
||||
explicit TUDPServer(TServer& Server, TPPSMonitor& PPSMonitor, TTCPServer& TCPServer);
|
||||
~TUDPServer();
|
||||
|
||||
void operator()() override;
|
||||
|
||||
@@ -21,6 +22,7 @@ private:
|
||||
TPPSMonitor& mPPSMonitor;
|
||||
TTCPServer& mTCPServer;
|
||||
SOCKET mUDPSock {};
|
||||
bool mShutdown { false };
|
||||
|
||||
std::string UDPRcvFromClient(sockaddr_in& client) const;
|
||||
};
|
||||
Submodule include/commandline updated: 01ec8e0388...19184df67e
Reference in New Issue
Block a user