From 56feab4e0bc74fbbb4186d0d19a238ebe068a199 Mon Sep 17 00:00:00 2001 From: Aaron Date: Fri, 18 Apr 2025 20:14:44 -0400 Subject: [PATCH] Add PreventFTLComponent and changed FTL check (#34077) * Add PreventFTLComponent and changed FTL check * Remove component body. --------- Co-authored-by: Milon --- .../Shuttles/Systems/ShuttleSystem.FasterThanLight.cs | 2 +- .../Shuttles/Components/PreventFTLComponent.cs | 9 +++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) create mode 100644 Content.Shared/Shuttles/Components/PreventFTLComponent.cs diff --git a/Content.Server/Shuttles/Systems/ShuttleSystem.FasterThanLight.cs b/Content.Server/Shuttles/Systems/ShuttleSystem.FasterThanLight.cs index cae6c443dd..40464e516f 100644 --- a/Content.Server/Shuttles/Systems/ShuttleSystem.FasterThanLight.cs +++ b/Content.Server/Shuttles/Systems/ShuttleSystem.FasterThanLight.cs @@ -243,7 +243,7 @@ public sealed partial class ShuttleSystem } } - if (HasComp(shuttleUid)) + if (HasComp(shuttleUid) || HasComp(shuttleUid)) { reason = Loc.GetString("shuttle-console-prevent"); return false; diff --git a/Content.Shared/Shuttles/Components/PreventFTLComponent.cs b/Content.Shared/Shuttles/Components/PreventFTLComponent.cs new file mode 100644 index 0000000000..343e1ffb06 --- /dev/null +++ b/Content.Shared/Shuttles/Components/PreventFTLComponent.cs @@ -0,0 +1,9 @@ +using Robust.Shared.GameStates; + +namespace Content.Shared.Shuttles.Components; + +/// +/// Add to grids that you do not want to FTL, but still might want to pilot. +/// +[RegisterComponent, NetworkedComponent] +public sealed partial class PreventFTLComponent : Component; -- 2.51.2