Photon Pun 2 PlayerList sorted by what?

I’m trying to point to a specific player in a room through an RPC. It seems the easiest property to send through is the actor ID.

The documentation for PhotonNetwork.PlayerList says:

But it does not say what key the list is sorted by. Is it the actor number? And is this number shared across the room or does every client have its own actor number for each player?

Thank you!

As I recall it’s sorted by actor number ascending, but you can easily confirm this yourself, with a quick debug.log of the contents.

The list is the same for all clients, so an actor number on any client refers to the same player.

1 Like