Problem: When it's a Map clean or Server save from Globalevents, the players can still playing but the players who want enter it's says that the server is offline.
I'm thinking that is a problem from firewall Zone Alarm :S
Somebody can help me!?
save.lua
clean.lua
I'm thinking that is a problem from firewall Zone Alarm :S
Somebody can help me!?
save.lua
PHP:
local config = {
broadcast = {120, 30},
shallow = "no",
delay = 120,
events = 30
}
config.shallow = getBooleanFromString(config.shallow)
local function executeSave(seconds)
if(isInArray(config.broadcast, seconds)) then
local text = ""
if(not config.shallow) then
text = "Full s"
else
text = "S"
end
text = text .. "erver save within " .. seconds .. " seconds, please mind it may freeze!"
doBroadcastMessage(text)
end
if(seconds > 0) then
addEvent(executeSave, config.events * 1000, seconds - config.events)
else
doSaveServer(config.shallow)
end
end
function onThink(interval, lastExecution, thinkInterval)
if(table.maxn(config.broadcast) == 0) then
doSaveServer(config.shallow)
else
executeSave(config.delay)
end
return true
end
clean.lua
PHP:
function executeClean()
doCleanMap()
doBroadcastMessage("Game map cleaned, next clean in 2 hours.")
return true
end
function onThink(interval, lastExecution, thinkInterval)
doBroadcastMessage("Game map cleaning within 30 seconds, please pick up your items!")
addEvent(executeClean, 30000)
return true
end