For reconnections, best way to see that a room exists without joining it?

Options
We cached the room Name to a local file when joining the room, and delete it when cleanly leaving the room.

We want to bring up a "You were d/c! Rejoin?" screen.

However, to accomplish this, 1) The cached room needs not be empty (np) 2) We need to see if the room exists WITHOUT actually joining it. How can I check this?

I saw GetCustomRoomList(), but can I use this without a lobby? Can I do something like "WHERE room = "room-name-here" as the query? I'm still brainstorming here.

Comments

  • [Deleted User]
    Options
    Hi @xblade724,

    if you have a SqlLooby, you can use GetCustomRoomList(...). You can find more details about how it works on the related documentation page or on the API page here. This works even if the client has not joined the certain lobby.

    If you don't use a SqlLobby, you can still iterate through PhotonNetwork.GetRoomList() and check Name and PlayerCount properties. This would require the client to join the lobby before.