mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2026-07-18 03:36:07 +01:00
Fixes ore boxes picking up strange rocks
Simple name check fix. Nothing should fill up, as the rock "bounces" out of the crate. Enjoy.
This commit is contained in:
@@ -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,"<span class='notice'>The [W] bounces out of the [src]!</span>")
|
||||
|
||||
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,"<span class='notice'>You empty the satchel into the box.</span>")
|
||||
to_chat(user,"<span class='notice'>You empty the satchel into the [src].</span>")
|
||||
|
||||
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
|
||||
|
||||
Reference in New Issue
Block a user