HELP: Can't add. Size exceeded.

Options
Hello guys, I'm really new to PUN so please be kind with me :D
I'm getting the "Can't add. Size exceeded." error some seconds after starting the room with 1 additional player and I don't really get where I'm causing this. Can someone please help me and tell me what causes such an error and where I should look into ?

Thank you very much !!!

Comments

  • JohnTube
    JohnTube ✭✭✭✭✭
    Options
    Hi @Snotax,

    Thank you for choosing Photon!

    Could you copy paste the code you are using to create or join rooms?
    I think you are using a combination of MaxPlayers and ExpectedUsers that reserves slots for users and makes the room full.
  • Snotax
    Snotax
    edited March 2019
    Options
    Thank you for your hint!

    Here I create the room:
      PhotonNetwork.NickName = SteamManager.UserData.DisplayName;
      LobbyManager.LobbySettings.SetLobbyGameServer();
      PhotonNetwork.JoinOrCreateRoom(LobbyManager.LobbySettings.LobbyName, new RoomOptions() { MaxPlayers = 2, }, TypedLobby.Default, null);
    This joins them:
    if (!LobbyManager.LobbySettings.IsHost)
            {
                PhotonNetwork.NickName = SteamManager.UserData.DisplayName;
                PhotonNetwork.JoinRoom(LobbyManager.LobbySettings.LobbyName);
            }
  • JohnTube
    JohnTube ✭✭✭✭✭
    Options
    Hi @Snotax,

    Can you provide the full error log with stack trace?
    "Can't add. Size exceeded." is not enough.

    No need to use the last parameter of JoinOrCreateRoom, default is already "null".

    PhotonNetwork.JoinOrCreateRoom(LobbyManager.LobbySettings.LobbyName, new RoomOptions() { MaxPlayers = 2, }, TypedLobby.Default);

    Is this PUN1 or PUN2? What version?

    The code you provided does not show exactly how this could happen.
    How many clients do you use to test this?
  • JohnTube
    JohnTube ✭✭✭✭✭
    Options
    Hi @Snotax,

    It seems I was wrong assuming this is due to Join room operation and Expected Users.

    It turns out it's related to PhotonView serialization.
    Read about it here.
This discussion has been closed.