From 1a0b108bdd3dfb2c6daba1f2a6fc54eaaf917c69 Mon Sep 17 00:00:00 2001 From: ScarKy0 <106310278+ScarKy0@users.noreply.github.com> Date: Thu, 22 Jan 2026 10:44:31 +0100 Subject: [PATCH] Force-prying crit borgs opens borg panel (#42460) yeah --- .../Lock/BypassLock/Components/BypassLockComponent.cs | 8 +++++++- .../Lock/BypassLock/Systems/BypassLockSystem.cs | 9 ++++++++- .../Entities/Mobs/Cyborgs/base_borg_chassis.yml | 1 + 3 files changed, 16 insertions(+), 2 deletions(-) diff --git a/Content.Shared/Lock/BypassLock/Components/BypassLockComponent.cs b/Content.Shared/Lock/BypassLock/Components/BypassLockComponent.cs index 38c6275d86..377c12cc6d 100644 --- a/Content.Shared/Lock/BypassLock/Components/BypassLockComponent.cs +++ b/Content.Shared/Lock/BypassLock/Components/BypassLockComponent.cs @@ -21,5 +21,11 @@ public sealed partial class BypassLockComponent : Component /// Amount of time in seconds it takes to bypass /// [DataField] - public TimeSpan BypassDelay = TimeSpan.FromSeconds(5f); + public TimeSpan BypassDelay = TimeSpan.FromSeconds(4f); + + /// + /// Whether the wirepanel should be opened as well, if one exists. + /// + [DataField] + public bool OpenWiresPanel = false; } diff --git a/Content.Shared/Lock/BypassLock/Systems/BypassLockSystem.cs b/Content.Shared/Lock/BypassLock/Systems/BypassLockSystem.cs index 1dcc4ee74a..406e898c59 100644 --- a/Content.Shared/Lock/BypassLock/Systems/BypassLockSystem.cs +++ b/Content.Shared/Lock/BypassLock/Systems/BypassLockSystem.cs @@ -6,6 +6,7 @@ using Content.Shared.Lock.BypassLock.Components; using Content.Shared.Tools; using Content.Shared.Tools.Systems; using Content.Shared.Verbs; +using Content.Shared.Wires; using Robust.Shared.Prototypes; using Robust.Shared.Serialization; @@ -16,6 +17,7 @@ public sealed partial class BypassLockSystem : EntitySystem [Dependency] private readonly ISharedAdminLogManager _adminLogger = default!; [Dependency] private readonly LockSystem _lock = default!; [Dependency] private readonly SharedToolSystem _tool = default!; + [Dependency] private readonly SharedWiresSystem _wires = default!; public override void Initialize() { @@ -32,7 +34,7 @@ public sealed partial class BypassLockSystem : EntitySystem { if (target.Owner == args.User) return; - + if (!_tool.HasQuality(args.Used, target.Comp.BypassingTool) || !_lock.IsLocked(target.Owner)) return; @@ -70,6 +72,11 @@ public sealed partial class BypassLockSystem : EntitySystem return; _lock.Unlock(target, args.User, target.Comp); + + if (TryComp(target, out var wiresPanel) && + TryComp(target, out var bypassLock) && bypassLock.OpenWiresPanel) + _wires.TogglePanel(target, wiresPanel, true, args.User); + } private void OnGetVerb(Entity target, ref GetVerbsEvent args) diff --git a/Resources/Prototypes/Entities/Mobs/Cyborgs/base_borg_chassis.yml b/Resources/Prototypes/Entities/Mobs/Cyborgs/base_borg_chassis.yml index ed61df6eff..b20116333f 100644 --- a/Resources/Prototypes/Entities/Mobs/Cyborgs/base_borg_chassis.yml +++ b/Resources/Prototypes/Entities/Mobs/Cyborgs/base_borg_chassis.yml @@ -247,6 +247,7 @@ flatReductions: Heat: 10 # capable of touching light bulbs and stoves without feeling pain! - type: BypassLock + openWiresPanel: true - type: BypassLockRequiresMobState requiredMobState: - Critical -- 2.52.0