local files = { "util.lua", "command.lua", "hook.lua", "config.lua" } table.foreach(files, function(_, f) dofile(f) end) function onMessage(channel, sender, login, hostname, message) if command.IsCommand(message) then local res = command.SplitCommand(message) command.Call(res.com, command.MSG, sender, channel, res.arg) end end function onJoin(channel, sender, login, hostname) end function onPrivateMessage(sender, login, hostname, message) end function onConnect() joinChannel("#testobot") end