aboutsummaryrefslogtreecommitdiff
path: root/advtrains
diff options
context:
space:
mode:
Diffstat (limited to 'advtrains')
-rw-r--r--advtrains/log.lua6
1 files changed, 1 insertions, 5 deletions
diff --git a/advtrains/log.lua b/advtrains/log.lua
index d2b71d3..2913904 100644
--- a/advtrains/log.lua
+++ b/advtrains/log.lua
@@ -3,11 +3,7 @@
advtrains.log = function() end
if minetest.settings:get_bool("advtrains_enable_logging") then
- advtrains.logfile = advtrains.fpath .. "_log"
-
function advtrains.log (event, player, pos, data)
- local log = io.open(advtrains.logfile, "a+")
- log:write(os.date()..": "..event.." by "..player.." at "..minetest.pos_to_string(pos).." -- "..(data or "").."\n")
- log:close()
+ minetest.log("action", "advtrains: " ..event.." by "..player.." at "..minetest.pos_to_string(pos).." -- "..(data or ""))
end
end