• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Lua Data save each X minutes by Colandus.

Jester

Off
Senator
Joined
May 28, 2007
Messages
2,683
Reaction score
56
Location
Romania.
Colandus wrote a script to save the data each 10 minutes and it worked fine but on rev 896 [tag 0,2] it doesn't work.
PHP:
saveDelay = 10 * 60 * 1000 -- 10 minutes for each save. 
storageValue = 2342 

if (getGlobalStorageValue(storageValue) == -1) then 
    function save(saveDelay) 
        saveData() 
        debugPrint(">>>>PLAYERS SAVED<<<<") 
        addEvent(save, saveDelay, saveDelay) 
    end 
    addEvent(save, saveDelay, saveDelay) 
    setGlobalStorageValue(storageValue, 1) 
end
 
In trunk the command was changed to saveServer() I suppose, try with that, maybe they changed it for tags too? :p
 
Back
Top