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

Make GetUISummary_UnitStatusIcons() skip empty status icons #1122

Merged
merged 2 commits into from
Feb 27, 2022

Conversation

Iridar
Copy link
Contributor

@Iridar Iridar commented Jan 6, 2022

Fixes #1120

This will fix the bug where status icons would not display sometimes.

@Iridar Iridar self-assigned this Jan 6, 2022
@Iridar Iridar added this to the 1.24.0 milestone Jan 6, 2022
@Iridar Iridar added the ready-to-review A pull request is ready to be reviewed label Jan 6, 2022
@Iridar
Copy link
Contributor Author

Iridar commented Jan 6, 2022

I've tested and can confirm the fix works. My test was:

  1. Use current Highlander
  2. Go to TQL, spawn a few Advent Troopers.
  3. Throw a Freeze Grenade at an Advent Trooper. Freeze grenade doesn't have a status icon set up, so it won't be displayed, but vanilla logic would try to display it anyway.
  4. Launch a Napalm Rocket from my Rocket Launchers mod, which does have a status icon set up.
  5. The status icon doesn't show up on the frozen enemy, but shows up on other enemies, since they don't have other display-able persistent effects applied to them before the napalm effect.

Then I applied the suggested fix in Issue #1120 and tested again, this time the Napalm effect status icon showed up for both frozen and unfrozen enemies.

@Iridar
Copy link
Contributor Author

Iridar commented Jan 6, 2022

I didn't do a HLDocs\ref-bugfixes entry for this one, since there's no room around and I wasn't sure how to handle it.

Copy link
Member

@Xymanek Xymanek left a comment

Choose a reason for hiding this comment

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

Please add HL-Docs: ref:Bugfixes

since there's no room around and I wasn't sure how to handle it

I would put it above the if

@Xymanek Xymanek added waiting-on-author A pull request is waiting on changes from the author and removed ready-to-review A pull request is ready to be reviewed labels Feb 26, 2022
@Iridar
Copy link
Contributor Author

Iridar commented Feb 27, 2022

Doneso.

@Iridar Iridar added ready-to-review A pull request is ready to be reviewed and removed waiting-on-author A pull request is waiting on changes from the author labels Feb 27, 2022
@Xymanek Xymanek merged commit b4a3f68 into X2CommunityCore:master Feb 27, 2022
@Iridar Iridar deleted the 1120-GetUISummary-fix branch October 29, 2023 06:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug-basegame ready-to-review A pull request is ready to be reviewed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

XComGameStateUnit.GetUISummary_UnitStatusIcons returns blank image links
2 participants