Class TWRulesArmor

java.lang.Object
megamek.common.rules.RulesArmor
megamek.common.rules.totalwarfare.TWRulesArmor

public class TWRulesArmor extends RulesArmor
  • Constructor Details

    • TWRulesArmor

      public TWRulesArmor()
  • Method Details

    • allowHeatWeapon

      public boolean allowHeatWeapon(boolean heat_weapon)
      Allow heat weapons for heat armor. TW does not need to know about heat weapons for armor.
      Specified by:
      allowHeatWeapon in class RulesArmor
      Parameters:
      heat_weapon - true if the weapon is a heat weapon
      Returns:
      true if heat weapons are allowed
    • allowArmorPiercing

      public boolean allowArmorPiercing(TWDamageManager.ModsInfo mods)
      Does armor allow armor piercing. Hardened, FerroLam, and Reactive prevent AP ammo.
      Specified by:
      allowArmorPiercing in class RulesArmor
      Parameters:
      mods - the modifications info
      Returns:
      true if armor piercing is allowed
    • impactArmorBreach

      public int impactArmorBreach()
      Impact Resistant Armor breach. Impact Resistant Armor breach.
      Specified by:
      impactArmorBreach in class RulesArmor
      Returns:
      the breach value modifier
    • impactArmorMod

      public int impactArmorMod()
      Impact resistant armor. Impact armor reduces crit rolls.
      Specified by:
      impactArmorMod in class RulesArmor
      Returns:
      the impact armor modifier
    • checkLancePenetration

      public boolean checkLancePenetration(int armorType)
      Does a lance penetrate the armor. Hardened and ferro lam prevent penetration.
      Specified by:
      checkLancePenetration in class RulesArmor
      Parameters:
      armorType - the type of armor
      Returns:
      true if a lance penetrates the armor
    • reduceHeatDamageByArmor

      public int reduceHeatDamageByArmor(int armorType, int heatDamage)
      Does the armor reduce heat?
      Specified by:
      reduceHeatDamageByArmor in class RulesArmor
      Parameters:
      armorType - the type of armor
      heatDamage - the amount of heat damage
      Returns:
      the reduced heat damage amount
    • reflectiveAP

      public boolean reflectiveAP(boolean reflectiveArmor)
      Does reflective armor cause modifiers for AP? In TW, reflective armor will cause AP crit chance changes.
      Specified by:
      reflectiveAP in class RulesArmor
      Parameters:
      reflectiveArmor - true if the armor is reflective
      Returns:
      true if reflective armor affects AP modifiers
    • blockTAC

      public boolean blockTAC(int armorType)
      Block TAC (Targeting Auto-Correlator).
      Specified by:
      blockTAC in class RulesArmor
      Parameters:
      armorType - the type of armor
      Returns:
      true if TAC is blocked
    • reduceImpactDamage

      public int reduceImpactDamage(int entityId, HitData hit, int damage, Vector<Report> reportVec, HitDamageType damageType)
      How does impact armor reduce damage.
      Specified by:
      reduceImpactDamage in class RulesArmor
      Parameters:
      entityId - the entity ID
      hit - the hit data
      damage - the damage amount
      reportVec - vector of reports describing the damage reduction
      damageType - the type of damage
      Returns:
      the reduced damage amount
    • reflectiveArmorReduction

      public int reflectiveArmorReduction(int damage)
      Reflective armor reduction Round down. TO:AUE p.93
      Specified by:
      reflectiveArmorReduction in class RulesArmor
      Parameters:
      damage - the damage to be reduced
      Returns:
      the reduced damage amount
    • reactiveArmorReduction

      public int reactiveArmorReduction(int damage)
      Reactive armor reduction Round down. TO:AUE p.93
      Specified by:
      reactiveArmorReduction in class RulesArmor
      Parameters:
      damage - the damage to be reduced
      Returns:
      the reduced damage amount
    • ballisticReinforcedArmorReduction

      public int ballisticReinforcedArmorReduction(int damage)
      Ballistic reinforced armor reduction Round down. TO:AUE p.93
      Specified by:
      ballisticReinforcedArmorReduction in class RulesArmor
      Parameters:
      damage - the damage to be reduced
      Returns:
      the reduced damage amount