@Override public int getBattleForceArmorPoints() { if (isCapitalFighter()) { return (int) Math.round(getCapArmor() / 3.0); } return super.getBattleForceArmorPoints(); }
@Override public int getThresh(int loc) { if (isCapitalFighter()) { if ((null != game) && game.getOptions().booleanOption(OptionsConstants.ADVAERORULES_AERO_SANITY)) { if (game.getOptions().booleanOption(OptionsConstants.ADVAERORULES_VARIABLE_DAMAGE_THRESH)) { return (int) Math.round(getCapArmor() / 40.0) + 1; } else { return (int) Math.round(getCap0Armor() / 40.0) + 1; } } else { return 2; } } else if (loc < damThresh.length) { return damThresh[loc]; } return 0; }
@Override public double getArmorRemainingPercent() { int armor0 = getTotalOArmor(); int armor = getTotalArmor(); if (isCapitalFighter()) { armor0 = getCap0Armor(); armor = getCapArmor(); } if (armor0 == 0) { return IArmorState.ARMOR_NA; } return ((double) armor / (double) armor0); }
/** * Determines if this object can accept the given unit. The unit may not be * of the appropriate type or there may be no room for the unit. * * @param unit * - the <code>Entity</code> to be loaded. * @return <code>true</code> if the unit can be loaded, <code>false</code> * otherwise. */ @Override public boolean canLoad(Entity unit, boolean checkFalse) { // capital fighters can load other capital fighters (becoming squadrons) // but not in the deployment phase if (isCapitalFighter() && !unit.isEnemyOf(this) && unit.isCapitalFighter() && (getId() != unit.getId()) && (game.getPhase() != IGame.Phase.PHASE_DEPLOYMENT)) { return true; } return super.canLoad(unit, checkFalse); }
if (!aero.isCapitalFighter()) { if ((sensors > 0) && (sensors < 3)) { toHit.addModifier(sensors, "sensor damage"); if ((fcs > 0) && !aero.isCapitalFighter()) { toHit.addModifier(fcs * 2, "fcs damage");
if ((fcs > 0) && !aero.isCapitalFighter()) { toHit.addModifier(fcs * 2, "fcs damage");