public boolean containsVTOLBomb() { for (MoveStep step : steps) { if (step.isVTOLBombingStep()) { return true; } } return false; }
/** * Searches the movement path for the first step that has the given position and sets it as * a VTOL bombing step. If found, any previous bombing step is cleared. If the coordinates are not * part of the path nothing is changed. * * @param pos The <code>Coords</code> of the hex to be bombed. * @return Whether the position was found in the movement path */ public boolean setVTOLBombStep(Coords pos) { boolean foundPos = false; MoveStep prevBombing = null; for (MoveStep step : steps) { if (step.getPosition().equals(pos)) { if (step.isVTOLBombingStep()) { return true; } else { step.setVTOLBombing(true); foundPos = true; } } else if (step.isVTOLBombingStep()) { prevBombing = step; } } if (foundPos && prevBombing != null) { prevBombing.setVTOLBombing(false); } return foundPos; }
if (step.isVTOLBombingStep() || step.isStrafingStep()) { graph.setColor(col); ((Graphics2D)graph).fill(
if (step.isVTOLBombingStep()) { boolean containsOtherBombStep = false; for (int i = 0; i < steps.size() - 1; i++) { if (steps.get(i).isVTOLBombingStep()) { containsOtherBombStep = true;
if (isVTOLBombingStep()) { if (!getEntity().isBomber() || getClearance() <= 0) { movementType = EntityMovementType.MOVE_ILLEGAL;