Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice

Question Without lobby events, what is the best option to get lobby players updates?

Discussion in 'Lobby' started by aliajami, Jun 25, 2023.

  1. aliajami

    aliajami

    Joined:
    Jan 5, 2023
    Posts:
    5
    I have a game in beta right now, that uses relay and lobby to match players and connect them.
    The way I have it setup, is that when a lobby is created I create a relay allocation along with it, so that any player joining the lobby will connect to relay right away, this helps to have real-time updates from players in the lobby over relay.

    With the introduction of lobby events, I switched to only using them and only create the relay connection when the game is about to start.
    My question is, until the lobby events are officially released, what is the best option for me right now?
    Shall I stick with my current setup or switch to polling the lobby for every client every couple of seconds?

    If the lobby new release is close I can just wait it out, but I have no idea when is it happening.
     
  2. neviovalsa

    neviovalsa

    Joined:
    Jun 24, 2019
    Posts:
    30
    I had a lot of issues using lobby events, therefore I made it so that when a player connects to a lobby it instantly also spawns a (netcode) player (no graphics) for them containing lobby information like "I'm ready". and use network variables instead of lobby player data.

    The main reason for this issues is that lobby events were fairly unreliable and also changing network variables doesn't have a rate limit
     
    wondermagic likes this.