|
|
@ -36,8 +36,7 @@ end
|
|
|
|
|
|
|
|
|
|
|
|
--Sets mode
|
|
|
|
--Sets mode
|
|
|
|
function tools.setMode(mode)
|
|
|
|
function tools.setMode(mode)
|
|
|
|
local file = io.open("./docs/mode", "r+")
|
|
|
|
local file = io.open("./docs/mode", "w")
|
|
|
|
io.input(file)
|
|
|
|
|
|
|
|
io.output(file)
|
|
|
|
io.output(file)
|
|
|
|
file:seek("set", 0)
|
|
|
|
file:seek("set", 0)
|
|
|
|
if mode == "test" then
|
|
|
|
if mode == "test" then
|
|
|
@ -52,7 +51,7 @@ function tools.setMode(mode)
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
function tools.getMode()
|
|
|
|
function tools.getMode()
|
|
|
|
local file = io.open("./docs/mode", "r+")
|
|
|
|
local file = io.open("./docs/mode", "r")
|
|
|
|
io.input(file)
|
|
|
|
io.input(file)
|
|
|
|
file:seek("set", 0)
|
|
|
|
file:seek("set", 0)
|
|
|
|
local mode = file:read()
|
|
|
|
local mode = file:read()
|
|
|
|