Well not sure how to do it - 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: Well not sure how to do it (
/showthread.php?tid=313896)
Well not sure how to do it -
lordturhan - 27.01.2012
Well guys here is the problem im using yini.So i want to count how many registered users there are so what i want to do is that to count users in files.
Can someone show me how to that?
Re: Well not sure how to do it -
MP2 - 27.01.2012
Create a variable 'RegisteredUsers' and add one to it when a player registers. And of course, save it to a file, something like serverstats.ini.
Re: Well not sure how to do it -
lordturhan - 27.01.2012
No no i ment counting users in the file.Like example there are 2 users it will say 2 user counted from users file.
Re: Well not sure how to do it -
MP2 - 27.01.2012
You can't count files in a directory.
Re: Well not sure how to do it -
aco_SRBIJA - 27.01.2012
Well, he could, somehow, but it would be soo laggy (some for&while conditions, strings from 1st and last character), but why not just add new var such as new Registered; and when you write a player ini file add also Registered++? Also, be sure to svae it somewhere so it could be loaded (when exiting sever, it's going to be destroyed).