From 101854f00a13fed79d8ee77be9facb668c196d22 Mon Sep 17 00:00:00 2001 From: Tayrtahn Date: Wed, 14 May 2025 18:02:51 -0400 Subject: [PATCH] Cleanup warnings in `AtmosAlarmableVisualsSystem` (#37459) Cleanup warnings in AtmosAlarmableVisualsSystem --- .../Atmos/Monitor/AtmosAlarmableVisualsSystem.cs | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/Content.Client/Atmos/Monitor/AtmosAlarmableVisualsSystem.cs b/Content.Client/Atmos/Monitor/AtmosAlarmableVisualsSystem.cs index 18ca223475..6d3a373759 100644 --- a/Content.Client/Atmos/Monitor/AtmosAlarmableVisualsSystem.cs +++ b/Content.Client/Atmos/Monitor/AtmosAlarmableVisualsSystem.cs @@ -7,9 +7,11 @@ namespace Content.Client.Atmos.Monitor; public sealed class AtmosAlarmableVisualsSystem : VisualizerSystem { + [Dependency] private readonly SpriteSystem _sprite = default!; + protected override void OnAppearanceChange(EntityUid uid, AtmosAlarmableVisualsComponent component, ref AppearanceChangeEvent args) { - if (args.Sprite == null || !args.Sprite.LayerMapTryGet(component.LayerMap, out var layer)) + if (args.Sprite == null || !_sprite.LayerMapTryGet((uid, args.Sprite), component.LayerMap, out var layer, false)) return; if (!args.AppearanceData.TryGetValue(PowerDeviceVisuals.Powered, out var poweredObject) || @@ -22,8 +24,8 @@ public sealed class AtmosAlarmableVisualsSystem : VisualizerSystem