Full room disconnects everyone
When I have more than 8 players join a small room, they all disconnect.
15 Replies
Hi @Alix Ollivier. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave:
----------------------
Based on the information provided in the knowledge sources, it appears that you may be encountering an issue related to room capacity. Let's address this problem:
The Room Server Options documentation provides insights into the capacity of different room server configurations. For a small room server, which is likely what you're using, the typical capacity for a VR title is around 16 players. However, if your application includes voice chat, this number drops to about 8 players.
Given that you're experiencing disconnections when more than 8 players join, it's possible that:
1. Your room is configured as a small server with voice chat enabled, reaching its capacity limit.
2. Your application might be using more bandwidth than a typical VR title, reducing the effective player count.
To resolve this issue, you have a few options:
1. Upgrade to a larger room server configuration. For example, a medium configuration could potentially support up to 20 players for a VR title with voice chat.
2. Optimize your application to reduce bandwidth usage. As mentioned in the How room servers scale section, "reducing the data a single player sends by 64 bytes leads to a total bandwidth saving of 1,024 bytes for the entire room server."
3. If possible, consider splitting your space across multiple Normcore rooms to distribute the player load.
To upgrade your room server, you can use the Room Server Options API when connecting to a room. Here's an example of how to connect to a medium-sized room:
Remember, the room server configuration is set by the first player to connect and cannot be changed during the session. If you need to change the configuration, all players must disconnect, and the room must be idle for 30 seconds before a new configuration can be applied.
If you continue to experience issues or need more specific guidance, you may want to contact Normcore support directly, as they might be able to provide more tailored advice based on your specific implementation and usage patterns.
----------------------
Note: you can ask me a follow up question by @ mentioning me again :speech_balloon:
----------------------
<@185325614775926784> Kapa.ai is still learning and improving, please let me know how I did by reacting below.
@Normcore Assistant is there any way to try connecting to a room and stop the player if the room is full?
Let me check the knowledge base for you again. One moment! :books:
----------------------
To address your question about trying to connect to a room and stopping the player if the room is full, I'll need to provide some context and then explain the available options based on the information from the Normcore documentation.
Unfortunately, there isn't a direct, built-in method to check if a room is full before connecting. However, we can implement a workaround using the existing Normcore APIs. Here's an approach you could consider:
1. Attempt to connect to the room.
2. Monitor the connection state.
3. If the connection fails due to the room being full, prevent the player from joining.
Here's a basic implementation of this approach:
This script attempts to connect to a room and listens for connection events. If the connection fails because the room is full, it will be caught in the
DidDisconnectFromRoom
method, where you can implement your logic to stop the player from joining and perhaps display a message.
It's worth noting that this approach will still attempt to connect before determining if the room is full. If you need a more efficient solution or want to avoid unnecessary connection attempts, you might consider:
1. Implementing a custom matchmaking system that keeps track of room occupancy.
2. Using Normcore Private, which may offer more advanced room management features.
Remember, as mentioned in the Common Questions section:
"How do I get a list of all rooms and how many players are in them? This is something we're working on, but for the time being, it's something you'll need to manage yourself."This suggests that Normcore doesn't currently provide a built-in way to check room occupancy before connecting, which is why we need to use the workaround described above. If you need more precise control over room occupancy and connections, you might want to reach out to Normcore support for additional guidance or to inquire about upcoming features that might address this need more directly. ---------------------- Note: you can ask me a follow up question by @ mentioning me again :speech_balloon: ----------------------
<@185325614775926784> Kapa.ai is still learning and improving, please let me know how I did by reacting below.
these answers are wrong it shouldn’t be disconnecting everyone if it’s full
you’ll just see packets start to stutter
this sounds like a bug but I’m not sure what in Normcore would disconnect everyone
the builds don’t crash or anything? No disconnect errors?
maybe you have code that joins and disconnects when you find a full room. instead you should use a lobby service
I don't have any code related to normcore connection afaik. It's just the "login on start" option
I use unity lobby to check for available rooms
@Alix Ollivier do you have paid normcore?
I tested Normcore free and I got only to 7 VR players, maybe new connections get bounced ? idk
I have normcore free for now
@Mechabit , would you be willing to share your unity lobby code?
after you've set up lobbies you want to add the normcore room name as meta data
string lobbyName = "new lobby";
int maxPlayers = 4;
CreateLobbyOptions options = new CreateLobbyOptions();
options.Data = new Dictionary<string, DataObject>()
{
{
"Room", new DataObject(
visibility: DataObject.VisibilityOptions.Public, // Visible publicly.
value: "Normcore Room Name")
},
};
Lobby lobby = await LobbyService.Instance.CreateLobbyAsync(lobbyName, maxPlayers, options);
I usually name my lobbies after the host player name
When a player joins a lobby they can read the "Room" data from the lobby and use Realtime.Connect(room name); to connect
Or you can just share the room name with your friends