Kevin
Kevin2mo ago

How to I change the room name in game

I want to make a lobby and then entering a code changes to that room. How would I do this? I cant find a way to change the room name
2 Replies
kapa.ai
kapa.ai2mo ago
Hi @Kevin. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave: ---------------------- To change the room name in NormalVR, you can use the Connect() method on the Realtime instance. This method allows you to connect to a room by specifying the room name. Here's how you can do it:
Realtime realtime = ... // your Realtime instance
realtime.Connect("New Room Name");
Realtime realtime = ... // your Realtime instance
realtime.Connect("New Room Name");
In your case, you can call this method with the room code as the room name when the player enters the code. This will connect the player to the room associated with that code. However, please note that the roomToJoinOnStart property, which specifies the name of the room to join on start, can only be configured in the editor inspector. If you'd like to change this name at runtime, you need to disable join room on start, and use the Connect() method on Realtime instead. For more information, you can refer to the Realtime documentation (https://normcore.io/documentation/reference/classes/Normal.Realtime.Realtime). ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ----------------------
kapa.ai
kapa.ai2mo ago
<@1151175034346414100> kapa.ai is still learning and improving, please let us know how it did by reacting below