Hahstudios
New Member
- Joined
- Mar 11, 2010
- Messages
- 49
- Solutions
- 3
- Reaction score
- 1
Im having an issue with my server save for some akward reason its not working at all.
and as of the new tfs it isnt in the config file anymore.
im using tfs v1.2
plz help
and as of the new tfs it isnt in the config file anymore.
im using tfs v1.2
HTML:
<globalevent name="save" interval="100" event="script" value="serversave.lua"/>
HTML:
local config = {
broadcast = {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