Skip to content

Commit

Permalink
fix: ignore player votes
Browse files Browse the repository at this point in the history
  • Loading branch information
Scoppio committed Dec 5, 2024
1 parent 561ffda commit f9adf19
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions megamek/src/megamek/server/totalwarfare/TWGameManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -1340,7 +1340,7 @@ private String getDetailedVictoryReport() {
*/
public void forceVictory(Player victor, boolean endImmediately, boolean ignorePlayerVotes) {
game.setEndImmediately(endImmediately);
game.setIgnorePlayerDefeatVotes(endImmediately);
game.setIgnorePlayerDefeatVotes(ignorePlayerVotes);
game.setForceVictory(true);
if (victor.getTeam() == Player.TEAM_NONE) {
game.setVictoryPlayerId(victor.getId());
Expand All @@ -1350,9 +1350,7 @@ public void forceVictory(Player victor, boolean endImmediately, boolean ignorePl
game.setVictoryTeam(victor.getTeam());
}

List<Player> playersVector = game.getPlayersList();
for (int i = 0; i < playersVector.size(); i++) {
Player player = playersVector.get(i);
for (Player player : game.getPlayersList()) {
player.setAdmitsDefeat(false);
}
}
Expand Down

0 comments on commit f9adf19

Please sign in to comment.