Revert "12/21 modernizations from TG live"
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
//Also contains /obj/structure/closet/body_bag because I doubt anyone would think to look for bodybags in /object/structures
|
||||
|
||||
/obj/item/bodybag
|
||||
name = "body bag"
|
||||
@@ -5,22 +6,14 @@
|
||||
icon = 'icons/obj/bodybag.dmi'
|
||||
icon_state = "bodybag_folded"
|
||||
var/unfoldedbag_path = /obj/structure/closet/body_bag
|
||||
w_class = WEIGHT_CLASS_SMALL
|
||||
w_class = 2
|
||||
|
||||
/obj/item/bodybag/attack_self(mob/user)
|
||||
deploy_bodybag(user, user.loc)
|
||||
|
||||
/obj/item/bodybag/afterattack(atom/target, mob/user, proximity)
|
||||
if(proximity)
|
||||
if(isopenturf(target))
|
||||
deploy_bodybag(user, target)
|
||||
|
||||
/obj/item/bodybag/proc/deploy_bodybag(mob/user, atom/location)
|
||||
var/obj/structure/closet/body_bag/R = new unfoldedbag_path(location)
|
||||
R.open(user)
|
||||
var/obj/structure/closet/body_bag/R = new unfoldedbag_path(user.loc)
|
||||
R.add_fingerprint(user)
|
||||
qdel(src)
|
||||
|
||||
|
||||
/obj/item/weapon/storage/box/bodybags
|
||||
name = "body bags"
|
||||
desc = "The label indicates that it contains body bags."
|
||||
@@ -32,6 +25,66 @@
|
||||
new /obj/item/bodybag(src)
|
||||
|
||||
|
||||
/obj/structure/closet/body_bag
|
||||
name = "body bag"
|
||||
desc = "A plastic bag designed for the storage and transportation of cadavers."
|
||||
icon = 'icons/obj/bodybag.dmi'
|
||||
icon_state = "bodybag"
|
||||
var/foldedbag_path = /obj/item/bodybag
|
||||
var/tagged = 0 // so closet code knows to put the tag overlay back
|
||||
density = 0
|
||||
mob_storage_capacity = 2
|
||||
open_sound = 'sound/items/zip.ogg'
|
||||
close_sound = 'sound/items/zip.ogg'
|
||||
|
||||
|
||||
/obj/structure/closet/body_bag/attackby(obj/item/I, mob/user, params)
|
||||
if (istype(I, /obj/item/weapon/pen) || istype(I, /obj/item/toy/crayon))
|
||||
var/t = stripped_input(user, "What would you like the label to be?", name, null, 53)
|
||||
if(user.get_active_hand() != I)
|
||||
return
|
||||
if(!in_range(src, user) && loc != user)
|
||||
return
|
||||
if(t)
|
||||
name = "body bag - [t]"
|
||||
tagged = 1
|
||||
update_icon()
|
||||
else
|
||||
name = "body bag"
|
||||
return
|
||||
else if(istype(I, /obj/item/weapon/wirecutters))
|
||||
user << "<span class='notice'>You cut the tag off [src].</span>"
|
||||
name = "body bag"
|
||||
tagged = 0
|
||||
update_icon()
|
||||
|
||||
/obj/structure/closet/body_bag/update_icon()
|
||||
..()
|
||||
if (tagged)
|
||||
add_overlay("bodybag_label")
|
||||
|
||||
/obj/structure/closet/body_bag/close()
|
||||
if(..())
|
||||
density = 0
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
/obj/structure/closet/body_bag/MouseDrop(over_object, src_location, over_location)
|
||||
..()
|
||||
if(over_object == usr && Adjacent(usr) && (in_range(src, usr) || usr.contents.Find(src)))
|
||||
if(!ishuman(usr))
|
||||
return 0
|
||||
if(opened)
|
||||
return 0
|
||||
if(contents.len)
|
||||
return 0
|
||||
visible_message("<span class='notice'>[usr] folds up [src].</span>")
|
||||
var/obj/item/bodybag/B = new foldedbag_path(get_turf(src))
|
||||
usr.put_in_hands(B)
|
||||
qdel(src)
|
||||
|
||||
|
||||
// Bluespace bodybag
|
||||
|
||||
/obj/item/bodybag/bluespace
|
||||
@@ -40,6 +93,15 @@
|
||||
icon = 'icons/obj/bodybag.dmi'
|
||||
icon_state = "bluebodybag_folded"
|
||||
unfoldedbag_path = /obj/structure/closet/body_bag/bluespace
|
||||
w_class = WEIGHT_CLASS_SMALL
|
||||
w_class = 2
|
||||
origin_tech = "bluespace=4;materials=4;plasmatech=4"
|
||||
|
||||
/obj/structure/closet/body_bag/bluespace
|
||||
name = "bluespace body bag"
|
||||
desc = "A bluespace body bag designed for the storage and transportation of cadavers."
|
||||
icon = 'icons/obj/bodybag.dmi'
|
||||
icon_state = "bluebodybag"
|
||||
foldedbag_path = /obj/item/bodybag/bluespace
|
||||
density = 0
|
||||
mob_storage_capacity = 15
|
||||
max_mob_size = MOB_SIZE_LARGE
|
||||
|
||||
Reference in New Issue
Block a user