From 62a4567bf5fead5fd5ef041af77a1affb6e89560 Mon Sep 17 00:00:00 2001 From: Christian 'ketura' McCarty Date: Thu, 19 Sep 2024 08:15:19 -0500 Subject: [PATCH] Fixed duplicate callout messages when changing stages in sealed tournaments. Fixed sealed tournaments not being made aware of deck registrations --- .../src/main/java/com/gempukku/lotro/hall/HallServer.java | 2 +- .../com/gempukku/lotro/tournament/SealedTournament.java | 7 ------- 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/gemp-lotr/gemp-lotr-server/src/main/java/com/gempukku/lotro/hall/HallServer.java b/gemp-lotr/gemp-lotr-server/src/main/java/com/gempukku/lotro/hall/HallServer.java index 240c3b5fe..a8ac3d611 100644 --- a/gemp-lotr/gemp-lotr-server/src/main/java/com/gempukku/lotro/hall/HallServer.java +++ b/gemp-lotr/gemp-lotr-server/src/main/java/com/gempukku/lotro/hall/HallServer.java @@ -533,7 +533,7 @@ public class HallServer extends AbstractServer { stage == Tournament.Stage.PAUSED || stage == Tournament.Stage.AWAITING_KICKOFF) { LotroDeck lotroDeck = validateUserAndDeck(_formatLibrary.getFormat(tournament.getFormatCode()), player, deckName, tournament.getCollectionType()); - _tournamentService.updateRecordedPlayerDeck(tournamentId, player.getName(), lotroDeck); + tournament.playerSubmittedDeck(player.getName(), lotroDeck); } result = "Registered deck '" + deckName + "' with tournament " + tournament.getTournamentName() + " successfully." + "

If you make an update to your deck, you will need to register it here again for any changes to take effect."; diff --git a/gemp-lotr/gemp-lotr-server/src/main/java/com/gempukku/lotro/tournament/SealedTournament.java b/gemp-lotr/gemp-lotr-server/src/main/java/com/gempukku/lotro/tournament/SealedTournament.java index 5f45d1bc6..79a2cadec 100644 --- a/gemp-lotr/gemp-lotr-server/src/main/java/com/gempukku/lotro/tournament/SealedTournament.java +++ b/gemp-lotr/gemp-lotr-server/src/main/java/com/gempukku/lotro/tournament/SealedTournament.java @@ -163,9 +163,6 @@ public class SealedTournament extends BaseTournament implements Tournament { else if (DateUtils.Now().isAfter(_sealedInfo.DeckbuildingDeadline) && _playerDecks.values().stream().noneMatch(x -> StringUtils.isEmpty(x.getDeckName()))) { _tournamentInfo.Stage = _sealedInfo.PostRegistrationStage(); _tournamentService.recordTournamentStage(_tournamentId, getTournamentStage()); - - result.add(new BroadcastAction("Deck building in tournament " + getTournamentName() - + " has finished and all players have turned in their decks. Stand by for the start of the tournament.")); } } @@ -175,8 +172,6 @@ public class SealedTournament extends BaseTournament implements Tournament { _tournamentInfo.Stage = _sealedInfo.PostRegistrationStage(); _tournamentService.recordTournamentStage(_tournamentId, getTournamentStage()); - result.add(new BroadcastAction("Deck registration for tournament " + getTournamentName() - + " has closed. Stand by for the start of the tournament.")); } } @@ -191,8 +186,6 @@ public class SealedTournament extends BaseTournament implements Tournament { result.add(finishTournament(collectionsManager)); } else { if(getCurrentRound() == 0) { - result.add(new BroadcastAction("Deck registration for tournament " + getTournamentName() - + " has closed. Stand by for the start of the tournament.")); result.add(new BroadcastAction("Deck registration for tournament " + getTournamentName() + " has closed. Round " + (getCurrentRound() + 1) + " will begin in " + DateUtils.HumanDuration(PairingDelayTime)