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

Fix for #4796: NPE in Princess off-board artillery targeting #4799

Conversation

Sleet01
Copy link
Collaborator

@Sleet01 Sleet01 commented Sep 20, 2023

I got too "efficient" and didn't account for non-Artillery weapons on off-board
units. This caused an NPE when attempting to dereference non-existent ammo bins of energy weapons.

Fix is to only run the ADA check on Artillery weapons.

Testing: confirmed that Princess can pass the indirect fire declaration phase using off-board units in the provided save file.

Close #4796

@NickAragua NickAragua merged commit 59dee6b into MegaMek:master Sep 21, 2023
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.

[0.49.15] NPE during Artillery Phase Preventing Princess From Firing Offboard Artillery
2 participants