add lua logging facilities as Util.Log*() functions

This commit is contained in:
Lion Kortlepel
2024-04-19 11:10:50 +02:00
parent e2d7721438
commit 1237e7e533
2 changed files with 29 additions and 0 deletions

View File

@@ -214,6 +214,10 @@ void RegisterThread(const std::string& str);
do { \
Application::Console().Write(_this_location + std::string("[LUA ERROR] ") + (x)); \
} while (false)
#define beammp_lua_log(level, plugin, x) \
do { \
Application::Console().Write(_this_location + fmt::format("[{}] [{}] ", plugin, level) + (x)); \
} while (false)
#define beammp_lua_warn(x) \
do { \
Application::Console().Write(_this_location + std::string("[LUA WARN] ") + (x)); \