diff --git a/code/game/data_huds.dm b/code/game/data_huds.dm index 9cc7a6531ce..876a8259273 100644 --- a/code/game/data_huds.dm +++ b/code/game/data_huds.dm @@ -323,26 +323,26 @@ ~~~~~~~~~~~~~~~*/ /proc/RoundPlantBar(value) switch(value * 100) - if(91 to INFINITY) - return "max" - if(81 to 90) - return "90" - if(71 to 80) - return "80" - if(61 to 70) - return "70" - if(51 to 60) - return "60" - if(41 to 50) - return "50" - if(31 to 40) - return "40" - if(21 to 30) - return "30" - if(11 to 20) - return "20" if(1 to 10) return "10" + if(10 to 20) + return "20" + if(20 to 30) + return "30" + if(30 to 40) + return "40" + if(40 to 50) + return "50" + if(50 to 60) + return "60" + if(60 to 70) + return "70" + if(70 to 80) + return "80" + if(80 to 90) + return "90" + if(90 to INFINITY) + return "max" else return "zero" return "zero" @@ -357,16 +357,10 @@ /obj/machinery/portable_atmospherics/hydroponics/proc/plant_hud_set_status() var/image/holder = hud_list[PLANT_STATUS_HUD] - // Dis be drugs here. And special mention plants - var/list/special = list(/datum/seed/nettle, /datum/seed/apple/poison, /datum/seed/ambrosia, /datum/seed/tobacco, /datum/seed/mushroom, \ - /datum/seed/weeds, /datum/seed/grass, /datum/seed/kudzu, /datum/seed/diona, /datum/seed/clown) if (!seed) holder.icon_state = "" return if (harvest) - if (is_type_in_list(seed, special)) - holder.icon_state = "hudharvest2" - return holder.icon_state = "hudharvest" return if (dead) diff --git a/code/modules/hydroponics/trays/tray.dm b/code/modules/hydroponics/trays/tray.dm index 42d22d82b2c..00e6a853069 100644 --- a/code/modules/hydroponics/trays/tray.dm +++ b/code/modules/hydroponics/trays/tray.dm @@ -87,6 +87,17 @@ /obj/machinery/portable_atmospherics/hydroponics/New() ..() + var/datum/atom_hud/data/hydroponic/hydro_hud = huds[DATA_HUD_HYDROPONIC] + prepare_huds() + hydro_hud.add_to_hud(src) + plant_hud_set_nutrient() + plant_hud_set_water() + plant_hud_set_status() + plant_hud_set_health() + plant_hud_set_toxin() + plant_hud_set_pest() + plant_hud_set_weed() + component_parts = list() component_parts += new /obj/item/weapon/circuitboard/hydroponics(null) component_parts += new /obj/item/weapon/stock_parts/matter_bin(null) @@ -103,16 +114,6 @@ if(closed_system) flags &= ~OPENCONTAINER - var/datum/atom_hud/data/hydroponic/hydro_hud = huds[DATA_HUD_HYDROPONIC] - prepare_huds() - hydro_hud.add_to_hud(src) - plant_hud_set_nutrient() - plant_hud_set_water() - plant_hud_set_status() - plant_hud_set_health() - plant_hud_set_toxin() - plant_hud_set_pest() - plant_hud_set_weed() /obj/machinery/portable_atmospherics/hydroponics/upgraded/New() ..() @@ -175,6 +176,8 @@ pestlevel = 0 plant_hud_set_status() plant_hud_set_health() + plant_hud_set_weed() + plant_hud_set_pest() //Harvests the product of a plant. /obj/machinery/portable_atmospherics/hydroponics/proc/harvest(var/mob/user) @@ -618,6 +621,7 @@ user.visible_message("[user] starts uprooting the weeds.", "You remove the weeds from the [src].") weedlevel = 0 update_icon() + plant_hud_set_weed() else to_chat(user, "This plot is completely devoid of weeds. It doesn't need uprooting.")