Moved tables file to be first file

master
Austin Shenk 2013-01-05 23:56:30 -05:00
parent 17db6429ee
commit 9fb793b959
1 changed files with 16 additions and 11 deletions

View File

@ -1,19 +1,24 @@
--run Files
local init = io.open(minetest.get_worldpath().."/adventures_init", "w")
if(init == nil) then
init:write("initialized")
init:close()
local file = io.open(minetest.get_worldpath().."/adventures_sources", "w")
file:write("initialized")
file:close()
local file = io.open(minetest.get_worldpath().."/adventures_previousmode", "w")
file:write("initialized")
file:close()
local file = io.open(minetest.get_worldpath().."/adventures_init", "r")
if(file == nil) then
print("Initialize")
io.output(minetest.get_worldpath().."/adventures_init")
io.write("initialized")
io.flush()
io.close()
io.output(minetest.get_worldpath().."/adventures_sources")
io.write("initialized")
io.flush()
io.close()
io.output(minetest.get_worldpath().."/adventures_previousmode")
io.write("initialized")
io.flush()
io.close()
end
local modpath=minetest.get_modpath("adventures")
dofile(modpath.."/decode.lua")
dofile(modpath.."/tables.lua")
dofile(modpath.."/decode.lua")
local creative = minetest.setting_get("creative_mode")
if creative then dofile(modpath.."/creative.lua")
else dofile(modpath.."/standard.lua")