mirror of
https://github.com/BeamMP/BeamMP-Server.git
synced 2025-07-01 23:35:41 +00:00
change version cmd behaviour
This commit is contained in:
parent
c880460a55
commit
06e5805428
@ -26,7 +26,9 @@
|
||||
#include "TLuaEngine.h"
|
||||
|
||||
#include <ctime>
|
||||
#include <lua.hpp>
|
||||
#include <mutex>
|
||||
#include <openssl/opensslv.h>
|
||||
#include <sstream>
|
||||
|
||||
static inline bool StringStartsWith(const std::string& What, const std::string& StartsWith) {
|
||||
@ -273,7 +275,25 @@ void TConsole::Command_Version(const std::string& cmd, const std::vector<std::st
|
||||
return;
|
||||
}
|
||||
|
||||
Application::Console().WriteRaw("Current version: v" + Application::ServerVersionString());
|
||||
std::string platform;
|
||||
#if defined(BEAMMP_WINDOWS)
|
||||
platform = "Windows";
|
||||
#elif defined(BEAMMP_LINUX)
|
||||
platform = "Linux";
|
||||
#elif defined(BEAMMP_FREEBSD)
|
||||
platform = "FreeBSD";
|
||||
#elif defined(BEAMMP_APPLE)
|
||||
platform = "Apple";
|
||||
#else
|
||||
platform = "Unknown";
|
||||
#endif
|
||||
|
||||
Application::Console().WriteRaw("Platform: " + platform);
|
||||
Application::Console().WriteRaw("Server: v" + Application::ServerVersionString());
|
||||
std::string lua_version = fmt::format("Lua: v{}.{}.{}", LUA_VERSION_MAJOR, LUA_VERSION_MINOR, LUA_VERSION_RELEASE);
|
||||
Application::Console().WriteRaw(lua_version);
|
||||
std::string openssl_version = fmt::format("OpenSSL: v{}.{}.{}", OPENSSL_VERSION_MAJOR, OPENSSL_VERSION_MINOR, OPENSSL_VERSION_PATCH);
|
||||
Application::Console().WriteRaw(openssl_version);
|
||||
}
|
||||
|
||||
void TConsole::Command_Kick(const std::string&, const std::vector<std::string>& args) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user