Skip to content

Commit 47e1001

Browse files
authored
Fix: Add Verifier that Non-Trailer CV has Control Systems (#8725)
Add a verifier check that the non-trailer CV has control systems
2 parents b08d7e0 + 83881b0 commit 47e1001

1 file changed

Lines changed: 8 additions & 5 deletions

File tree

megamek/src/megamek/common/verifier/TestTank.java

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -407,11 +407,14 @@ public boolean correctEntity(StringBuffer buff, int ammoTechLvl) {
407407
}
408408
}
409409

410-
if (tank.getMovementMode() == EntityMovementMode.WIGE) {
411-
if (tank.getWalkMP() < 5) {
412-
buff.append("WiGE must have at least 5 Cruise MP.\n");
413-
correct = false;
414-
}
410+
if (tank.getMovementMode() == EntityMovementMode.WIGE && tank.getWalkMP() < 5) {
411+
buff.append("WiGE must have at least 5 Cruise MP.\n");
412+
correct = false;
413+
}
414+
415+
if (!tank.isTrailer() && tank.hasNoControlSystems()) {
416+
buff.append("Non-trailer must have control systems.\n");
417+
correct = false;
415418
}
416419

417420
if (showFailedEquip() && hasFailedEquipment(buff)) {

0 commit comments

Comments
 (0)