[R]How to get online players count
#2

Code:
GetPlayersOnServer() {
	new count;
	for(new x=0; x< MAX_PLAYERS; x++) { //x = MAX_PLAYERS
	  if(IsPlayerConnected(x))) { 
			count++;
		}
	}
	return count;
}
Then call that function whenever you need to know how many players are on the server.
Reply


Messages In This Thread
[R]How to get online players count - by xfire - 26.03.2010, 14:18
Re: [R]How to get online players count - by Whitetiger - 26.03.2010, 14:23
Re: [R]How to get online players count - by xfire - 26.03.2010, 14:29

Forum Jump:


Users browsing this thread: 1 Guest(s)