Class StratConFacility

java.lang.Object
mekhq.campaign.digitalGM.stratCon.facility.StratConFacility
All Implemented Interfaces:
Cloneable

public class StratConFacility extends Object implements Cloneable
This represents a facility in the StratCon context
  • Constructor Details

    • StratConFacility

      public StratConFacility()
  • Method Details

    • clone

      public StratConFacility clone()
      Overrides:
      clone in class Object
    • copyRulesDataFrom

      public void copyRulesDataFrom(StratConFacility facility)
      Copies data from the source facility to here. Does cosmetic data. Reconstructs file-driven transient data.
    • getOwner

    • setOwner

      public void setOwner(ScenarioForceTemplate.ForceAlignment owner)
    • isOwnerAlliedToPlayer

      public boolean isOwnerAlliedToPlayer()
      Returns:
      true if the facility owner is either allied to the player or is the player themselves, false otherwise.
    • getFormattedDisplayableName

      public String getFormattedDisplayableName()
    • getDisplayableName

      public String getDisplayableName()
    • setDisplayableName

      public void setDisplayableName(String displayableName)
    • getFacilityType

      public StratConFacility.FacilityType getFacilityType()
    • setFacilityType

      public void setFacilityType(StratConFacility.FacilityType facilityType)
    • getVisible

      public boolean getVisible()
    • setVisible

      public void setVisible(boolean visible)
    • isVisible

      public boolean isVisible()
    • getIsAvailable

      public boolean getIsAvailable()
    • setIsAvailable

      public void setIsAvailable(boolean isAvailable)
    • isAvailable

      public boolean isAvailable()
    • getSharedModifiers

      public List<String> getSharedModifiers()
      This is a list of scenario modifier IDs that affect scenarios in the same track as this facility.
    • setSharedModifiers

      public void setSharedModifiers(List<String> sharedModifiers)
    • getLocalModifiers

      public List<String> getLocalModifiers()
      This is a list of scenario modifier IDs that affect scenarios involving this facility directly.
    • setLocalModifiers

      public void setLocalModifiers(List<String> localModifiers)
    • getAggroRating

      @Deprecated(since="0.51.0", forRemoval=true) public int getAggroRating()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • setAggroRating

      @Deprecated(since="0.51.0", forRemoval=true) public void setAggroRating(int rating)
      Deprecated, for removal: This API element is subject to removal in a future version.
    • isStrategicObjective

      public boolean isStrategicObjective()
    • setStrategicObjective

      public void setStrategicObjective(boolean isStrategicObjective)
    • getBiomes

      public List<StratConBiome> getBiomes()
    • setBiomes

      public void setBiomes(List<StratConBiome> biomes)
    • incrementOwnershipChangeScore

      public void incrementOwnershipChangeScore()
    • decrementOwnershipChangeScore

      public void decrementOwnershipChangeScore()
    • clearOwnershipChangeScore

      @Deprecated(since="0.51.0", forRemoval=true) public void clearOwnershipChangeScore()
      Deprecated, for removal: This API element is subject to removal in a future version.
    • getOwnershipChangeScore

      public int getOwnershipChangeScore()
    • getCapturedDefinition

      public String getCapturedDefinition()
      If present, this is the name of the definition file to draw from when switching facility ownership.
    • setCapturedDefinition

      public void setCapturedDefinition(String capturedDefinition)
    • getRevealTrack

      public boolean getRevealTrack()
    • setRevealTrack

      public void setRevealTrack(boolean revealTrack)
    • getIncreaseScanRange

      public boolean getIncreaseScanRange()
    • setIncreaseScanRange

      public void setIncreaseScanRange(boolean increaseScanRange)
    • getScenarioOddsModifier

      public int getScenarioOddsModifier()
    • setScenarioOddsModifier

      public void setScenarioOddsModifier(int scenarioOddsModifier)
    • getMonthlySPModifier

      public int getMonthlySPModifier()
      Returns:
      The facility's monthly SP (Support Points) modifier as an integer.
    • setMonthlySPModifier

      public void setMonthlySPModifier(int monthlySPModifier)
      Sets a new value for the monthly SP (Support Points) modifier.
      Parameters:
      monthlySPModifier - The new monthly SP modifier value.
    • getBiomeTempMap

      public TreeMap<Integer,StratConBiome> getBiomeTempMap()
      Returns the biome temperature map (note: temperature mapping is in kelvins but stored in Celsius)
    • deserialize

      public static StratConFacility deserialize(String fileName)
      Attempt to deserialize an instance of a StratConFacility from the passed-in file name
      Returns:
      Possibly an instance of a StratConFacility
    • Serialize

      public void Serialize(File outputFile)
      Serialize this facility to a JSON file, led by the MegaMek Data license header. Please pass in a non-null file.
      Parameters:
      outputFile - The destination file.
    • preventAerospace

      public boolean preventAerospace()
    • setPreventAerospace

      public void setPreventAerospace(boolean preventAerospace)
    • getUserDescription

      public String getUserDescription()
    • setUserDescription

      public void setUserDescription(String userDescription)