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

Removed End of Contract and Manual Resupplies; Fixed Smuggler Prices; Added Remove SP Button #5723

Merged
merged 5 commits into from
Jan 9, 2025

Conversation

IllianiCBT
Copy link
Collaborator

  • Removed End of Contract Resupplies. These were giving users too much stuff for free, as they were based on remaining SP which ballooned due to the new SP generation changes.
  • Removed Manual Resupplies. These were made too effective due to the recent SP generation changes.
  • Smugglers now correctly use sticker price and not sale price when determining how much to charge.
  • Added the ability to GM Remove SP to StratCon.
  • Updated documentation.

Fix #5717

Consolidated StratCon support point management by removing resupply mechanics and replacing the "Request Resupply" button with "Remove SP (GM)." Simplified codebase by eliminating unused resupply-related logic, improving maintainability. Updated UI labels and button actions accordingly.
Updated the cost calculation to use `buyValue` instead of `sellValue` for smuggler resupplies. This ensures the correct pricing logic is applied when determining convoy contents value.
@IllianiCBT IllianiCBT added Bug StratCon Bugs relating strictly to StratCon Documentation labels Jan 9, 2025
@IllianiCBT IllianiCBT self-assigned this Jan 9, 2025
AtBContract contract = currentCampaignState.getContract();
Resupply resupply = new Resupply(campaign, contract, ResupplyType.RESUPPLY_NORMAL);
performResupply(resupply, contract);
private void removeSP(ActionEvent event) {

Check notice

Code scanning / CodeQL

Useless parameter Note

The parameter 'event' is never used.
@Sleet01 Sleet01 merged commit 4ae5f84 into MegaMek:master Jan 9, 2025
4 checks passed
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 10.19%. Comparing base (16ea3f7) to head (e6d6cda).
Report is 22 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff              @@
##             master    #5723      +/-   ##
============================================
- Coverage     10.21%   10.19%   -0.02%     
+ Complexity     6070     6062       -8     
============================================
  Files          1009     1010       +1     
  Lines        139242   139310      +68     
  Branches      20437    20448      +11     
============================================
- Hits          14221    14204      -17     
- Misses       123651   123734      +83     
- Partials       1370     1372       +2     

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Documentation StratCon Bugs relating strictly to StratCon
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Issue] Massive end of contract Payout. 50.02
4 participants