Initial work on the actual bot.
This commit is contained in:
parent
41e3b9ab85
commit
f104fa41f3
18
init.lua
Normal file
18
init.lua
Normal file
@ -0,0 +1,18 @@
|
||||
local socket = require "socket"
|
||||
local serialization = require "serialization"
|
||||
|
||||
local config = {}
|
||||
|
||||
function loadconfig()
|
||||
local f = io.open("config.lua","rb")
|
||||
local content = f:read("*a")
|
||||
f:close()
|
||||
config = serialization.unserialize(dat)
|
||||
end
|
||||
|
||||
function saveconfig()
|
||||
local newconfig = serialization.serialize(config)
|
||||
local f = io.open("config.lua","rb")
|
||||
f:write(newconfig)
|
||||
f:close()
|
||||
end
|
Loading…
Reference in New Issue
Block a user