diff --git a/code/modules/food_and_drinks/kitchen_machinery/deep_fryer.dm b/code/modules/food_and_drinks/kitchen_machinery/deep_fryer.dm
index d9b98c82724..7aa24bdf264 100644
--- a/code/modules/food_and_drinks/kitchen_machinery/deep_fryer.dm
+++ b/code/modules/food_and_drinks/kitchen_machinery/deep_fryer.dm
@@ -76,7 +76,7 @@
output = /obj/item/weapon/reagent_containers/food/snacks/fried_shrimp
/datum/deepfryer_special/banana
- input = "banana"
+ input = /obj/item/weapon/reagent_containers/food/snacks/grown/banana
output = /obj/item/weapon/reagent_containers/food/snacks/friedbanana
/datum/deepfryer_special/potato_chips
@@ -84,7 +84,7 @@
output = /obj/item/weapon/reagent_containers/food/snacks/chips
/datum/deepfryer_special/corn_chips
- input = "corn"
+ input = /obj/item/weapon/reagent_containers/food/snacks/grown/corn
output = /obj/item/weapon/reagent_containers/food/snacks/cornchips
/datum/deepfryer_special/fried_tofu
diff --git a/code/modules/hydroponics/hydroponics.dm b/code/modules/hydroponics/hydroponics.dm
index 5eae76ea446..8cbca85a521 100644
--- a/code/modules/hydroponics/hydroponics.dm
+++ b/code/modules/hydroponics/hydroponics.dm
@@ -1,3 +1,5 @@
+#define HYDRO_CYCLES_PER_AGE 2 //Adjust this to adjust how many hydroponics cycles it takes to increase age. Positive integers only.
+
/obj/machinery/hydroponics
name = "hydroponics tray"
icon = 'icons/obj/hydroponics/equipment.dmi'
@@ -20,10 +22,12 @@
var/lastproduce = 0 //Last time it was harvested
var/lastcycle = 0 //Used for timing of cycles.
var/cycledelay = 200 //About 10 seconds / cycle
+ var/current_cycle = 0 //Used for tracking when to age
var/harvest = 0 //Ready to harvest?
var/obj/item/seeds/myseed = null //The currently planted seed
var/rating = 1
var/wrenchable = 1
+ var/lid_state = 0
var/recent_bee_visit = FALSE //Have we been visited by a bee recently, so bees dont overpollinate one plant
var/using_irrigation = FALSE //If the tray is connected to other trays via irrigation hoses
var/self_sustaining = FALSE //If the tray generates nutrients and water on its own
@@ -108,6 +112,20 @@
return connected
+/obj/machinery/hydroponics/AltClick()
+ if(wrenchable && !usr.stat && !usr.lying && Adjacent(usr))
+ toggle_lid(usr)
+ return
+ return ..()
+
+/obj/machinery/hydroponics/proc/toggle_lid(mob/living/user)
+ if(!user || user.stat || user.restrained())
+ return
+
+ lid_state = !lid_state
+ to_chat(user, "You [lid_state ? "close" : "open"] the tray's lid.")
+ update_icon()
+
/obj/machinery/hydroponics/bullet_act(obj/item/projectile/Proj) //Works with the Somatoray to modify plant variables.
if(!myseed)
@@ -136,7 +154,10 @@
lastcycle = world.time
if(myseed && !dead)
// Advance age
- age++
+ current_cycle++
+ if(current_cycle == HYDRO_CYCLES_PER_AGE)
+ age++
+ current_cycle = 0
if(age < myseed.maturation)
lastproduce = age
@@ -267,6 +288,9 @@
overlays += image('icons/obj/hydroponics/equipment.dmi', icon_state = "gaia_blessing")
set_light(3)
+ if(lid_state)
+ overlays += image('icons/obj/hydroponics/equipment.dmi', icon_state = "hydrocover")
+
update_icon_hoses()
if(myseed)
@@ -904,6 +928,9 @@
/obj/machinery/hydroponics/attack_hand(mob/user)
if(issilicon(user)) //How does AI know what plant is?
return
+ if(lid_state)
+ to_chat(user, "You can't reach the plant through the cover.")
+ return
if(harvest)
myseed.harvest(user)
else if(dead)
@@ -1013,4 +1040,6 @@
to_chat(user, "You clear up [src]!")
qdel(src)
else
- ..()
\ No newline at end of file
+ ..()
+
+#undef HYDRO_CYCLES_PER_AGE
\ No newline at end of file
diff --git a/code/modules/mob/living/simple_animal/hostile/bees.dm b/code/modules/mob/living/simple_animal/hostile/bees.dm
index 538ce8450c7..76577327b61 100644
--- a/code/modules/mob/living/simple_animal/hostile/bees.dm
+++ b/code/modules/mob/living/simple_animal/hostile/bees.dm
@@ -161,8 +161,8 @@
/mob/living/simple_animal/hostile/poison/bees/worker/Found(atom/A)
if(istype(A, /obj/machinery/hydroponics))
var/obj/machinery/hydroponics/Hydro = A
- if(Hydro.myseed && !Hydro.dead && !Hydro.recent_bee_visit)
- wanted_objects |= /obj/machinery/hydroponics //so we only hunt them while they're alive/seeded/not visisted
+ if(Hydro.myseed && !Hydro.dead && !Hydro.recent_bee_visit && !Hydro.lid_state)
+ wanted_objects |= /obj/machinery/hydroponics //so we only hunt them while they're alive/seeded/not visisted and uncovered
return 1
..()
@@ -188,12 +188,12 @@
..()
/mob/living/simple_animal/hostile/poison/bees/worker/proc/pollinate(obj/machinery/hydroponics/Hydro)
- if(!istype(Hydro) || !Hydro.myseed || Hydro.dead || Hydro.recent_bee_visit)
+ if(!istype(Hydro) || !Hydro.myseed || Hydro.dead || Hydro.recent_bee_visit || Hydro.lid_state)
target = null
return
target = null //so we pick a new hydro tray next FindTarget(), instead of loving the same plant for eternity
- wanted_objects -= /obj/machinery/hydroponics //so we only hunt them while they're alive/seeded/not visisted
+ wanted_objects -= /obj/machinery/hydroponics //so we only hunt them while they're alive/seeded/not visisted and uncovered
Hydro.recent_bee_visit = TRUE
spawn(BEE_TRAY_RECENT_VISIT)
if(Hydro)
diff --git a/code/modules/reagents/chemistry/machinery/reagentgrinder.dm b/code/modules/reagents/chemistry/machinery/reagentgrinder.dm
index 278ec7ad82f..0e8fee1926c 100644
--- a/code/modules/reagents/chemistry/machinery/reagentgrinder.dm
+++ b/code/modules/reagents/chemistry/machinery/reagentgrinder.dm
@@ -40,6 +40,7 @@
/obj/item/weapon/reagent_containers/food/snacks/grown/cherries = list("cherryjelly" = 0),
/obj/item/weapon/reagent_containers/food/snacks/grown/bluecherries = list("bluecherryjelly" = 0),
/obj/item/weapon/reagent_containers/food/snacks/egg = list("egg" = -5),
+ /obj/item/weapon/reagent_containers/food/snacks/grown/rice = list("rice" = -5),
//Grinder stuff, but only if dry
/obj/item/weapon/reagent_containers/food/snacks/grown/coffee/robusta = list("coffeepowder" = 0, "morphine" = 0),
diff --git a/icons/obj/hydroponics/equipment.dmi b/icons/obj/hydroponics/equipment.dmi
index 189d1682194..3b1c4c07cfa 100644
Binary files a/icons/obj/hydroponics/equipment.dmi and b/icons/obj/hydroponics/equipment.dmi differ