Skip to content

Commit

Permalink
GameManager: prevent bomb choices from being erased when creating a F…
Browse files Browse the repository at this point in the history
…ighterSquadron
  • Loading branch information
SJuliez committed Aug 2, 2024
1 parent 58b72c9 commit b9c72a7
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions megamek/src/megamek/server/GameManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -29128,15 +29128,15 @@ private void receiveSquadronAdd(Packet c, int connIndex) {
if (null != fighter) {
formerCarriers.addAll(ServerLobbyHelper.lobbyUnload(game, List.of(fighter)));
fs.load(fighter, false);
fs.autoSetMaxBombPoints();
fighter.setTransportId(fs.getId());
// If this is the lounge, we want to configure bombs
if (getGame().getPhase().isLounge()) {
((IBomber) fighter).setBombChoices(fs.getExtBombChoices());
}
entityUpdate(fighter.getId());
}
}
// If this is the lounge, we want to configure bombs
fs.autoSetMaxBombPoints();
if (!getGame().getPhase().isLounge()) {
fs.applyBombs();
}
if (!formerCarriers.isEmpty()) {
send(new Packet(PacketCommand.ENTITY_MULTIUPDATE, formerCarriers));
}
Expand Down

0 comments on commit b9c72a7

Please sign in to comment.