Storage implants drop their items when removed.

This commit is contained in:
bgobandit
2019-05-26 20:15:45 -04:00
parent 6636712a4d
commit 243dd8f377
2 changed files with 10 additions and 4 deletions
@@ -10,10 +10,16 @@
SEND_SIGNAL(src, COMSIG_TRY_STORAGE_SHOW, imp_in, TRUE)
/obj/item/implant/storage/removed(source, silent = FALSE, special = 0)
if(!special)
var/datum/component/storage/lostimplant = GetComponent(/datum/component/storage/concrete/implant)
var/mob/living/implantee = source
for (var/obj/item/I in lostimplant.contents())
I.add_mob_blood(implantee)
lostimplant.do_quick_empty()
implantee.visible_message("<span class='warning'>A bluespace pocket opens around [src] as it exits [implantee], spewing out its contents and rupturing the surrounding tissue!</span>")
implantee.apply_damage(20, BRUTE, BODY_ZONE_CHEST)
qdel(lostimplant)
. = ..()
if(.)
if(!special)
qdel(GetComponent(/datum/component/storage/concrete/implant))
/obj/item/implant/storage/implant(mob/living/target, mob/user, silent = FALSE, force = FALSE)
for(var/X in target.implants)