From 33e5e4e581a8d224cc2c44465db188ded0302e4e Mon Sep 17 00:00:00 2001 From: chromiumboy <50505512+chromiumboy@users.noreply.github.com> Date: Sat, 13 Apr 2024 22:01:01 -0500 Subject: [PATCH] Bug fix: Force cancellation of RCD constructions if the construction type is changed (#26935) Force cancellation of RCD constructions if the construction type is changed --- Content.Shared/RCD/Systems/RCDSystem.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Content.Shared/RCD/Systems/RCDSystem.cs b/Content.Shared/RCD/Systems/RCDSystem.cs index f172060ded..974755f000 100644 --- a/Content.Shared/RCD/Systems/RCDSystem.cs +++ b/Content.Shared/RCD/Systems/RCDSystem.cs @@ -230,13 +230,19 @@ public class RCDSystem : EntitySystem // Exit if the RCD prototype has changed if (component.ProtoId != args.Event.StartingProtoId) + { + args.Cancel(); return; + } // Ensure the RCD operation is still valid var location = GetCoordinates(args.Event.Location); if (!TryGetMapGridData(location, out var mapGridData)) + { + args.Cancel(); return; + } if (!IsRCDOperationStillValid(uid, component, mapGridData.Value, args.Event.Target, args.Event.User)) args.Cancel(); -- 2.51.2