Hello !
I am following the “Make Online Games Using Unity’s NEW Multiplayer Framework” course and while joining lobbies I am getting an exception. I have the full call stack to this exception, but to summarize it, it just says:
Unity.Services.Lobbies.LobbyServiceException: player is already a member of the lobby
This happens only when joining the same lobby from 2 different game instances running on the same machine on Linux platform. I had a hunch that it is because I am on a Linux platform. To confirm this I tested the same project on Windows and it worked perfectly fine there.
I am not 100% sure but I think it could be related to PlayerPrefs
. I say this because, on Windows, when I launch one instance via Build and Run
and another instance via Unity Editor, it seem to be using 2 different places to store the prefs (The stored player names stay unique for both of them). But on Linux, both the instances shows the same player name from prefs.
I know this is not a big issues as running the same game twice on the same machine is not the end goal of this course and this is a Linux specific problem. But if possible, can you provide some workaround for this? I’d really like to avoid switching to Windows just for this.