diff --git a/lua/gmod_integration/shared/sh_main.lua b/lua/gmod_integration/shared/sh_main.lua index d2d283d..ab63faf 100644 --- a/lua/gmod_integration/shared/sh_main.lua +++ b/lua/gmod_integration/shared/sh_main.lua @@ -2,8 +2,15 @@ // Functions // +// Log function gmInte.log(msg, debug) if (debug && !gmInte.config.debug) then return end - //format: [2021-08-01 00:00:00] [INFO] msg print("[" .. os.date("%Y-%m-%d %H:%M:%S") .. "] [Gmod Integration] " .. msg) +end + +// Log Error +function gmInte.logError(msg, debug) + if (debug && !gmInte.config.debug) then return end + print("[" .. os.date("%Y-%m-%d %H:%M:%S") .. "] [Gmod Integration] [ERROR] " .. msg) + print(debug.traceback()) end \ No newline at end of file