Skip to content

Commit

Permalink
feat: Updated ally and enemy rating labels and references
Browse files Browse the repository at this point in the history
- Replaced 'Ally Dragoon Rating' and 'Enemy Dragoon Rating' with 'Ally Experience & Tech Rating' and 'Enemy Experience & Tech Rating' in various properties files
- Renamed 'ratingNames' to 'qualityNames' in MissionViewPanel.java, ContractSummaryPanel.java
- Updated references in Java files to align with label changes in properties files
  • Loading branch information
IllianiCBT committed Jun 20, 2024
1 parent 48fa065 commit 21ad618
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ lblEnemy.text=Enemy:
lblMissionType.text=Mission Type:
lblLocation.text=Location:
lblDistance.text= Days (Jumps) to Location:
lblAllyRating.text=Ally Dragoon Rating:
lblEnemyRating.text=Enemy Dragoon Rating:
lblAllyRating.text=Ally Experience & Tech Rating:
lblEnemyRating.text=Enemy Experience & Tech Rating:
lblStartDate.text=Start Date:
lblLength.text=Contract length (months):
lblOverhead.text=Overhead Compensation:
Expand Down
6 changes: 3 additions & 3 deletions MekHQ/resources/mekhq/resources/ContractViewPanel.properties
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@ lblSalvageValueMerc.text=<html><nobr><b>Total Value Salvaged (Mercs):</b></nobr>
lblSalvageValueEmployer.text=<html><nobr><b>Total Value Salvaged (Employer):</b></nobr></html>
lblSalvagePct.text=<html><nobr><b>Salvage Percentage:</b></nobr></html>
lblSalvage.text=<html><nobr><b>Salvage Rights:</b></nobr></html>
exchange=Exchange
exchange=Exchange
none=None

lblEnemy.text=<html><nobr><b>Enemy:</b></nobr></html>
lblAllyRating.text=<html><nobr><b>Ally Dragoon Rating:</b></nobr></html>
lblEnemyRating.text=<html><nobr><b>Enemy Dragoon Rating:</b></nobr></html>
lblAllyRating.text=<html><nobr><b>Ally Experience & Tech Rating:</b></nobr></html>
lblEnemyRating.text=<html><nobr><b>Enemy Experience & Tech Rating:</b></nobr></html>
lblMorale.text=<html><nobr><b>Enemy Morale:</b></nobr></html>
lblScore.text=<html><nobr><b>Contract Score:</b></nobr></html>
lblBonusParts.text=<html><nobr><b>Bonus Parts:</b></nobr></html>
Expand Down
4 changes: 2 additions & 2 deletions MekHQ/resources/mekhq/resources/NewContractDialog.properties
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@ checkMRBC.text=Pay MRBC Fee
checkSalvageExchange.text=Exchange Rights

lblEnemy.text=Enemy:
lblAllyRating.text=Ally Dragoon Rating:
lblEnemyRating.text=Enemy Dragoon Rating:
lblAllyRating.text=Ally Experience & Tech Rating:
lblEnemyRating.text=Enemy Experience & Tech Rating:
chkShowAllFactions.text=Show All Factions
chkShowAllPlanets.text=Show All Planets
lblDistance.text=Days (Jumps) to Location:
Expand Down
8 changes: 4 additions & 4 deletions MekHQ/src/mekhq/gui/view/ContractSummaryPanel.java
Original file line number Diff line number Diff line change
Expand Up @@ -117,10 +117,10 @@ private void initComponents() {

private void fillStats() {
//region Variable Initialization
String[] ratingNames = {"A", "B", "C", "D", "F"};
String[] qualityNames = {"A", "B", "C", "D", "F"};

if (campaign.getCampaignOptions().isReverseQualityNames()) {
ratingNames = new String[] { "F", "D", "C", "B", "A" };
qualityNames = new String[] { "F", "D", "C", "B", "A" };
}

// Initializing the GridBagConstraint used for Labels
Expand Down Expand Up @@ -242,7 +242,7 @@ public void mouseClicked(MouseEvent e) {

if (contract instanceof AtBContract) {
JLabel txtAllyRating = new JLabel(((AtBContract) contract).getAllySkill()
+ "/" + ratingNames[((AtBContract) contract).getAllyQuality()]);
+ "/" + qualityNames[((AtBContract) contract).getAllyQuality()]);
txtAllyRating.setName("txtAllyRating");
gridBagConstraintsText.gridy = y;
mainPanel.add(txtAllyRating, gridBagConstraintsText);
Expand All @@ -253,7 +253,7 @@ public void mouseClicked(MouseEvent e) {
mainPanel.add(lblEnemyRating, gridBagConstraintsLabels);

JLabel txtEnemyRating = new JLabel(((AtBContract) contract).getEnemySkill()
+ "/" + ratingNames[((AtBContract) contract).getEnemyQuality()]);
+ "/" + qualityNames[((AtBContract) contract).getEnemyQuality()]);
txtEnemyRating.setName("txtEnemyRating");
gridBagConstraintsText.gridy = y;
mainPanel.add(txtEnemyRating, gridBagConstraintsText);
Expand Down
8 changes: 4 additions & 4 deletions MekHQ/src/mekhq/gui/view/MissionViewPanel.java
Original file line number Diff line number Diff line change
Expand Up @@ -557,10 +557,10 @@ private void fillStatsAtBContract() {
AtBContract contract = (AtBContract) mission;
Campaign campaign = gui.getCampaign();

String[] ratingNames = {"A", "B", "C", "D", "F"};
String[] qualityNames = {"A", "B", "C", "D", "F"};

if (campaign.getCampaignOptions().isReverseQualityNames()) {
ratingNames = new String[] { "F", "D", "C", "B", "A" };
qualityNames = new String[] { "F", "D", "C", "B", "A" };
}

lblStatus = new JLabel();
Expand Down Expand Up @@ -717,7 +717,7 @@ public void mouseClicked(MouseEvent e) {
pnlStats.add(lblAllyRating, gridBagConstraints);

txtAllyRating.setName("txtAllyRating");
txtAllyRating.setText(contract.getAllySkill() + "/" + ratingNames[contract.getAllyQuality()]);
txtAllyRating.setText(contract.getAllySkill() + "/" + qualityNames[contract.getAllyQuality()]);
gridBagConstraints = new GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = y++;
Expand All @@ -737,7 +737,7 @@ public void mouseClicked(MouseEvent e) {
pnlStats.add(lblEnemyRating, gridBagConstraints);

txtEnemyRating.setName("txtEnemyRating");
txtEnemyRating.setText(contract.getEnemySkill() + "/" + ratingNames[contract.getEnemyQuality()]);
txtEnemyRating.setText(contract.getEnemySkill() + "/" + qualityNames[contract.getEnemyQuality()]);
gridBagConstraints = new GridBagConstraints();
gridBagConstraints.gridx = 1;
gridBagConstraints.gridy = y++;
Expand Down

0 comments on commit 21ad618

Please sign in to comment.