Class MissingOmniPod

All Implemented Interfaces:
megamek.common.interfaces.ITechnology, IAcquisitionWork, IPartWork, IWork

public class MissingOmniPod extends MissingPart
Like OmniPod this is never added to a Unit. OmniPod is used for empty pods in the warehouse, and MissingOmniPod is used for acquisition.
  • Constructor Details

    • MissingOmniPod

      public MissingOmniPod()
    • MissingOmniPod

      public MissingOmniPod(Part partType, Campaign c)
      Parameters:
      partType - The type of part that can be installed in this pod
      c - The campaign
  • Method Details

    • setCampaign

      public void setCampaign(Campaign c)
      Overrides:
      setCampaign in class Part
    • getPartType

      public Part getPartType()
      Returns:
      The type of part that can be installed in this pod
    • getTechBase

      public megamek.common.enums.TechBase getTechBase()
      Specified by:
      getTechBase in interface IAcquisitionWork
      Specified by:
      getTechBase in interface megamek.common.interfaces.ITechnology
      Overrides:
      getTechBase in class Part
      Returns:
      The tech base of the part the OmniPod is meant to contain.
    • writeToXML

      public void writeToXML(PrintWriter pw, int indent)
      Exports class data to xml
      Overrides:
      writeToXML in class MissingPart
    • loadFieldsFromXmlNode

      protected void loadFieldsFromXmlNode(Node wn)
      Loads class fields from XML
      Specified by:
      loadFieldsFromXmlNode in class Part
    • getNewPart

      public Part getNewPart()
      Specified by:
      getNewPart in class MissingPart
    • getTechRating

      public megamek.common.enums.TechRating getTechRating()
      Specified by:
      getTechRating in interface megamek.common.interfaces.ITechnology
      Overrides:
      getTechRating in class Part
    • getTechAdvancement

      public megamek.common.TechAdvancement getTechAdvancement()
      Specified by:
      getTechAdvancement in class Part
    • getBaseTime

      public int getBaseTime()
    • updateConditionFromPart

      public void updateConditionFromPart()
    • getLocation

      public int getLocation()
    • checkFixable

      @Nullable public String checkFixable()
    • getDifficulty

      public int getDifficulty()
      Returns:
      the base difficulty of this work unit
    • isAcceptableReplacement

      public boolean isAcceptableReplacement(Part part, boolean refit)
      Specified by:
      isAcceptableReplacement in class MissingPart
    • getTonnage

      public double getTonnage()
      Specified by:
      getTonnage in class Part
    • getLocationName

      public String getLocationName()
      Specified by:
      getLocationName in class Part