Remove some obsolete AppearanceComponent method usages (#13726)

This commit is contained in:
Visne
2023-02-02 17:34:53 +01:00
committed by GitHub
parent 23b90de34d
commit 5a5a3afbb1
111 changed files with 428 additions and 349 deletions

View File

@@ -24,6 +24,7 @@ namespace Content.Server.Atmos.Piping.Binary.EntitySystems
[Dependency] private readonly IAdminLogManager _adminLogger = default!;
[Dependency] private readonly AtmosphereSystem _atmosphereSystem = default!;
[Dependency] private readonly SharedAmbientSoundSystem _ambientSoundSystem = default!;
[Dependency] private readonly SharedAppearanceSystem _appearance = default!;
public override void Initialize()
{
@@ -146,7 +147,7 @@ namespace Content.Server.Atmos.Piping.Binary.EntitySystems
if (!Resolve(uid, ref pump, ref appearance, false))
return;
appearance.SetData(PumpVisuals.Enabled, pump.Enabled);
_appearance.SetData(uid, PumpVisuals.Enabled, pump.Enabled, appearance);
}
}
}

View File

@@ -6,6 +6,7 @@ using Content.Shared.Audio;
using Content.Shared.Examine;
using Content.Shared.Interaction;
using JetBrains.Annotations;
using Robust.Server.GameObjects;
using Robust.Shared.Audio;
using Robust.Shared.Player;
@@ -15,6 +16,7 @@ namespace Content.Server.Atmos.Piping.Binary.EntitySystems
public sealed class GasValveSystem : EntitySystem
{
[Dependency] private readonly SharedAmbientSoundSystem _ambientSoundSystem = default!;
[Dependency] private readonly SharedAppearanceSystem _appearance = default!;
public override void Initialize()
{
@@ -58,7 +60,7 @@ namespace Content.Server.Atmos.Piping.Binary.EntitySystems
{
if (TryComp<AppearanceComponent>(component.Owner,out var appearance))
{
appearance.SetData(FilterVisuals.Enabled, component.Open);
_appearance.SetData(uid, FilterVisuals.Enabled, component.Open, appearance);
}
if (component.Open)
{

View File

@@ -26,6 +26,7 @@ namespace Content.Server.Atmos.Piping.Binary.EntitySystems
[Dependency] private readonly AtmosphereSystem _atmosphereSystem = default!;
[Dependency] private readonly UserInterfaceSystem _userInterfaceSystem = default!;
[Dependency] private readonly SharedAmbientSoundSystem _ambientSoundSystem = default!;
[Dependency] private readonly SharedAppearanceSystem _appearance = default!;
public override void Initialize()
{
@@ -160,7 +161,7 @@ namespace Content.Server.Atmos.Piping.Binary.EntitySystems
if (!Resolve(uid, ref pump, ref appearance, false))
return;
appearance.SetData(PumpVisuals.Enabled, pump.Enabled);
_appearance.SetData(uid, PumpVisuals.Enabled, pump.Enabled, appearance);
}
}
}