From 3c30599910e3eda72b761f23042185ea95909b32 Mon Sep 17 00:00:00 2001 From: RandomityGuy <31925790+RandomityGuy@users.noreply.github.com> Date: Mon, 3 Jun 2024 22:36:50 +0530 Subject: [PATCH] fix issue where other player leaving messed it up --- src/net/NetCommands.hx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/net/NetCommands.hx b/src/net/NetCommands.hx index 849ee071..95858248 100644 --- a/src/net/NetCommands.hx +++ b/src/net/NetCommands.hx @@ -213,7 +213,7 @@ class NetCommands { var allReady = true; for (id => client in Net.clientIdMap) { - if (client.state != GameplayState.GAME) { + if (client.state != GameplayState.GAME && client != conn) { allReady = false; break; } @@ -222,7 +222,6 @@ class NetCommands { MarbleGame.instance.world.allClientsReady(); } } - Net.clientIdMap.remove(clientId); if (MarbleGame.canvas.content is MultiplayerLevelSelectGui) { cast(MarbleGame.canvas.content, MultiplayerLevelSelectGui).updateLobbyNames(); }