- Home /
Photon Question. How can I Create a Room in a Lobby without entering the Room?
Hello I have been looking for a way to create rooms in the lobby without entering them in the latest version of Photon. I want the player to enter a string name of the room and hit Enter to 'Create Room' then have it appear on a list of rooms that has been created.PhotonNetwork.JoinRoom() will join an existing room. PhotonNetwork.CreateRoom() will create a new room and enter it. What function or method can create a room and NOT enter it?
Answer by tobiass · Aug 03, 2015 at 02:44 PM
You can't.
If you want some rooms in the list, just add them to any list you get from the server. Flag the items/entries as something you only show locally.
Use JoinOrCreate() to get into the room, no matter if it existed or not.
Thank you for your input. I will try this new approach
Answer by Archimy · Apr 24, 2016 at 07:32 AM
Maybe I just don't understand properly (highly the case) but what's the purpose of having two functions-- PhotonNetwork.CreateRoom() and PhotonNetwork.JoinRoom() -- if I can't create a room without joining it?? I'm in the midst of a multiplayer sandbox that would be helped greatly by this added functionality. Is there a chance of it being implemented? A workaround that doesn't involve me defining room properties before runtime?