- Home /
Question by
Mohammadjavad · Jan 17, 2012 at 02:28 PM ·
networkingnetworkserverclient
All players number in Network
Hi. I want to get number of all connected players. but my problem is that when I am connecting as a client I couldn't get all connected players number. but when I am connecting as a server with this statement ( Network.connections.Length ) I can get all connected clients numbers. Its essential get all numbers of players when I am connected as a client.
Comment
Answer by Kryptos · Jan 17, 2012 at 04:30 PM
As a client you can only see yourself and the server (don't ask me why, I also find this stupid).
The solution is to make the server send a RPC each time a player is connected or disconnected so that each client can keep a track on that.