After I leave room, I can't see the rooms avaliable.

Options
Hi @JohnTube
How is your weekend :smile:
I have some problem.
I just left the room. (PhotonNetwork.LeaveRoom(true);)
And on offline scene, I couldn't find any rooms(RoomList is null)
If I restart my app, I can see the rooms.
What is the problem?

Best Answer

  • sweetmei25
    edited March 2019 Answer ✓
    Options
    This was my mistake

    Once I leave the room, i called this block of code twice in a separate 2 files.
    if (PhotonNetwork.connected == true)
                {
                    PhotonNetwork.Disconnect();
                }
                else
                {
                    PhotonNetwork.ConnectUsingSettings("0.0.0");
                }
    removed one block of code in one file and it worked.

Answers

  • JohnTube
    JohnTube ✭✭✭✭✭
    Options
    Hi @sweetmei25,

    And on offline scene
    What do you mean by this?
    In offline mode, I don't think there is a room list.
  • sweetmei25
    edited March 2019 Answer ✓
    Options
    This was my mistake

    Once I leave the room, i called this block of code twice in a separate 2 files.
    if (PhotonNetwork.connected == true)
                {
                    PhotonNetwork.Disconnect();
                }
                else
                {
                    PhotonNetwork.ConnectUsingSettings("0.0.0");
                }
    removed one block of code in one file and it worked.