From dbb23f9cf7a492430766828ece135f4a17db495f Mon Sep 17 00:00:00 2001 From: Jacob Tong <10494922+ShadowCommander@users.noreply.github.com> Date: Mon, 31 Oct 2022 22:52:53 -0700 Subject: [PATCH] Fix butchering inside of a container making the target unbutcherable permenantly (#12328) --- Content.Server/Kitchen/EntitySystems/SharpSystem.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Content.Server/Kitchen/EntitySystems/SharpSystem.cs b/Content.Server/Kitchen/EntitySystems/SharpSystem.cs index 395ebffe52..8eba67555e 100644 --- a/Content.Server/Kitchen/EntitySystems/SharpSystem.cs +++ b/Content.Server/Kitchen/EntitySystems/SharpSystem.cs @@ -83,11 +83,11 @@ public sealed class SharpSystem : EntitySystem if (!TryComp(ev.Sharp, out var sharp)) return; + sharp.Butchering.Remove(ev.Entity); + if (_containerSystem.IsEntityInContainer(ev.Entity)) return; - sharp.Butchering.Remove(ev.Entity); - var spawnEntities = EntitySpawnCollection.GetSpawns(butcher.SpawnedEntities, _robustRandom); var coords = Transform(ev.Entity).MapPosition; EntityUid popupEnt = default;