Loading Previous Server Time ? - 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)
+--- Thread: Loading Previous Server Time ? (
/showthread.php?tid=442628)
Loading Previous Server Time ? -
Zex Tan - 08.06.2013
Hello, I was wondering of how to load the server time from the previous restart
like:
The Server Time was 3 p.m then a Server Restart has been issued, when the server is back it will load the Previous Server Time ( 3 p.m ).
So my question is, how can I make/create that ? MySQL ?
Re: Loading Previous Server Time ? -
JaKe Elite - 08.06.2013
when the gamemodeexit is called saved the server time in a file.
Then load it back base on file when server starts again.
gettime should be use on this. However, gettime returns your computer time.
I'm not sure if gamemodeexit is called when server restarts, but all i know it gets called when the samp-server.exe is closed