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

Add a bool flag to use ability's minimum damage for Unit Flag damage preview #1282

Merged
merged 2 commits into from
Oct 29, 2023

Conversation

Iridar
Copy link
Contributor

@Iridar Iridar commented Oct 29, 2023

Fixes #579

Adds a bool flag to force UIUnitFlagManager to use ability's min damage over max damage for the on-the-flag damage preview.

I don't think a hook/event is warranted.

The diff looks uglier than it should, I pretty much just made: if (bool_flag) { new logic } else { original logic }

Did a brief test, seemed to work as intended for both targeted and mouse-hover melee abilities.

@Iridar Iridar added this to the 1.27.0 milestone Oct 29, 2023
@Iridar Iridar self-assigned this Oct 29, 2023
@Iridar Iridar changed the title 579 min damage preview Add a bool flag to use ability's minimum damage for Unit Flag damage preview Oct 29, 2023
@Iridar Iridar added the ready-to-review A pull request is ready to be reviewed label Oct 29, 2023
@Iridar Iridar merged commit 689735d into X2CommunityCore:master Oct 29, 2023
4 checks passed
@Iridar Iridar deleted the 579-min-damage-preview branch October 29, 2023 16:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement ready-to-review A pull request is ready to be reviewed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow mods to show min damage previews rather than max
2 participants