Time spend on game - 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: Time spend on game (
/showthread.php?tid=624983)
Time spend on game -
Loinal - 26.12.2016
Hi guys iam trying to get player time spend on game but i can't i need it in /stats but its mysql and iam new at mysql
Re: Time spend on game -
StrikerZ - 26.12.2016
Quote:
Originally Posted by Loinal
Hi guys iam trying to get player time spend on game but i can't i need it in /stats but its mysql and iam new at mysql
|
Get the value of the total spent time when your player logins and save it in variable. Then use that variable to format the string in /stats. Btw which mysql version are you using?
Re: Time spend on game -
Loinal - 26.12.2016
Quote:
Originally Posted by Sunehildeep
Get the value of the total spent time when your player logins and save it in variable. Then use that variable to format the string in /stats. Btw which mysql version are you using?
|
How to get it?
Re: Time spend on game -
GoldenLion - 26.12.2016
Quote:
Originally Posted by Loinal
How to get it?
|
You can either use
https://sampwiki.blast.hk/wiki/NetStats_GetConnectedTime or create a repeating timer with an interval of 1 minute then add 1 to player's playing minutes or something.