Updated 'LobbyState' class.

Updated the 'LobbyState' class by sending a broadcast update the new ready state of the client.
This commit is contained in:
Daniel Grigencha
2024-12-02 21:23:53 +01:00
parent 72321eab9a
commit 468e4005dc

View File

@@ -122,6 +122,7 @@ public void received(LobbyReadyMessage msg, int from) {
}
}
this.logic.getGame().getPlayerById(from).setReady(true);
this.logic.getServerSender().broadcast(new UpdateReadyMessage(from, true));
if (this.logic.getGame().areAllReady()) {
this.initializeGame();
this.logic.getServerSender().broadcast(new ServerStartGameMessage());