fix(ui): deleted units shouldn't be considered dead or alive#453
Merged
Conversation
…ces 3-state unit styling — alive, dead (killed), inactive (despawned/deleted) Units tab now distinguishes combat deaths (orange, kill event required) from despawned or pre-spawn units (greyed out), fixing false dead-styling in missions with frequent server-side cleanup (e.g. Antistasi, Zeus, etc). Respawned players correctly return to alive styling.
Contributor
There was a problem hiding this comment.
Code Review
This pull request introduces a distinction between 'dead' and 'inactive' unit statuses in the UnitsTab component. It replaces the binary alive/dead check with a more granular status helper that accounts for kill events and despawning. Corresponding CSS updates were made to style inactive units with dimmed text and dead units with a warning color. Additionally, new test cases were added to verify the styling logic for despawned, killed, and respawned units. I have no feedback to provide as there were no review comments.
Contributor
|
lgtm |
fank
approved these changes
May 24, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
introduces 3-state unit styling — alive, dead (killed), inactive (despawned/deleted)
Units tab now distinguishes combat deaths (orange, kill event required) from
despawned or pre-spawn units (greyed out), fixing false dead-styling in missions
with frequent server-side cleanup (e.g. Antistasi, Zeus, etc). Respawned players correctly
return to alive styling.
This maintains the intent of PR #422, making deleted units distinct from alive units, but now they are also distinct from dead units as well, making it easy to see the state of a group at a glance. Styling matches existing aesthetic and uses the color for "dead" that is used on the other tabs for death counts.
How to test
View a recording where some units die and some are deleted/despawned in game, you will see 3 different styles in the unit list.
View where a player dies and respawns, style will go alive > dead > alive (maintains existing behavior for players)
Checklist
cd ui && npm testpasses