Wires refactor (#7699)

Co-authored-by: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
Co-authored-by: Kara <lunarautomaton6@gmail.com>
This commit is contained in:
Flipp Syder
2022-05-05 19:35:06 -07:00
committed by GitHub
parent 39a35641ab
commit 2c6158e115
51 changed files with 2656 additions and 1660 deletions

View File

@@ -1,6 +1,6 @@
using Content.Server.Doors.Components;
using Content.Server.Power.Components;
using Content.Server.WireHacking;
using Content.Server.Wires;
using Content.Shared.Doors;
using Content.Shared.Doors.Components;
using Content.Shared.Doors.Systems;
@@ -15,6 +15,8 @@ namespace Content.Server.Doors.Systems
{
public sealed class AirlockSystem : SharedAirlockSystem
{
[Dependency] private readonly WiresSystem _wiresSystem = default!;
public override void Initialize()
{
base.Initialize();
@@ -128,7 +130,7 @@ namespace Content.Server.Doors.Systems
if (TryComp<WiresComponent>(uid, out var wiresComponent) && wiresComponent.IsPanelOpen &&
EntityManager.TryGetComponent(args.User, out ActorComponent? actor))
{
wiresComponent.OpenInterface(actor.PlayerSession);
_wiresSystem.OpenUserInterface(uid, actor.PlayerSession);
args.Handled = true;
}
}