Skip to content

Enforce using mech status icons, remove mech status colors#143

Merged
Raugharr merged 2 commits intomainfrom
force-icons-for-mech-status
Feb 3, 2026
Merged

Enforce using mech status icons, remove mech status colors#143
Raugharr merged 2 commits intomainfrom
force-icons-for-mech-status

Conversation

@Raugharr
Copy link
Owner

@Raugharr Raugharr commented Jan 18, 2026

MekWars apparently has the ability to show the status of a mech via icons instead of using colored backgrounds, but it had to be enabled. I think this is a much better way of doing it, so instead of having it configurable, these are forced to always be on.
image

Copy link
Collaborator

@sandysimonton sandysimonton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Insanely cool! Is there a way where we can test that if there is a really damaged mek that all the icons show up properly (in the right space, not on top of each other, etc.)?

@Raugharr Raugharr force-pushed the force-icons-for-mech-status branch from eeef049 to 3bac364 Compare January 30, 2026 18:10
@Raugharr
Copy link
Owner Author

Raugharr commented Jan 30, 2026

Sorry for the long delay on this PR, but the answer was no it didn't. I ended up rewriting to code so the icons section would expand if there were more icons.

I also spend a bunch of time trying to add a tooltip to each of the icons when hovered over. That seems to be impossible as in order to do that you need to know the position of each icon as it is layed out. However the CellRenderPane detaches every cell from the JComponent hierarchy and sets their width/height to 0, only restoring it to the hierarchy to draw it.

The icons also take up extra space so I set the default to show 7 mechs instead of 10.

MekWarsClient/src/mekwars/client/gui/dialog/UnitViewerDialog.java was also removed as it was never actually used and seems to be replaced by NewUnitViewerDialog.java

@Raugharr Raugharr merged commit 383e847 into main Feb 3, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants