Photon 2 Tutorial

good day,

so i am going throught the Photon official tutorial and am struggling a little with this error:

JoinRandomRoom failed. Client is on MasterServer (must be Master Server for matchmaking) but not ready for operations (State: ConnectingToNameServer). Wait for callback: OnJoinedLobby or OnConnectedToMaster.

“Client is on MasterServer (must be Master Server for matchmaking)”, so i AM on the masterserver, but it still tells me that its not… ?

any ideas?

I’m just gonna asume here that your code looks something like this:

ConnectToPhoton();
JoinRandomRoom();
... Do more stuff....

But as the error describes: There is a callback which indicates that the connection to photon has beens successully established. (OnConnectToMaster)
You first have to wait for that to call JoinRandomRoom