Skip to content

Commit 851b1a7

Browse files
committed
Refactor Faction variable naming in map panel
Renamed the 'independentFaction' variable to 'indFaction' for brevity and consistency. This change affects multiple locations within the InterstellarMapPanel class where faction checks are performed.
1 parent 502c0c3 commit 851b1a7

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

MekHQ/src/mekhq/gui/InterstellarMapPanel.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -478,7 +478,7 @@ protected void paintComponent(Graphics g) {
478478
int minY = (int) Math.floor(scr2mapY(getHeight()) / HEX_SIZE);
479479
int maxY = (int) Math.ceil(scr2mapY(0.0) / HEX_SIZE);
480480

481-
Faction independentFaction = Factions.getInstance().getFaction("IND");
481+
Faction indFaction = Factions.getInstance().getFaction("IND");
482482

483483
for (int x = minX; x <= maxX; ++x) {
484484
for (int y = minY; y <= maxY; ++y) {
@@ -495,7 +495,7 @@ protected void paintComponent(Graphics g) {
495495
for (PlanetarySystem system : nearbySystems) {
496496
if (!isSystemEmpty(system) && path.contains(system.getX(), system.getY())) {
497497
Set<Faction> factions = system.getFactionSet(now);
498-
factions.remove(independentFaction);
498+
factions.remove(indFaction);
499499
hexFactions.addAll(factions);
500500
}
501501
}
@@ -510,7 +510,7 @@ protected void paintComponent(Graphics g) {
510510
}
511511

512512
if (hexFactions.size() > 1) {
513-
hexFactions.remove(independentFaction);
513+
hexFactions.remove(indFaction);
514514
}
515515

516516
path.transform(transform);

0 commit comments

Comments
 (0)