diff --git a/code/defines/obj/clothing/glasses.dm b/code/defines/obj/clothing/glasses.dm index a3754496132..d6de1488699 100644 --- a/code/defines/obj/clothing/glasses.dm +++ b/code/defines/obj/clothing/glasses.dm @@ -56,4 +56,34 @@ /obj/item/clothing/glasses/thermal/monocle name = "Thermoncle" - icon_state = "thermoncle" \ No newline at end of file + icon_state = "thermoncle" + flags = null //doesn't protect eyes because it's a monocle, duh + +/obj/item/clothing/glasses/healthscanner + name = "Health Scanner HUD" + desc = "A heads-up display that scans the humans in view and provides accurate data about their health status." + icon_state = "healthscanner" + flags = null //doesn't protect eyes because it's a monocle, duh + var/list/icon/current = list() //the current hud icons + +/proc/RoundHealth(health) + switch(health) + if(100 to INFINITY) + return "health100" + if(70 to 100) + return "health80" + if(50 to 70) + return "health60" + if(30 to 50) + return "health40" + if(20 to 30) + return "health25" + if(5 to 15) + return "health10" + if(1 to 5) + return "health1" + if(-99 to 0) + return "health0" + else + return "health-100" + return "0" \ No newline at end of file diff --git a/code/game/machinery/hydroponics.dm b/code/game/machinery/hydroponics.dm index 782c1cbb70c..0bbee28560a 100644 --- a/code/game/machinery/hydroponics.dm +++ b/code/game/machinery/hydroponics.dm @@ -257,7 +257,7 @@ obj/machinery/hydroponics/proc/hardmutate() // Strongly mutates the current seed src.myseed.lifespan += rand(-4,4) if(src.myseed.lifespan < 10) src.myseed.lifespan = 10 - else if(src.myseed.lifespan > 30) + else if(src.myseed.lifespan > 30 && !istype(myseed,/obj/item/seeds/glowshroom)) //hack to prevent glowshrooms from always resetting to 30 sec delay src.myseed.lifespan = 30 src.myseed.endurance += rand(-10,10) diff --git a/code/game/objects/toys.dm b/code/game/objects/toys.dm index 89e1ae9d0ab..5eb3ae743c7 100644 --- a/code/game/objects/toys.dm +++ b/code/game/objects/toys.dm @@ -157,6 +157,7 @@ CRAYONS desc = "A rune drawn in crayon." icon = 'rune.dmi' layer = 2.1 + anchored = 1 /obj/decal/cleanable/crayon/New(location,main = "#FFFFFF",shade = "#000000") ..() diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm index dc16ec8f94b..a6e4371da4a 100644 --- a/code/modules/mob/living/carbon/human/life.dm +++ b/code/modules/mob/living/carbon/human/life.dm @@ -744,6 +744,11 @@ handle_regular_hud_updates() + if(client) + for(var/image/hud in client.images) + if(hud.icon_state in list("healthdead","healthill","healthy","health-100","health0","health1","health10","health25","health40","health60","health80","health100")) //ugly, but icon comparison is worse, I believe + del(hud) + if (src.stat == 2 || src.mutations & 4) src.sight |= SEE_TURFS src.sight |= SEE_MOBS @@ -790,6 +795,19 @@ src.sight |= SEE_OBJS if (!src.druggy) src.see_invisible = 0 + else if (istype(glasses, /obj/item/clothing/glasses/healthscanner)) + if(client) + var/icon/tempHud = 'hud.dmi' + for(var/mob/living/carbon/human/patient in view(src)) + client.images += image(tempHud,patient,RoundHealth(patient.health)) + if(patient.stat == 2) + client.images += image(tempHud,patient,"healthdead") + else if(patient.virus) + client.images += image(tempHud,patient,"healthill") + else + client.images += image(tempHud,patient,"healthy") + if (!src.druggy) + src.see_invisible = 0 else if (src.stat != 2) src.sight &= ~SEE_TURFS diff --git a/icons/mob/eyes.dmi b/icons/mob/eyes.dmi index b22f2281f73..f2295549db1 100644 Binary files a/icons/mob/eyes.dmi and b/icons/mob/eyes.dmi differ diff --git a/icons/mob/hud.dmi b/icons/mob/hud.dmi new file mode 100644 index 00000000000..372afa10bba Binary files /dev/null and b/icons/mob/hud.dmi differ diff --git a/icons/obj/clothing/glasses.dmi b/icons/obj/clothing/glasses.dmi index 6b4461fd19a..3af65d9c262 100644 Binary files a/icons/obj/clothing/glasses.dmi and b/icons/obj/clothing/glasses.dmi differ diff --git a/icons/obj/items.dmi b/icons/obj/items.dmi index 57519159455..91acd82aa8f 100644 Binary files a/icons/obj/items.dmi and b/icons/obj/items.dmi differ diff --git a/maps/tgstation.2.0.7.dmm b/maps/tgstation.2.0.7.dmm index e754f0feeea..30d6a7e78dc 100644 --- a/maps/tgstation.2.0.7.dmm +++ b/maps/tgstation.2.0.7.dmm @@ -3471,7 +3471,7 @@ "boM" = (/obj/machinery/atmospherics/unary/vent_pump{dir = 1; on = 1},/obj/item/device/radio/intercom{pixel_y = 25},/obj/machinery/light{dir = 1},/turf/simulated/floor{icon_state = "white"},/area/medical/surgery) "boN" = (/obj/machinery/computer/operating,/obj/cable{icon_state = "0-2"; d2 = 2},/turf/simulated/floor{icon_state = "white"},/area/medical/surgery) "boO" = (/obj/machinery/door_control{id = "Obshutter"; name = "Observation Door Control"; pixel_y = 25},/obj/machinery/light{dir = 1},/turf/simulated/floor{icon_state = "white"},/area/medical/surgery) -"boP" = (/obj/table{icon_state = "tabledir"; dir = 8},/obj/item/weapon/scalpel,/turf/simulated/floor{icon_state = "white"},/area/medical/surgery) +"boP" = (/obj/table{icon_state = "tabledir"; dir = 8},/obj/item/weapon/scalpel,/obj/item/clothing/glasses/healthscanner,/obj/item/clothing/glasses/healthscanner,/obj/item/clothing/glasses/healthscanner,/obj/item/clothing/glasses/healthscanner,/obj/item/clothing/glasses/healthscanner,/turf/simulated/floor{icon_state = "white"},/area/medical/surgery) "boQ" = (/obj/grille,/obj/machinery/door/poddoor{density = 0; icon_state = "pdoor0"; id = "Obshutter"; name = "Observation Shutters"; opacity = 0},/obj/window/reinforced{dir = 8},/obj/window/reinforced{dir = 4},/turf/simulated/floor/plating,/area/medical/surgery) "boR" = (/obj/stool/chair{dir = 8},/obj/item/device/radio/intercom{pixel_y = 25},/obj/machinery/camera{c_tag = "Surgery Observation"},/turf/simulated/floor{icon_state = "dark"},/area/medical/surgery) "boS" = (/turf/simulated/floor{icon_state = "dark"},/area/medical/surgery) @@ -4084,7 +4084,7 @@ "bAB" = (/obj/machinery/atmospherics/unary/vent_scrubber{on = 1; scrub_N2O = 0; scrub_Toxins = 0},/obj/secure_closet/personal/patient,/turf/simulated/floor{dir = 1; icon_state = "warning"},/area/medical/genetics) "bAC" = (/obj/machinery/light{dir = 8},/obj/disposalpipe/segment{dir = 1},/turf/simulated/floor{icon_state = "white"},/area/medical/medbay) "bAD" = (/obj/grille,/obj/window/reinforced{dir = 4},/obj/window/reinforced{dir = 1},/obj/window/reinforced{dir = 8},/obj/window/reinforced,/turf/simulated/floor/plating,/area/medical/cmo) -"bAE" = (/obj/table{dir = 5; icon_state = "tabledir"},/obj/item/weapon/reagent_containers/hypospray,/turf/simulated/floor{icon_state = "white"},/area/medical/cmo) +"bAE" = (/obj/table{dir = 5; icon_state = "tabledir"},/obj/item/weapon/reagent_containers/hypospray,/obj/item/clothing/glasses/healthscanner,/turf/simulated/floor{icon_state = "white"},/area/medical/cmo) "bAF" = (/obj/machinery/firealarm{dir = 1; pixel_y = -24},/obj/landmark{name = "xeno_spawn"; pixel_x = -1},/obj/machinery/atmospherics/unary/vent_pump{on = 1},/turf/simulated/floor{icon_state = "white"},/area/medical/cmo) "bAG" = (/obj/machinery/atmospherics/pipe/simple{color = "red"; icon_state = "intact-r-f"; level = 1; name = "pipe"},/obj/machinery/requests_console{department = "Chief Medical Officer's Office"; departmentType = 5; name = "CMO RC"; pixel_y = -30},/obj/cable{d1 = 1; d2 = 4; icon_state = "1-4"; tag = "90Curve"},/turf/simulated/floor{icon_state = "white"},/area/medical/cmo) "bAH" = (/obj/machinery/light,/obj/machinery/atmospherics/unary/vent_scrubber{on = 1; scrub_N2O = 0; scrub_Toxins = 0},/obj/cable{d1 = 4; d2 = 8; icon_state = "4-8"; tag = "Streight"},/turf/simulated/floor{icon_state = "white"},/area/medical/cmo)