From 7ed51e3d503b11ed97f81526ea89273ea4f94aab Mon Sep 17 00:00:00 2001 From: PuroSlavKing <103608145+PuroSlavKing@users.noreply.github.com> Date: Thu, 26 Dec 2024 13:26:01 +0300 Subject: [PATCH] Update Content.Server/_White/Headcrab/HeadcrabSystem.cs Co-authored-by: Spatison <137375981+Spatison@users.noreply.github.com> --- Content.Server/_White/Headcrab/HeadcrabSystem.cs | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Content.Server/_White/Headcrab/HeadcrabSystem.cs b/Content.Server/_White/Headcrab/HeadcrabSystem.cs index 16bbc070cc..178266ddbf 100644 --- a/Content.Server/_White/Headcrab/HeadcrabSystem.cs +++ b/Content.Server/_White/Headcrab/HeadcrabSystem.cs @@ -104,10 +104,9 @@ private void OnGotEquipped(EntityUid uid, HeadcrabComponent component, GotEquipp private void OnUnequipAttempt(EntityUid uid, HeadcrabComponent component, BeingUnequippedAttemptEvent args) { if (args.Slot != "mask") - return; - if (component.EquippedOn != args.Unequipee) - return; - if (HasComp(args.Unequipee)) + || component.EquippedOn != args.Unequipee) + || HasComp(args.Unequipee) + || _mobState.IsDead(uid)) return; _popup.PopupEntity(Loc.GetString("headcrab-try-unequip"), args.Unequipee, args.Unequipee, PopupType.Large);