From d682ecacfa2c5a4115e7dcffcfa734846819ae25 Mon Sep 17 00:00:00 2001
From: MASMC <9438930+the-og-gear@users.noreply.github.com>
Date: Sat, 6 Jul 2019 18:40:42 -0400
Subject: [PATCH] Fixes ore boxes picking up strange rocks
Simple name check fix. Nothing should fill up, as the rock "bounces" out
of the crate. Enjoy.
---
code/modules/mining/satchel_ore_boxdm.dm | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/code/modules/mining/satchel_ore_boxdm.dm b/code/modules/mining/satchel_ore_boxdm.dm
index b904a7cfad..99ad0568a8 100644
--- a/code/modules/mining/satchel_ore_boxdm.dm
+++ b/code/modules/mining/satchel_ore_boxdm.dm
@@ -12,8 +12,11 @@
/obj/structure/ore_box/attackby(obj/item/weapon/W as obj, mob/user as mob)
if (istype(W, /obj/item/weapon/ore))
- user.remove_from_mob(W)
- src.contents += W
+ if (W.name != "strange rock")
+ user.remove_from_mob(W)
+ src.contents += W
+ else
+ to_chat(user,"The [W] bounces out of the [src]!")
else if (istype(W, /obj/item/weapon/storage))
var/obj/item/weapon/storage/S = W
@@ -22,7 +25,7 @@
S.hide_from(usr)
for(var/obj/item/weapon/ore/O in S.contents)
S.remove_from_storage(O, src) //This will move the item to this item's contents
- to_chat(user,"You empty the satchel into the box.")
+ to_chat(user,"You empty the satchel into the [src].")
update_ore_count()
@@ -33,7 +36,6 @@
stored_ore = list()
for(var/obj/item/weapon/ore/O in contents)
-
if(stored_ore[O.name])
stored_ore[O.name]++
else