Skip to content

Commit

Permalink
Copy players list when adding players
Browse files Browse the repository at this point in the history
  • Loading branch information
Gaming32 committed Feb 24, 2024
1 parent 506c270 commit c47bc3d
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -493,7 +493,7 @@ private static int startGame(CommandContext<CommandSourceStack> context) throws

Bingo.activeGame = new BingoGame(board, gamemode, requireClient, persistent, teams.toArray(PlayerTeam[]::new));
Bingo.updateCommandTree(playerList);
playerList.getPlayers().forEach(Bingo.activeGame::addPlayer);
new ArrayList<>(playerList.getPlayers()).forEach(Bingo.activeGame::addPlayer);
playerList.broadcastSystemMessage(Bingo.translatable("bingo.started", difficulty.getDescription()), false);
return Command.SINGLE_SUCCESS;
}
Expand Down

0 comments on commit c47bc3d

Please sign in to comment.