aboutsummaryrefslogtreecommitdiff
path: root/gamemode/shared/log.lua
diff options
context:
space:
mode:
Diffstat (limited to 'gamemode/shared/log.lua')
-rw-r--r--gamemode/shared/log.lua48
1 files changed, 35 insertions, 13 deletions
diff --git a/gamemode/shared/log.lua b/gamemode/shared/log.lua
index 1ede67f..ad5da46 100644
--- a/gamemode/shared/log.lua
+++ b/gamemode/shared/log.lua
@@ -4,20 +4,42 @@ local col = nrequire("colortheme.lua")
local log = {}
log.debug = fn.compose(
- fn.curry(
- MsgC,
- col.console.cyan),
- fn.curry(
- string.format,
- "[DEBUG] %s"))
+ fn.curry(
+ MsgC,
+ col.console.cyan
+ ),
+ fn.curry(
+ string.format,
+ "[DEBUG] %s"
+ )
+)
+
+log.info = fn.compose(
+ fn.curry(
+ MsgC,
+ col.console.blue
+ ),
+ fn.curry(
+ string.format,
+ "[INFO] %s"
+ )
+)
log.warn = fn.compose(
- fn.curry(
- MsgC,
- col.console.yellow),
- debug.traceback,
- fn.curry(
- ErrorNoHalt,
- "[WARNING]"))
+ fn.curry(
+ MsgC,
+ col.console.yellow
+ ),
+ debug.traceback,
+ fn.curry(
+ ErrorNoHalt,
+ "[WARNING]"
+ )
+)
+
+log.report = fn.curry(
+ file.Append,
+ "artery/report_log.txt"
+)
return log