Fixed Tipped ammo not being Spent (#25167)

Fix Tipped Ammo not being Spent
This commit is contained in:
PoorMansDreams
2024-02-13 13:40:15 -08:00
committed by GitHub
parent 6b16bda9f3
commit e40318b831
7 changed files with 50 additions and 7 deletions

View File

@@ -17,4 +17,5 @@ public sealed partial class SpentAmmoVisualsComponent : Component
public enum AmmoVisualLayers : byte
{
Base,
Tip,
}

View File

@@ -30,5 +30,8 @@ public sealed partial class GunSystem
state = component.State;
sprite.LayerSetState(AmmoVisualLayers.Base, state);
if (sprite.LayerExists(AmmoVisualLayers.Tip)){
sprite.RemoveLayer(AmmoVisualLayers.Tip);
}
}
}