Skip to content

Commit

Permalink
Merge pull request #4909 from kuronekochomusuke/reportPilotingRollsHe…
Browse files Browse the repository at this point in the history
…adingWhenNotEmpty

only add pilot rolls heading when there are piloting rolls
  • Loading branch information
neoancient authored Nov 22, 2023
2 parents 6ddd0e4 + 539034d commit 9cf6344
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion megamek/src/megamek/server/GameManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -20192,12 +20192,16 @@ private void cleanupDestroyedNarcPods() {
*/
private Vector<Report> resolvePilotingRolls() {
Vector<Report> vPhaseReport = new Vector<>();
vPhaseReport.add(new Report(3900, Report.PUBLIC));

for (Iterator<Entity> i = game.getEntities(); i.hasNext(); ) {
vPhaseReport.addAll(resolvePilotingRolls(i.next()));
}
game.resetPSRs();

if (vPhaseReport.size() > 0) {
vPhaseReport.insertElementAt(new Report(3900, Report.PUBLIC), 0);
}

return vPhaseReport;
}

Expand Down

0 comments on commit 9cf6344

Please sign in to comment.