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.
Situation: Su-Ren casts Spirit Bend with Slow, Helio casts Battleforged with Unstoppable on the same target. If Unstoppable applied first, Spirit Bend just doesn't apply Slow and moves on. If Slow is applied first, Unstoppable dispels the whole Spirit Bend effect as it contains a movement debuff (and when Unstoppable wears off, the target still has Slow status but has full movement as there have been no status changes to trigger an update).
So it's a race condition resolved by actor order.
Solution 1: Allow effects to handle Unstoppable and remove movement debuff they have applied while keeping the effect itself active.
Solution 2: Effect has WillApplyStatus method which is not used in Rogues. Perhaps we can use it in ExecuteResults to resolve the race condition?
https://discord.com/channels/600425662452465701/1241828879618936893