Package megamek.client.ratgenerator
Class ChassisRecord
java.lang.Object
megamek.client.ratgenerator.AbstractUnitRecord
megamek.client.ratgenerator.ChassisRecord
The ChassisRecord tracks all available variants and determines how much total weight is to be distributed among the
 various models.
- 
Field SummaryFieldsFields inherited from class megamek.client.ratgenerator.AbstractUnitRecordchassis, clan, includedFactions, introYear, omni, unitType
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionvoidaddModel(ModelRecord model) getFilteredModels(int exactYear, Collection<Integer> validWeightClasses, Collection<EntityMovementMode> movementModes, int networkMask) Generate a list of models for this chassis based on certain criteria.doubletotalModelWeight(int era, String fKey) doubletotalModelWeight(int era, FactionRecord fRec) doubletotalModelWeight(HashSet<ModelRecord> validModels, int currentEra, int exactYear, int nextEra, FactionRecord fRec, Collection<MissionRole> roles, int roleStrictness, int equipRating, int numRatingLevels, HashMap<String, Double> weightData) Total the weights of all models for this chassis, including modifiers for +/- dynamic adjustment, intro year adjustment, interpolation, and role modifications.Methods inherited from class megamek.client.ratgenerator.AbstractUnitRecordcalcAvailability, getChassis, getChassisKey, getIncludedFactions, getIntroYear, getKey, getUnitType, isClan, isOmni, parseUnitType, setChassis, setClan, setIntroYear, setOmni, setUnitType, setUnitType, toString
- 
Field Details- 
models
 
- 
- 
Constructor Details- 
ChassisRecord
 
- 
- 
Method Details- 
addModel
- 
getModels
- 
getSortedModels
- 
getFilteredModelspublic HashSet<ModelRecord> getFilteredModels(int exactYear, Collection<Integer> validWeightClasses, Collection<EntityMovementMode> movementModes, int networkMask) Generate a list of models for this chassis based on certain criteria. Early prototypes may be available one year before official introduction.- Parameters:
- exactYear- game year
- validWeightClasses- restrict weight class to one or more classes
- movementModes- movement mode types, may be null or empty
- networkMask- specific C3 network equipment
- Returns:
- set of models which pass the filter requirements, may be empty
 
- 
totalModelWeightpublic double totalModelWeight(HashSet<ModelRecord> validModels, int currentEra, int exactYear, int nextEra, FactionRecord fRec, Collection<MissionRole> roles, int roleStrictness, int equipRating, int numRatingLevels, HashMap<String, Double> weightData) Total the weights of all models for this chassis, including modifiers for +/- dynamic adjustment, intro year adjustment, interpolation, and role modifications.- Parameters:
- validModels- models to add up
- currentEra- year for current era
- exactYear- current year in game
- nextEra- start date of next era after the current one
- fRec- faction data
- roles- roles selected for generation, may be null or empty
- roleStrictness- positive number, higher applies heavier role adjustments
- equipRating- equipment rating to generate for
- numRatingLevels- how many rating levels are present
- Returns:
- sum of calculated weights of all models of this chassis
 
- 
totalModelWeight
- 
totalModelWeight
 
-