1
0
forked from MTSR/mapserver
mapserver/doc/wip/advtrains_interlock_dump.lua
2019-06-07 10:39:25 +02:00

11 lines
315 B
Lua

minetest.after(2, function()
local world_path = minetest.get_worldpath()
local file, err = io.open(world_path .. "advtrains.json", "w")
local data = advtrains.interlocking.db.save()
local json = minetest.write_json(data.ts, true)
file:write(json)
file:close()
end)