Skip to content

Commit

Permalink
Condensed woods if statement
Browse files Browse the repository at this point in the history
  • Loading branch information
pheonixstorm committed Feb 16, 2023
1 parent 7ca5b59 commit 8b3e7dd
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions megamek/src/megamek/common/Terrain.java
Original file line number Diff line number Diff line change
Expand Up @@ -413,9 +413,8 @@ public int movementCost(Entity e) {
case Terrains.WOODS:
mp = level;
if (isCrossCountry && e.isGround() && e.isCombatVehicle()) {
if ((level == 1) && ((moveMode == EntityMovementMode.HOVER) || (moveMode == EntityMovementMode.WHEELED))) {
mp *= 2;
} else if (level > 1){
if (((level == 1) && ((moveMode == EntityMovementMode.HOVER) || (moveMode == EntityMovementMode.WHEELED)))
|| (level > 1)) {
mp *= 2;
}
}
Expand Down

0 comments on commit 8b3e7dd

Please sign in to comment.