• 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!

Save system doubt!

feverdog

Active Member
Joined
Mar 10, 2008
Messages
229
Reaction score
36
I still don't get the new tfs mystic spirit saves..

the saves lags my pc with the command.. but if I don't use the command the server won't save anything at all?

if the server crashes and the server didnt saved with the command players will lose it all?

can someone please explain it to me.. I still have doubts about it..
 
Tried to "reinstall" the server?
 
im just asking for someone to explain me how the tfs saves works..
i think u didnt understand what i said up there
:p
 
Lua function for saving: saveData()
Use it in onThink creatureScript or talkactions, and else :p
 
i made a auto saver for tfs
that goes in global.lua ill release it later
also gives u a msg in the console everytime it saves (in minutes)
 
Use this, i didn't make it so but i can't remember who did so if you are the one, post here to earn your credits :p
Goto
Forgotten Server>Data>CreatureScripts>Scripts>login.lua - erase everything and add this

Code:
local minute = 10 -- interval in minutes
local minutes = minute * 60 * 1000 -- dont edit

function onLogin(cid)
	registerCreatureEvent(cid, "PlayerDeath")
	if(alryInitServSave == 0) then
		local eventServ = addEvent(autoSavePlayers, minutes, {})
		alryInitServSave = eventServ
	end
	return 1
end

function autoSavePlayers(parameters)
	saveData()
	print("Server save...")
	local eventServ = addEvent(autoSavePlayers, minutes, parameters)
	alryInitServSave = eventServ
end

than go to Forgotten Server>Data>global.lua
and add this somewhere add the end of the code

Code:
alryInitServSave = 0

The Server will than save every 10 Minutes as soon as 1 Player is online! I've been using this for some times now and it works great for me!
But like i said, i didn't make this so don't give me any credits
 
i made a auto saver for tfs
that goes in global.lua ill release it later
also gives u a msg in the console everytime it saves (in minutes)

Why do you made a auto saver i dont think ur the maker...
give the credit to Colandus...
 
Back
Top