$begingroup$

I’m utilizing PUN2 for my sport and I’m utilizing the OnRoomListUpdate() operate to sync my UI with the rooms which might be out there to gamers when they’re within the foyer. The room lists come again from Photon simply nice till I swap areas. If I swap areas and rejoin the foyer, I get the OnRoomListUpdate() occasion however no rooms are handed again for that area once I know I’ve rooms open. Beneath is the code I’ve for switching areas:

public void ConnectToRegion(string area)
{
    PhotonNetwork.Disconnect();
    PhotonNetwork.PhotonServerSettings.AppSettings.FixedRegion = area;

    if (!PhotonNetwork.ConnectUsingSettings())
    {
        Debug.LogError("Unable to attach.");
    }
    else
    {
        PhotonNetwork.JoinLobby();
        currentRegionText.textual content = $"Present area: {area}";
    }
}

$endgroup$


You will need to
log in to reply this query.


Browse different questions tagged .