Skip to content

Commit

Permalink
Refactor getReportText method for improved readability
Browse files Browse the repository at this point in the history
Enhanced the `getReportText` method with cleaner HTML table formatting and consolidated string operations. Removed unused and redundant private methods to streamline the code and improve maintainability.
  • Loading branch information
IllianiCBT committed Nov 18, 2024
1 parent 4f065b3 commit b7d7e36
Show file tree
Hide file tree
Showing 2 changed files with 296 additions and 292 deletions.
110 changes: 58 additions & 52 deletions MekHQ/resources/mekhq/resources/CamOpsReputation.properties
Original file line number Diff line number Diff line change
@@ -1,57 +1,63 @@
unitReputation.text=<html><font size='7'><b>Unit Reputation: %d</b></font><br><br>

averageExperienceRating.text=<b><font size='6'>Average Experience Rating: %s</font></b>
experienceLevel.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Experience Level: </b>%s<br><br>

commandRating.text=<b><font size='6'>Command Rating: %s</font></b>
leadership.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Leadership: </b>%s
tactics.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Tactics: </b>%s
strategy.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Strategy: </b>%s
negotiation.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Negotiation: </b>%s
traits.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Traits: </b>%s <i>Not Implemented</i>
personality.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Personality: </b>%s

combatRecordRating.text=<b><font size='6'>Combat Record Rating: %s</font></b>
refresh.text=This report refreshes every Monday.
count.text=Count
modifier.text=Modifier
required.text=Required
available.text=Available

averageExperienceRating.text=Average Experience Rating
experienceLevel.text=Experience Level

commandRating.text=Command Rating
leadership.text=Leadership
tactics.text=Tactics
strategy.text=Strategy
negotiation.text=Negotiation
traits.text=Traits
traitsNotImplemented.text=Not Implemented
personality.text=Personality

combatRecordRating.text=Combat Record Rating
successes.text=Successes
partialSuccesses.text=Partial Successes
failures.text=Failures
contractsBreached.text=Contracts Breached
retainerDuration.text=Retainer Duration
mission.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;%s: </b>%s (%s)

transportationRating.text=<b><font size='6'>Transportation Rating: %s</font></b>
hasJumpShipOrWarShip.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Has JumpShip or WarShip: </b>+10
smallCraft.text=Small Craft
fighters.text=Fighters
battleMeks.text=BattleMeks
vehicleSuperHeavy.text=Vehicles (Super Heavy)
vehicleHeavy.text=Vehicles (Heavy)
vehicleLight.text=Vehicles (Light)
protoMeks.text=ProtoMeks
battleArmor.text=Battle Armor
infantry.text=Infantry
transportString.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;%s: </b>%d / %d Bays%s %s
asterisk.text=<br><i>* Lighter units will occupy spare bays</i><br>
noDropShip.text=No DropShip: -5
dropShipString.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;DropShips: </b>%d / %d Docking Collars (%s)<br>

supportRating.text=<br><b><font size='6'>Support Rating: %d </font></b>
crewRequirements.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Partially Crewed Large Craft: -5<br>
administrationRequirements.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Administration Requirements: </b>%d / %d (%d)<br>
technicianRequirements.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Technician Requirements: %s</b><br>
battleMeksAndProtoMeks.text=BattleMeks & ProtoMeks
vehicles.text=Vehicles
fightersAndSmallCraft.text=Fighters & Small Craft
technicianString.text=&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;%s: </b>%d / %d<br>

financialRating.text=<b><font size='6'>Financial Rating: %s</font></b>
hasLoanOrDebt.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Has Loan or Debt: -10</b><br><br>

crimeRating.text=<br><b><font size='6'>Crime Rating: %s</font></b>
piracy.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Piracy: </b>%s
otherCrimes.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Other: </b>%s
dateOfLastCrime.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Date of Last Crime: </b>%s<br>

otherModifiers.text=<br><b><font size='6'>Other Modifiers: %s</font></b>
inactiveYears.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Inactivity: </b>%d
customModifier.text=<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Custom Modifier: </b>%s

transportationRating.text=Transportation Rating
hasJumpShipOrWarShip.text=JumpShip/WarShip Modifier
hasDropShip.text=DropShip Modifier
capacityCombatant.text=Combatant Capacity
capacityNonCombatant.text=Non-Combatant Capacity
dockingCollars.text=Docking Collars
smallCraft.text=Small Craft Bays
fighters.text=Fighter Bays
battleMeks.text=BattleMek Bays
vehicleSuperHeavy.text=Vehicle Bays (Super Heavy)
vehicleHeavy.text=Vehicle Bays (Heavy)
vehicleLight.text=Vehicle Bays (Light)
protoMeks.text=ProtoMek Bays
battleArmor.text=Battle Armor Bays
infantry.text=Infantry Bays
passengers.text=Non-Combatant Capacity
asterisk.text=Lighter units will occupy spare bays

supportRating.text=Support Rating
crewRequirements.text=Partially Crewed Large Craft Modifier
administrationModifier.text=Administration Modifier
TechnicianModifier.text=Technician Modifier
administrationRequirements.text=Administrators
battleMeksAndProtoMeks.text=BattleMek & ProtoMek Technicians
vehicles.text=Vehicle Technicians
fightersAndSmallCraft.text=Fighters & Small Craft Technicians

financialRating.text=Financial Rating
hasLoanOrDebt.text=Debt Modifier

crimeRating.text=Crime Rating
piracy.text=Piracy
otherCrimes.text=Other
dateOfLastCrime.text=Date of Last Crime

otherModifiers.text=Other Modifiers
inactiveYears.text=Inactivity Modifier
customModifier.text=Custom Modifier
Loading

0 comments on commit b7d7e36

Please sign in to comment.