diff --git a/Content.Client/SprayPainter/SprayPainterSystem.cs b/Content.Client/SprayPainter/SprayPainterSystem.cs index 8f7d7f0362..365aedd82a 100644 --- a/Content.Client/SprayPainter/SprayPainterSystem.cs +++ b/Content.Client/SprayPainter/SprayPainterSystem.cs @@ -22,9 +22,9 @@ public sealed class SprayPainterSystem : SharedSprayPainterSystem { [Dependency] private readonly UserInterfaceSystem _ui = default!; - public List Decals = []; - public Dictionary> PaintableGroupsByCategory = new(); - public Dictionary> PaintableStylesByGroup = new(); + public readonly List Decals = []; + public readonly Dictionary> PaintableGroupsByCategory = new(); + public readonly Dictionary> PaintableStylesByGroup = new(); public override void Initialize() { @@ -50,7 +50,8 @@ protected override void UpdateUi(Entity ent) private void OnPrototypesReloaded(PrototypesReloadedEventArgs args) { - if (!args.WasModified() || !args.WasModified() || !args.WasModified()) + if (!args.WasModified() || !args.WasModified() || + !args.WasModified()) return; CachePrototypes(); @@ -79,12 +80,10 @@ private void CachePrototypes() Decals.Clear(); foreach (var decalPrototype in Proto.EnumeratePrototypes().OrderBy(x => x.ID)) { - if (!decalPrototype.Tags.Contains("station") - && !decalPrototype.Tags.Contains("markings") - || decalPrototype.Tags.Contains("dirty")) + if (decalPrototype.Tags.Contains("dirty")) continue; - - Decals.Add(new SprayPainterDecalEntry(decalPrototype.ID, decalPrototype.Sprite)); + if (decalPrototype.Tags.Contains("station") && decalPrototype.Tags.Contains("markings")) + Decals.Add(new SprayPainterDecalEntry(decalPrototype.ID, decalPrototype.Sprite)); } } @@ -110,15 +109,15 @@ protected override void FrameUpdate(FrameEventArgs args) _lastPaintingDecals = _entity.Comp.DecalMode; - string modeLocString = _entity.Comp.DecalMode switch + var modeLocalization = _entity.Comp.DecalMode switch { DecalPaintMode.Add => "spray-painter-item-status-add", DecalPaintMode.Remove => "spray-painter-item-status-remove", - _ => "spray-painter-item-status-off" + _ => "spray-painter-item-status-off", }; _label.SetMarkupPermissive(Robust.Shared.Localization.Loc.GetString("spray-painter-item-status-label", - ("mode", Robust.Shared.Localization.Loc.GetString(modeLocString)))); + ("mode", Robust.Shared.Localization.Loc.GetString(modeLocalization)))); } } } diff --git a/Resources/Prototypes/_Null/Decals/pipes.yml b/Resources/Prototypes/_Null/Decals/pipes.yml index 4861fb3073..4e92d34480 100644 --- a/Resources/Prototypes/_Null/Decals/pipes.yml +++ b/Resources/Prototypes/_Null/Decals/pipes.yml @@ -1,6 +1,6 @@ - type: decal id: Pipes - tags: ["station"] + tags: ["station", "markings"] sprite: sprite: Decals/pipes.rsi state: pipes diff --git a/Resources/Prototypes/_Null/Decals/spesos.yml b/Resources/Prototypes/_Null/Decals/spesos.yml new file mode 100644 index 0000000000..0a086e3882 --- /dev/null +++ b/Resources/Prototypes/_Null/Decals/spesos.yml @@ -0,0 +1,6 @@ +- type: decal + id: speso + tags: ["station", "markings"] + sprite: + sprite: Decals/speso.rsi + state: speso diff --git a/Resources/Textures/Decals/speso.rsi/meta.json b/Resources/Textures/Decals/speso.rsi/meta.json new file mode 100644 index 0000000000..4bd41cfd23 --- /dev/null +++ b/Resources/Textures/Decals/speso.rsi/meta.json @@ -0,0 +1,14 @@ +{ + "version": 1, + "license": "CC0-1.0", + "copyright": "Edited Speso Sprite", + "size": { + "x": 32, + "y": 32 + }, + "states": [ + { + "name": "speso" + } + ] +} diff --git a/Resources/Textures/Decals/speso.rsi/speso.png b/Resources/Textures/Decals/speso.rsi/speso.png new file mode 100644 index 0000000000..b11a08a1cd Binary files /dev/null and b/Resources/Textures/Decals/speso.rsi/speso.png differ