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

SV armor weight and space calculations #5186

Merged
merged 2 commits into from
Feb 20, 2024
Merged

SV armor weight and space calculations #5186

merged 2 commits into from
Feb 20, 2024

Conversation

neoancient
Copy link
Member

Fixes two issues with SV armor:

  1. I left out the multiplier that accounts for the number of points when calculating the armor weight, resulting in the weight always being calculated for a single point.
  2. The svslots field in EquipmentType is initialized to -1, which is supposed to indicate that it uses the mech slots value. ArmorType sets all the values explicitly when they are not zero, so I added initialization to zero in the constructor.

Fixes MegaMek/megameklab#1430.

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.

Looks good to me!

@SJuliez SJuliez merged commit 37ad30a into master Feb 20, 2024
4 checks passed
@SJuliez SJuliez deleted the sv_armor_weight branch April 20, 2024 09:10
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.

Support vehicle armor is bugged
3 participants