Made old IPC icons into a mask slot item for prosthetic heads.

This commit is contained in:
Zuhayr
2016-01-05 15:58:38 +10:30
parent beb54f906a
commit 51deb6cd7e
6 changed files with 87 additions and 75 deletions

View File

@@ -345,6 +345,10 @@ var/global/list/gear_datums = list()
display_name = "bandana, red"
path = /obj/item/clothing/mask/bandana/red
/datum/gear/bandanamask/ipc_monitor
display_name = "display monitor (prosthetic head only)"
path = /obj/item/clothing/mask/monitor
/datum/gear/sterilemask
display_name = "sterile mask"
path = /obj/item/clothing/mask/surgical

View File

@@ -0,0 +1,82 @@
//IPC-face object for FPB.
/obj/item/clothing/mask/monitor
name = "display monitor"
desc = "A rather clunky old CRT-style display screen, fit for mounting on an optical output."
flags_inv = HIDEFACE|HIDEEYES
body_parts_covered = FACE
dir = SOUTH
icon = 'icons/mob/monitor_icons.dmi'
icon_override = 'icons/mob/monitor_icons.dmi'
icon_state = "ipc_blank"
item_state = null
var/monitor_state_index = "blank"
var/global/list/monitor_states = list(
"blank" = "ipc_blank",
"pink" = "ipc_pink",
"red" = "ipc_red",
"green" = "ipc_green",
"blue" = "ipc_blue",
"breakout" = "ipc_breakout",
"eight" = "ipc_eight",
"goggles" = "ipc_goggles",
"heart" = "ipc_heart",
"monoeye" = "ipc_monoeye",
"nature" = "ipc_nature",
"orange" = "ipc_orange",
"purple" = "ipc_purple",
"shower" = "ipc_shower",
"static" = "ipc_static",
"yellow" = "ipc_yellow"
)
/obj/item/clothing/mask/monitor/set_dir()
dir = SOUTH
return
/obj/item/clothing/mask/monitor/equipped()
..()
var/mob/living/carbon/human/H = loc
if(istype(H) && H.wear_mask == src)
canremove = 0
H << "<span class='notice'>\The [src] connects to your display output.</span>"
/obj/item/clothing/mask/monitor/dropped()
canremove = 1
return ..()
/obj/item/clothing/mask/monitor/mob_can_equip(var/mob/living/carbon/human/user, var/slot)
if (!..())
return 0
if(istype(user))
var/obj/item/organ/external/E = user.organs_by_name[BP_HEAD]
if(istype(E) && (E.status & ORGAN_ROBOT))
return 1
user << "<span class='warning'>You must have a robotic head to install this upgrade.</span>"
return 0
/obj/item/clothing/mask/monitor/verb/set_monitor_state()
set name = "Set Monitor State"
set desc = "Choose an icon for your monitor."
set category = "IC"
set src in usr
var/mob/living/carbon/human/H = loc
if(!istype(H) || H != usr)
return
if(H.wear_mask != src)
usr << "<span class='warning'>You have not installed \the [src] yet.</span>"
return
var/choice = input("Select a screen icon.") as null|anything in monitor_states
if(choice)
monitor_state_index = choice
update_icon()
/obj/item/clothing/mask/monitor/update_icon()
if(!(monitor_state_index in monitor_states))
monitor_state_index = initial(monitor_state_index)
icon_state = monitor_states[monitor_state_index]
var/mob/living/carbon/human/H = loc
if(istype(H)) H.update_inv_wear_mask()

View File

@@ -435,81 +435,6 @@
name = "Bald"
icon_state = "bald"
icp_screen_pink
name = "pink IPC screen"
icon_state = "ipc_pink"
species_allowed = list("Machine")
icp_screen_red
name = "red IPC screen"
icon_state = "ipc_red"
species_allowed = list("Machine")
icp_screen_green
name = "green IPC screen"
icon_state = "ipc_green"
species_allowed = list("Machine")
icp_screen_blue
name = "blue IPC screen"
icon_state = "ipc_blue"
species_allowed = list("Machine")
icp_screen_breakout
name = "breakout IPC screen"
icon_state = "ipc_breakout"
species_allowed = list("Machine")
icp_screen_eight
name = "eight IPC screen"
icon_state = "ipc_eight"
species_allowed = list("Machine")
icp_screen_goggles
name = "goggles IPC screen"
icon_state = "ipc_goggles"
species_allowed = list("Machine")
icp_screen_heart
name = "heart IPC screen"
icon_state = "ipc_heart"
species_allowed = list("Machine")
icp_screen_monoeye
name = "monoeye IPC screen"
icon_state = "ipc_monoeye"
species_allowed = list("Machine")
icp_screen_nature
name = "nature IPC screen"
icon_state = "ipc_nature"
species_allowed = list("Machine")
icp_screen_orange
name = "orange IPC screen"
icon_state = "ipc_orange"
species_allowed = list("Machine")
icp_screen_purple
name = "purple IPC screen"
icon_state = "ipc_purple"
species_allowed = list("Machine")
icp_screen_shower
name = "shower IPC screen"
icon_state = "ipc_shower"
species_allowed = list("Machine")
icp_screen_static
name = "static IPC screen"
icon_state = "ipc_static"
species_allowed = list("Machine")
icp_screen_yellow
name = "yellow IPC screen"
icon_state = "ipc_yellow"
species_allowed = list("Machine")
/*
///////////////////////////////////
/ =---------------------------= /

Binary file not shown.

Before

Width:  |  Height:  |  Size: 67 KiB

After

Width:  |  Height:  |  Size: 50 KiB

BIN
icons/mob/monitor_icons.dmi Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

View File

@@ -1049,6 +1049,7 @@
#include "code\modules\clothing\masks\breath.dm"
#include "code\modules\clothing\masks\gasmask.dm"
#include "code\modules\clothing\masks\miscellaneous.dm"
#include "code\modules\clothing\masks\monitor.dm"
#include "code\modules\clothing\masks\voice.dm"
#include "code\modules\clothing\shoes\colour.dm"
#include "code\modules\clothing\shoes\jobs.dm"