MySQL:
mysql = dbConnect("mysql", "dbname=test", "host=localhost", "root", "")
outputServerLog("[MySQL] Connected!\n")
if(mysql ~= nil) then
outputServerLog("[MySQL] Disconnected...\n")
destroyElement(mysql)
end
Restart:
function restartServer()
local hour, mins = getTime()
local allResources = getResources()
if(hour == 12) and (mins == 00) then
for index, res in ipairs(allResources) do
if getResourceState(res) == "running" then
restartResource(res)
outputDebugString("GameMode restarted!", 3, 0, 224, 0)
end
end
end
end
setTimer(restartServer, 1000, 0)