Class MiscMounted

java.lang.Object
megamek.common.equipment.Mounted<MiscType>
megamek.common.equipment.MiscMounted
All Implemented Interfaces:
Serializable, PhaseUpdated, RoundUpdated

public class MiscMounted extends Mounted<MiscType>
See Also:
  • Field Details

  • Constructor Details

  • Method Details

    • getBridgeLayerState

      @Nullable public BridgeLayerState getBridgeLayerState()
      Returns:
      the carried folding-bridge state for a Bridge-Layer (AVLB) mount, or null if this equipment is not a bridgelayer
    • isBridgeLayer

      public boolean isBridgeLayer()
      Returns:
      true if this equipment is a Bridge-Layer (AVLB) variant
    • getBaseDamageAbsorptionRate

      public int getBaseDamageAbsorptionRate()
    • getBaseDamageCapacity

      public int getBaseDamageCapacity()
    • getDamageAbsorption

      public int getDamageAbsorption(Entity entity, int location)
      Rules state that every time the shield takes a crit its damage absorption for each attack is reduced by 1. Also for every Arm actuator critted damage absorption is reduced by 1 and finally if the shoulder is hit the damage absorption is reduced by 2 making it possible to kill a shield before its gone through its full damage capacity.
      Parameters:
      entity - Entity mounted the shield
      location - The shield location index
      Returns:
      The shield's damage absorption value
    • getCurrentDamageCapacity

      public int getCurrentDamageCapacity(Entity entity, int location)
      Rules say every time a shield is critted it loses 5 points from its Damage Capacity. basically count down from the top then subtract the amount of damage its already take. The damage capacity is used to determine if the shield is still viable.
      Parameters:
      entity - The entity the shield is mounted on
      location - The shield's location index
      Returns:
      damage capacity(no less than 0)
    • getDamageTaken

      public int getDamageTaken()
    • setDamageTaken

      public void setDamageTaken(int damage)
    • takeDamage

      public void takeDamage(int damage)
    • getMineType

      public int getMineType()
      Returns:
      the type of mine this mounted is, or -1 if it isn't a mine
    • setMineType

      public void setMineType(int mineType)
      set the type of mine this should be
      Parameters:
      mineType - The mine type index
    • setVibraSetting

      public void setVibraSetting(int vibraSetting)
      set the vibrabomb sensitivity
      Parameters:
      vibraSetting - the int sensitivity to set
    • getVibraSetting

      public int getVibraSetting()
      get the vibrabomb sensitivity
      Returns:
      the int vibrabomb sensitivity this mine is set to.
    • setEmpSetting

      public void setEmpSetting(int empSetting)
      set the EMP mine weight threshold
      Parameters:
      empSetting - the int weight threshold (in tons) to set
    • getEmpSetting

      public int getEmpSetting()
      get the EMP mine weight threshold
      Returns:
      the int weight threshold (in tons) this mine is set to.
    • getBaseDesc

      public String getBaseDesc()
      Overrides:
      getBaseDesc in class Mounted<MiscType>
    • isTurret

      public boolean isTurret()
      Overrides:
      isTurret in class Mounted<MiscType>
      Returns:
      True when this Mounted is a head, quad, shoulder, pintle or sponson turret.