Posts: 314
Threads: 58
Joined: Oct 2010
Reputation:
0
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?
Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
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.
Posts: 314
Threads: 58
Joined: Oct 2010
Reputation:
0
No no i ment counting users in the file.Like example there are 2 users it will say 2 user counted from users file.
Posts: 6,236
Threads: 310
Joined: Jan 2011
Reputation:
0
You can't count files in a directory.
Posts: 178
Threads: 17
Joined: Apr 2010
Reputation:
0
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).