ConnectUsingSettings issue
Options
Hi everyone! First of all sorry for my bad English. I'm trying to use PUN in my project but I have some problems. I set up my project properly and created an empty GO with script in it. Script must Connect>JoinLobby>TryToJoinRandomRoom>CreateNewRoom. But unfortunately it connects to Master only. I did the same year ago on 4.5.x UnityFREE version but now I'm running on Unity5. Well I'm wondering thats an easy and common problem but I didn't find any useful info. Plz help
ServerSettings: Hosting with Cloud / Region Eu / App-Id is OK / Auto-Join Lobby is disabled
C# code:
const string VERSION = "v0.01";
void Start ()
{
PhotonNetwork.ConnectUsingSettings(VERSION);
}
void OnGUI()
{
GUILayout.Label(PhotonNetwork.connectionStateDetailed.ToString());
}
void OnJoinedLobby()
{
Debug.Log("JoinedLobby");
PhotonNetwork.JoinRandomRoom();
}
void OnJoinRandomJoinFailed()
{
Debug.Log("RandomJoinFailed");
PhotonNetwork.CreateRoom(null);
}
ServerSettings: Hosting with Cloud / Region Eu / App-Id is OK / Auto-Join Lobby is disabled
C# code:
const string VERSION = "v0.01";
void Start ()
{
PhotonNetwork.ConnectUsingSettings(VERSION);
}
void OnGUI()
{
GUILayout.Label(PhotonNetwork.connectionStateDetailed.ToString());
}
void OnJoinedLobby()
{
Debug.Log("JoinedLobby");
PhotonNetwork.JoinRandomRoom();
}
void OnJoinRandomJoinFailed()
{
Debug.Log("RandomJoinFailed");
PhotonNetwork.CreateRoom(null);
}
0
Best Answer
-
Hi,
PUN behavior on master server changed recently: http://forum.photonengine.com/discussion/6426/autojoinlobby-disabled-in-pun-v1-60
5
Answers
-
Yes, I see that I have wrong method name OnJoinRandomJoinFailed() but script not even touching PhotonNetwork.ConnectUsingSettings(VERSION); so it's not a problem0
-
Hi,
PUN behavior on master server changed recently: http://forum.photonengine.com/discussion/6426/autojoinlobby-disabled-in-pun-v1-60
5 -
Thanks0