Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed Award Image Display in Person View #4115

Merged

Conversation

IllianiCBT
Copy link
Collaborator

This is another quick fix to the display of award ribbons, medals, and miscs in the person view panel. My previous fix appeared to resolve the issue, but instead it failed whenever 'person' had more than one issuance of the award. This adds better bounds by using the MathUtility.clamp().

Each graduateCaste method in the EducationController has been adjusted to include a return statement following the method call, thereby preventing the execution of multiple graduateCaste calls within a single instance. The update ensures process efficiency and eliminates potential errors caused by unintended multiple gradations.
… for award image calculations"

This reverts commit 0eba5f0.
@codecov-commenter
Copy link

Codecov Report

Attention: Patch coverage is 0% with 13 lines in your changes are missing coverage. Please review.

Project coverage is 10.28%. Comparing base (33a36ea) to head (64390e3).
Report is 299 commits behind head on master.

Files Patch % Lines
MekHQ/src/mekhq/gui/view/PersonViewPanel.java 0.00% 9 Missing ⚠️
...paign/personnel/education/EducationController.java 0.00% 4 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##             master    #4115      +/-   ##
============================================
- Coverage     10.54%   10.28%   -0.27%     
- Complexity     5605     5732     +127     
============================================
  Files           886      913      +27     
  Lines        117416   123696    +6280     
  Branches      17617    18390     +773     
============================================
+ Hits          12383    12720     +337     
- Misses       103774   109710    +5936     
- Partials       1259     1266       +7     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Collaborator

@Sleet01 Sleet01 left a comment

Choose a reason for hiding this comment

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

LGTM

@Sleet01 Sleet01 merged commit d1e8e45 into MegaMek:master May 29, 2024
4 checks 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.

3 participants