From 2187aef90449824643d247e392eb7462d948d465 Mon Sep 17 00:00:00 2001
From: slarticodefast <161409025+slarticodefast@users.noreply.github.com>
Date: Mon, 9 Sep 2024 13:02:15 +0200
Subject: [PATCH] Make mobs without hands unable to spill jugs (#31438)
* make mobs without hands unable to spill jugs
* snails
---
.../Fluids/Components/PreventSpillerComponent.cs | 12 ------------
.../Fluids/SharedPuddleSystem.Spillable.cs | 6 +-----
Resources/Prototypes/Entities/Mobs/NPCs/animals.yml | 1 -
Resources/Prototypes/Entities/Mobs/NPCs/space.yml | 3 +--
4 files changed, 2 insertions(+), 20 deletions(-)
delete mode 100644 Content.Shared/Fluids/Components/PreventSpillerComponent.cs
diff --git a/Content.Shared/Fluids/Components/PreventSpillerComponent.cs b/Content.Shared/Fluids/Components/PreventSpillerComponent.cs
deleted file mode 100644
index e396d9faf5..0000000000
--- a/Content.Shared/Fluids/Components/PreventSpillerComponent.cs
+++ /dev/null
@@ -1,12 +0,0 @@
-using Robust.Shared.GameStates;
-
-namespace Content.Shared.Fluids.Components;
-
-///
-/// Blocks this entity's ability to spill solution containing entities via the verb menu.
-///
-[RegisterComponent, NetworkedComponent]
-public sealed partial class PreventSpillerComponent : Component
-{
-
-}
diff --git a/Content.Shared/Fluids/SharedPuddleSystem.Spillable.cs b/Content.Shared/Fluids/SharedPuddleSystem.Spillable.cs
index f88f13e8b0..2ce008da26 100644
--- a/Content.Shared/Fluids/SharedPuddleSystem.Spillable.cs
+++ b/Content.Shared/Fluids/SharedPuddleSystem.Spillable.cs
@@ -34,7 +34,7 @@ public abstract partial class SharedPuddleSystem
private void AddSpillVerb(Entity entity, ref GetVerbsEvent args)
{
- if (!args.CanAccess || !args.CanInteract)
+ if (!args.CanAccess || !args.CanInteract || args.Hands == null)
return;
if (!_solutionContainerSystem.TryGetSolution(args.Target, entity.Comp.SolutionName, out var soln, out var solution))
@@ -46,10 +46,6 @@ public abstract partial class SharedPuddleSystem
if (solution.Volume == FixedPoint2.Zero)
return;
- if (HasComp(args.User))
- return;
-
-
Verb verb = new()
{
Text = Loc.GetString("spill-target-verb-get-data-text")
diff --git a/Resources/Prototypes/Entities/Mobs/NPCs/animals.yml b/Resources/Prototypes/Entities/Mobs/NPCs/animals.yml
index 4e37a5ca3f..b11c1a50c6 100644
--- a/Resources/Prototypes/Entities/Mobs/NPCs/animals.yml
+++ b/Resources/Prototypes/Entities/Mobs/NPCs/animals.yml
@@ -1719,7 +1719,6 @@
price: 50
- type: BadFood
- type: NonSpreaderZombie
- - type: PreventSpiller
- type: FireVisuals
sprite: Mobs/Effects/onfire.rsi
normalState: Mouse_burning
diff --git a/Resources/Prototypes/Entities/Mobs/NPCs/space.yml b/Resources/Prototypes/Entities/Mobs/NPCs/space.yml
index bba4d44265..a51fe52238 100644
--- a/Resources/Prototypes/Entities/Mobs/NPCs/space.yml
+++ b/Resources/Prototypes/Entities/Mobs/NPCs/space.yml
@@ -484,7 +484,6 @@
price: 50
- type: BadFood
- type: NonSpreaderZombie
- - type: PreventSpiller
- type: FireVisuals
sprite: Mobs/Effects/onfire.rsi
normalState: Mouse_burning
@@ -506,7 +505,7 @@
visualType: Large
messages: [ "snail-hurt-by-salt-popup" ]
probability: 0.66
-
+
- type: entity
parent: MobSnail
id: MobSnailInstantDeath
--
2.51.2