/** * Returns the number of allowed anti-mech weapons the supplied location * can mount. The body can mount a set number of anti-mech weapons and a * set number of anti-personnel, however for the arms can mount 2 AP or * 1 AP and 1 AM. * * @param loc * @return */ public int getNumAllowedAntiMechWeapons(int loc){ if ((loc == MOUNT_LOC_LARM) || (loc == MOUNT_LOC_RARM)){ return 1; } else if ((loc == MOUNT_LOC_BODY) || (loc == MOUNT_LOC_TURRET)) { if (getChassisType() == CHASSIS_TYPE_QUAD){ return 4; } else { return 2; } } else { return 0; } }
public static int maxUmuMP(BattleArmor ba) { if (ba.getChassisType() == BattleArmor.CHASSIS_TYPE_QUAD) { return 0; } else { return Math.min(5, 5 - ba.getWeightClass() + EntityWeightClass.WEIGHT_LIGHT); } }
public static int maxJumpMP(BattleArmor ba) { if (ba.getChassisType() == BattleArmor.CHASSIS_TYPE_QUAD) { return 0; } else { return maxWalkMP(ba); } }
public static int maxWalkMP(BattleArmor ba) { int max = 3; if (ba.getWeightClass() >= EntityWeightClass.WEIGHT_HEAVY) { max--; } if (ba.getChassisType() == BattleArmor.CHASSIS_TYPE_QUAD) { max += 2; } return max; }
public int getArmCrits() { if(getChassisType() == CHASSIS_TYPE_QUAD) { return 0; } switch(getWeightClass()) { case EntityWeightClass.WEIGHT_ULTRA_LIGHT: case EntityWeightClass.WEIGHT_LIGHT: return 2; case EntityWeightClass.WEIGHT_MEDIUM: case EntityWeightClass.WEIGHT_HEAVY: return 3; default: return 4; } }
public static int maxVtolMP(BattleArmor ba) { if ((ba.getChassisType() == BattleArmor.CHASSIS_TYPE_QUAD) || (ba.getWeightClass() > EntityWeightClass.WEIGHT_MEDIUM)) { return 0; } else { return 7 - ba.getWeightClass() + EntityWeightClass.WEIGHT_ULTRA_LIGHT; } }
public double getWeightGroundMP() { int walkMP = ba.getOriginalWalkMP(); if (ba.getChassisType() == BattleArmor.CHASSIS_TYPE_QUAD) { walkMP -= QUAD_FREE_MP; } else { walkMP -= BIPED_FREE_MP; } if (walkMP > 0) { return ADDITIONAL_GROUND_MP_WEIGHT[ba.getWeightClass()] * walkMP; } else { return 0; } }
switch (getChassisType()) { case BattleArmor.CHASSIS_TYPE_BIPED: buff.append("biped");
public int getBodyCrits() { if(getChassisType() == CHASSIS_TYPE_QUAD) { int turret = 0; if (getTurretCapacity() > 0) {
if (getChassisType() != CHASSIS_TYPE_QUAD) { if (hasWorkingMisc(MiscType.F_MAGNETIC_CLAMP)) { return true;
public BattleArmorSuit(BattleArmor ba, int loc, Campaign c) { super((int)ba.getWeight(), c); this.trooper = loc; this.quad = ba.getChassisType() == BattleArmor.CHASSIS_TYPE_QUAD; this.weightClass= ba.getWeightClass(); this.groundMP = ba.getOriginalWalkMP(); this.jumpMP = ba.getOriginalJumpMP(); this.clan = ba.isClan(); this.chassis = ba.getChassis(); this.model = ba.getModel(); this.jumpType = ba.getMovementMode(); this.name = chassis + " " + model + " Suit"; initializeExtraCostsAndTons(); }
if (getChassisType() == CHASSIS_TYPE_QUAD) { return 4; } else {
Justification.LEFT, Justification.LEFT, Justification.CENTER, Justification.RIGHT })); final TestBattleArmor testBA = new TestBattleArmor(ba, verifier.baOption, null); if (ba.getChassisType() == BattleArmor.CHASSIS_TYPE_QUAD) { setModelData("chassisType", Messages.getString("TROView.chassisQuad")); } else {
&& ba.getChassisType() == BattleArmor.CHASSIS_TYPE_QUAD){ buff.append("Quad BattleArmor cannot use squad support " + "weapon mounts!\n");
if (((BattleArmor) ent).getChassisType() != BattleArmor.CHASSIS_TYPE_QUAD) { int tBasicManipulatorCount = ent .countWorkingMisc(MiscType.F_BASIC_MANIPULATOR);
if (ba.getChassisType() == BattleArmor.CHASSIS_TYPE_BIPED) { blk.writeBlockData("chassis", "biped"); } else if (ba.getChassisType() == BattleArmor.CHASSIS_TYPE_QUAD) { blk.writeBlockData("chassis", "quad"); if (ba.getTurretCapacity() > 0) {
int numAntiMechWeapons = 0; int numAntiPersonnelWeapons = 0; if ((ba.getChassisType() == BattleArmor.CHASSIS_TYPE_QUAD) && ((loc == BattleArmor.MOUNT_LOC_LARM) || (loc == BattleArmor.MOUNT_LOC_RARM))) { return false;