mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-27 15:17:01 +01:00
Merge pull request #8830 from Jordie0608/howdoyouknowyourbestfriendisntsecretlyawizard
Icon_door customability fix
This commit is contained in:
@@ -37,7 +37,10 @@
|
||||
if(welded)
|
||||
overlays += "welded"
|
||||
else
|
||||
overlays += "[icon_state]_open"
|
||||
if(icon_door)
|
||||
overlays += "[icon_door]_open"
|
||||
else
|
||||
overlays += "[icon_state]_open"
|
||||
|
||||
/obj/structure/closet/alter_health()
|
||||
return get_turf(src)
|
||||
|
||||
@@ -1,22 +1,20 @@
|
||||
/obj/structure/closet/secure_closet
|
||||
name = "secure locker"
|
||||
desc = "It's an immobile card-locked storage unit."
|
||||
density = 1
|
||||
opened = 0
|
||||
locked = 1
|
||||
icon_state = "secure"
|
||||
wall_mounted = 0 //never solid (You can always pass over it)
|
||||
health = 200
|
||||
|
||||
/obj/structure/closet/secure_closet/update_icon()//Putting the welded stuff in updateicon() so it's easy to overwrite for special cases (Fridges, cabinets, and whatnot)
|
||||
..()
|
||||
if(!broken)
|
||||
if(locked)
|
||||
overlays += "locked"
|
||||
if(!opened)
|
||||
if(!broken)
|
||||
if(locked)
|
||||
overlays += "locked"
|
||||
else
|
||||
overlays += "unlocked"
|
||||
else
|
||||
overlays += "unlocked"
|
||||
else
|
||||
overlays += "off"
|
||||
overlays += "off"
|
||||
|
||||
/obj/structure/closet/secure_closet/examine(mob/user)
|
||||
..()
|
||||
|
||||
@@ -11,6 +11,10 @@
|
||||
var/sound_effect_open = 'sound/machines/click.ogg'
|
||||
var/sound_effect_close = 'sound/machines/click.ogg'
|
||||
|
||||
/obj/structure/closet/crate/New()
|
||||
..()
|
||||
update_icon()
|
||||
|
||||
/obj/structure/closet/crate/update_icon()
|
||||
if(opened)
|
||||
icon_state = "[icon_crate]open"
|
||||
@@ -107,25 +111,21 @@
|
||||
/obj/structure/closet/crate/secure/weapon
|
||||
desc = "A secure weapons crate."
|
||||
name = "weapons crate"
|
||||
icon = 'icons/obj/storage.dmi'
|
||||
icon_crate = "weaponcrate"
|
||||
|
||||
/obj/structure/closet/crate/secure/plasma
|
||||
desc = "A secure plasma crate."
|
||||
name = "plasma crate"
|
||||
icon = 'icons/obj/storage.dmi'
|
||||
icon_crate = "plasmacrate"
|
||||
|
||||
/obj/structure/closet/crate/secure/gear
|
||||
desc = "A secure gear crate."
|
||||
name = "gear crate"
|
||||
icon = 'icons/obj/storage.dmi'
|
||||
icon_crate = "secgearcrate"
|
||||
|
||||
/obj/structure/closet/crate/secure/hydrosec
|
||||
desc = "A crate with a lock on it, painted in the scheme of the station's botanists."
|
||||
name = "secure hydroponics crate"
|
||||
icon = 'icons/obj/storage.dmi'
|
||||
icon_crate = "hydrosecurecrate"
|
||||
|
||||
/obj/structure/closet/crate/secure/New()
|
||||
@@ -145,20 +145,16 @@
|
||||
|
||||
/obj/structure/closet/crate/open()
|
||||
playsound(src.loc, sound_effect_open, 15, 1, -3)
|
||||
|
||||
dump_contents()
|
||||
|
||||
update_icon()
|
||||
src.opened = 1
|
||||
update_icon()
|
||||
return 1
|
||||
|
||||
/obj/structure/closet/crate/close()
|
||||
playsound(src.loc, sound_effect_close, 15, 1, -3)
|
||||
|
||||
take_contents()
|
||||
|
||||
update_icon()
|
||||
src.opened = 0
|
||||
update_icon()
|
||||
return 1
|
||||
|
||||
/obj/structure/closet/crate/insert(var/atom/movable/AM, var/include_mobs = 0)
|
||||
|
||||
Reference in New Issue
Block a user