]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Allow strip removing items if you're holding something (#32750)
authorPieter-Jan Briers <pieterjan.briers+git@gmail.com>
Fri, 18 Oct 2024 19:20:04 +0000 (21:20 +0200)
committerGitHub <noreply@github.com>
Fri, 18 Oct 2024 19:20:04 +0000 (21:20 +0200)
You were already able to strip more items at once from somebody than you could hold, and they would drop to the floor. This matched the behavior in SS13.

Annoyingly, however, you were not allowed to *start* a stripping action if you're holding something. This just feels like an annoying paper cut, so this is no longer a thing.

Content.Shared/Strip/SharedStrippableSystem.cs

index e1c3d8ef0d86c8781a89ccbd2797d30d0fb59aac..7afe503275a1d2bab0313bf65fc044e2c66f6e05 100644 (file)
@@ -103,7 +103,7 @@ public abstract class SharedStrippableSystem : EntitySystem
 
         if (userHands.ActiveHandEntity != null && !hasEnt)
             StartStripInsertInventory((user, userHands), strippable.Owner, userHands.ActiveHandEntity.Value, args.Slot);
-        else if (userHands.ActiveHandEntity == null && hasEnt)
+        else if (hasEnt)
             StartStripRemoveInventory(user, strippable.Owner, held!.Value, args.Slot);
     }
 
@@ -135,7 +135,7 @@ public abstract class SharedStrippableSystem : EntitySystem
 
         if (user.Comp.ActiveHandEntity != null && handSlot.HeldEntity == null)
             StartStripInsertHand(user, target, user.Comp.ActiveHandEntity.Value, handId, targetStrippable);
-        else if (user.Comp.ActiveHandEntity == null && handSlot.HeldEntity != null)
+        else if (handSlot.HeldEntity != null)
             StartStripRemoveHand(user, target, handSlot.HeldEntity.Value, handId, targetStrippable);
     }