Fix damage colour persisting (#12469)

Probably. Easiest way to repro is make spaceman go horizontal and most of the time the red colour persists when the rotation animation starts.
This commit is contained in:
metalgearsloth
2022-11-09 06:58:21 +11:00
committed by GitHub
parent 724074426e
commit c7d4fd3cba

View File

@@ -22,6 +22,9 @@ public sealed partial class MeleeWeaponSystem
private void OnEffectAnimation(EntityUid uid, DamageEffectComponent component, AnimationCompletedEvent args)
{
if (args.Key != DamageAnimationKey)
return;
if (TryComp<SpriteComponent>(uid, out var sprite))
{
sprite.Color = component.Color;