Player Stats Auto Save - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (
https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Player Stats Auto Save (
/showthread.php?tid=191674)
Player Stats Auto Save -
Steven82 - 20.11.2010
Would it cause lag if i set a timer to auto save player states every 1 second?
Re: Player Stats Auto Save -
TheXIII - 20.11.2010
Probably. Maybe not with 1-2 or even 5-10 players. But SA-MP supports 500
With 10+ players it isn't probably the best idea.
Re: Player Stats Auto Save -
ChristopherM - 20.11.2010
It all depends on what format of file saving you are using. For example if you were saving the players statistics to their user file ever second that's going to cause a high CPU usage due to the constant file writing. And saving them via MySQL is going to cause adverse effect on your CPU usage too if your running a query every second. It isn't advisable to save the statistics every 1 second.
Re: Player Stats Auto Save -
Steven82 - 20.11.2010
Yea thats what i was thinking
Re: Player Stats Auto Save -
TheHoodRat - 20.11.2010
I tried it once, it lagged like hell.
Re: Player Stats Auto Save -
Steven82 - 20.11.2010
Quote:
Originally Posted by TheHoodRat
I tried it once, it lagged like hell.
|
Lol maybe i should change to every 10 minutes or something idk? I never did it.
Offtopic:
Whats EC-RP?
Re: Player Stats Auto Save -
TheHoodRat - 20.11.2010
Quote:
Originally Posted by Steven82
Lol maybe i should change to every 10 minutes or something idk? I never did it.
Offtopic:
Whats EC-RP?
|
It's a roleplay script that had 6000 lines, but I accidentally overwritten the file, so I'm starting all over.