SA-MP Forums Archive
Saving timer - 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: Saving timer (/showthread.php?tid=270033)



Saving timer - cloudysky - 18.07.2011

I'm basically not sure how to save the timer to the player so when he/she logs out it saves and when the relog it continues.

An example would be appreciated.


Re: Saving timer - Famalamalam - 19.07.2011

More info would be appreciated. You can thank me for the bump later.


Re: Saving timer - coole210 - 19.07.2011

What do you need this for (Yes It will help me to know more information)

You can also use GetTickCount..

Код:
//Top of script
new Last[MAX_PLAYERS];
//END
Код:
//Where the player types a cmd or something..
if(Last[playerid] <= 0)
{
Last[playerid] = GetTickCount();
}
else
{
//Last is set..
}
//END
I'm not sure if that helped but meh..