Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hydroponics Overhaul (not even close to done) #1181

Draft
wants to merge 84 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
84 commits
Select commit Hold shift + click to select a range
8784651
minor cleanup
Kapu1178 Dec 10, 2024
d1c0193
progress
Kapu1178 Dec 11, 2024
d35274d
progress
Kapu1178 Dec 13, 2024
4286a3d
progress
Kapu1178 Dec 19, 2024
61ef3a7
cherries and chilli
Kapu1178 Dec 21, 2024
21434e8
citrus
Kapu1178 Dec 21, 2024
423d328
corn
Kapu1178 Dec 30, 2024
a409346
abstract plant datum handling
francinum Jan 1, 2025
d795e09
Flowers
francinum Jan 1, 2025
d626bff
another batch
Kapu1178 Jan 5, 2025
9e7d543
MORE
Kapu1178 Jan 5, 2025
7c28c79
whoops
Kapu1178 Jan 5, 2025
e03d066
cleanup
Kapu1178 Jan 6, 2025
f824388
untick
Kapu1178 Jan 6, 2025
91c57b4
finish more
Kapu1178 Jan 7, 2025
4a278b8
gorwn item code
Kapu1178 Jan 7, 2025
e8aabd2
cabbage/replicapod
francinum Jan 8, 2025
0e2fc4a
fixes and hedges
francinum Jan 8, 2025
c044a44
plant gene pt1
Kapu1178 Jan 9, 2025
344aca2
trait -> product_trait
Kapu1178 Jan 9, 2025
ae8a7bf
plant gene pt2
Kapu1178 Jan 9, 2025
525da97
proggers
Kapu1178 Jan 9, 2025
b54897d
proggers 2
Kapu1178 Jan 9, 2025
1f59535
Merge branch 'master' of github.com:DaedalusDock/daedalusdock into hydro
Kapu1178 Jan 9, 2025
512a1c1
random shit
Kapu1178 Jan 10, 2025
521192b
grass
Kapu1178 Jan 10, 2025
e7dc25f
work
Kapu1178 Jan 12, 2025
17b3f2e
grind/juice refactor sidequest
Kapu1178 Jan 13, 2025
61c2dab
whoops
Kapu1178 Jan 13, 2025
c5f5c57
almost
Kapu1178 Jan 13, 2025
14bfe6d
Lily and Spacemans Trumpet
francinum Jan 13, 2025
043ef11
potency scalar
Kapu1178 Jan 13, 2025
8735720
Merge branch 'hydro' of github.com:Kapu1178/daedalusdock into hydro
Kapu1178 Jan 13, 2025
4421f09
horrrryyy fuck it compiles
Kapu1178 Jan 13, 2025
41ad6a0
updatepaths
Kapu1178 Jan 13, 2025
c498c00
unused var
Kapu1178 Jan 13, 2025
0eafdad
fixes
Kapu1178 Jan 13, 2025
752b5f3
more fixes
Kapu1178 Jan 13, 2025
9e21417
rename vars
Kapu1178 Jan 13, 2025
6891fb4
var renames
Kapu1178 Jan 13, 2025
d5f843d
i dont even know what to title this
Kapu1178 Jan 13, 2025
b561d68
unit test fixes
Kapu1178 Jan 13, 2025
0dd20fc
small tweaks
Kapu1178 Jan 13, 2025
23177e4
fixes / temp stuff
Kapu1178 Jan 14, 2025
e71f370
Merge branch 'master' of github.com:DaedalusDock/daedalusdock into hydro
Kapu1178 Jan 14, 2025
b73decf
fixes
Kapu1178 Jan 14, 2025
2a92f99
harddel fix
Kapu1178 Jan 14, 2025
2498e5c
plant icon fixes
Kapu1178 Jan 14, 2025
6880341
fuck
Kapu1178 Jan 14, 2025
c162bdd
fixes
Kapu1178 Jan 14, 2025
4507316
fix
Kapu1178 Jan 14, 2025
f34dee9
fix
Kapu1178 Jan 14, 2025
46e59ed
qdel gene holder
Kapu1178 Jan 14, 2025
2980fae
fuck you
Kapu1178 Jan 14, 2025
f47c2cc
fix mutations
Kapu1178 Jan 14, 2025
9ddae28
ambrosia/vulgaris -> ambrosia
Kapu1178 Jan 14, 2025
5f7593c
restore novaflower properties
Kapu1178 Jan 14, 2025
f4d1206
maybe fix this runtime
Kapu1178 Jan 14, 2025
29c2390
reagent genes are unsplicable
Kapu1178 Jan 15, 2025
ac6f197
i change my mind
Kapu1178 Jan 15, 2025
6d1b366
fix seed extractor, jsx -> tsx
Kapu1178 Jan 15, 2025
81fac32
fix not passing plant_datum
Kapu1178 Jan 15, 2025
78b3d9b
fix test
Kapu1178 Jan 15, 2025
47960d7
FRICK
Kapu1178 Jan 15, 2025
789e5fb
FRICK. AGAIN.
Kapu1178 Jan 15, 2025
c4267c9
AM I DUMB?
Kapu1178 Jan 15, 2025
2ac25cf
fix + improve test accuracy
Kapu1178 Jan 15, 2025
1bf8a7f
i need t osleep
Kapu1178 Jan 15, 2025
4534e0a
fix these
Kapu1178 Jan 15, 2025
2e32ddb
fix all icons hopefuly
Kapu1178 Jan 15, 2025
f2e6353
unit test name fix
Kapu1178 Jan 15, 2025
d992881
tweak seed extractor ui
Kapu1178 Jan 15, 2025
4427842
flex conv
Kapu1178 Jan 15, 2025
2de0800
good enough for now
Kapu1178 Jan 15, 2025
62f1f37
unused gene flags
Kapu1178 Jan 16, 2025
220631e
add some goon genes
Kapu1178 Jan 16, 2025
62f8163
tincture base
Kapu1178 Jan 16, 2025
a505261
bananrries
Kapu1178 Jan 17, 2025
4989501
probably need this
Kapu1178 Jan 17, 2025
5d56a66
analyzer
Kapu1178 Jan 17, 2025
c77b3d3
should be unit tested but i need a break
Kapu1178 Jan 17, 2025
65fdb62
fix seeds
Kapu1178 Jan 17, 2025
5c73382
parsnip fix
Kapu1178 Jan 17, 2025
c87f7da
infusion UI
Kapu1178 Jan 17, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 1 addition & 7 deletions _maps/RandomRuins/SpaceRuins/hilbertresearchfacility.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -1113,7 +1113,6 @@
/area/ruin/space/has_grav/powered/hilbertresearchfacility)
"zq" = (
/obj/structure/table/reinforced/rglass,
/obj/item/food/grown/tomato/blue/bluespace,
/turf/open/floor/glass,
/area/ruin/space/has_grav/powered/hilbertresearchfacility)
"zu" = (
Expand Down Expand Up @@ -2105,11 +2104,6 @@
/obj/item/grown/bananapeel/bluespace,
/turf/open/floor/glass,
/area/ruin/space/has_grav/powered/hilbertresearchfacility)
"Uc" = (
/obj/structure/table/reinforced/rglass,
/obj/item/food/grown/banana/bluespace,
/turf/open/floor/glass,
/area/ruin/space/has_grav/powered/hilbertresearchfacility)
"Ui" = (
/obj/effect/decal/cleanable/dirt/dust,
/turf/open/floor/iron/grimy,
Expand Down Expand Up @@ -2673,7 +2667,7 @@ Rj
CO
Rj
Zc
Uc
yi
Bo
ch
Ut
Expand Down
2 changes: 0 additions & 2 deletions _maps/RandomRuins/SpaceRuins/spacehotel.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -1093,8 +1093,6 @@
/obj/item/food/grown/tomato,
/obj/item/food/grown/rice,
/obj/item/food/grown/rice,
/obj/item/food/grown/icepepper,
/obj/item/food/grown/icepepper,
/obj/item/food/grown/citrus/lemon,
/obj/item/food/grown/citrus/lime,
/obj/item/food/grown/citrus/orange,
Expand Down
25 changes: 21 additions & 4 deletions _maps/map_files/debug/runtimestation.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,11 @@
"aw" = (
/turf/open/floor/plating,
/area/station/engineering/atmos)
"ax" = (
/obj/effect/landmark/start,
/obj/machinery/light/floor/has_bulb,
/turf/open/floor/iron,
/area/station/commons/storage/primary)
"aA" = (
/turf/open/floor/iron,
/area/station/engineering/main)
Expand Down Expand Up @@ -1961,6 +1966,10 @@
/obj/structure/cable/smart_cable/color/yellow,
/turf/open/floor/iron,
/area/station/hallway/primary/central)
"zX" = (
/obj/machinery/hydroponics/constructable,
/turf/open/floor/iron,
/area/station/commons/storage/primary)
"Ao" = (
/obj/effect/turf_decal/plaque{
icon_state = "L9"
Expand Down Expand Up @@ -2367,6 +2376,10 @@
/obj/machinery/chem_recipe_debug,
/turf/open/floor/iron,
/area/station/medical/chemistry)
"Nd" = (
/obj/machinery/vending/hydroseeds,
/turf/open/floor/iron,
/area/station/commons/storage/primary)
"NN" = (
/obj/structure/fans/tiny,
/obj/structure/cable/smart_cable/color/yellow,
Expand Down Expand Up @@ -2575,6 +2588,10 @@
},
/turf/open/floor/iron,
/area/station/hallway/secondary/entry)
"TR" = (
/obj/machinery/vending/hydronutrients,
/turf/open/floor/iron,
/area/station/commons/storage/primary)
"UI" = (
/obj/machinery/door/airlock,
/obj/structure/cable/smart_cable/color/yellow,
Expand Down Expand Up @@ -7581,7 +7598,7 @@ cS
hf
dr
dJ
dJ
TR
dJ
dI
dJ
Expand Down Expand Up @@ -7673,7 +7690,7 @@ Tg
xN
ds
dJ
dJ
Nd
dJ
dI
dJ
Expand Down Expand Up @@ -7766,8 +7783,8 @@ jm
dt
dJ
dD
dJ
dI
zX
ax
dJ
XZ
dJ
Expand Down
4 changes: 1 addition & 3 deletions _maps/map_files/generic/CentCom.dmm
Original file line number Diff line number Diff line change
Expand Up @@ -5152,8 +5152,6 @@
/obj/item/food/grown/tomato,
/obj/item/food/grown/rice,
/obj/item/food/grown/rice,
/obj/item/food/grown/icepepper,
/obj/item/food/grown/icepepper,
/obj/item/food/grown/citrus/lemon,
/obj/item/food/grown/citrus/lime,
/obj/item/food/grown/citrus/orange,
Expand Down Expand Up @@ -17730,7 +17728,7 @@
/obj/item/food/grown/chili,
/obj/item/food/grown/carrot,
/obj/item/food/grown/apple,
/obj/item/food/grown/ambrosia/vulgaris,
/obj/item/food/grown/ambrosia,
/obj/effect/turf_decal/tile/neutral/fourcorners,
/obj/machinery/status_display/evac/directional/north,
/turf/open/floor/iron/dark,
Expand Down
File renamed without changes.
8 changes: 3 additions & 5 deletions code/__DEFINES/botany.dm
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,10 @@
#define FLORA_GUN_MIN_ENDURANCE 20

/// -- Flags for genes --
/// Plant genes that can be removed via gene shears.
#define PLANT_GENE_REMOVABLE (1<<0)
/// Plant genes that can be mutated randomly in strange seeds / due to high instability.
/// Gene is not passed on via splicing.
#define PLANT_GENE_UNSPLICABLE (1<<0)
/// Gene can be obtained via random seed.
#define PLANT_GENE_MUTATABLE (1<<1)
/// Plant genes that can be graftable. Used in formatting text, as they need to be set to be graftable anyways.
#define PLANT_GENE_GRAFTABLE (1<<2)

/// -- Flags for seeds. --
/// Allows a plant to wild mutate (mutate on haravest) at a certain instability.
Expand Down
24 changes: 2 additions & 22 deletions code/__DEFINES/dcs/signals/signals_hydroponic.dm
Original file line number Diff line number Diff line change
Expand Up @@ -11,25 +11,5 @@
///called when a seed is planted in a tray (obj/machinery/hydroponics)
#define COMSIG_SEED_ON_PLANTED "plant_on_plant"

//Hydro tray
///from base of /obj/machinery/hydroponics/set_seed() : (obj/item/new_seed)
#define COMSIG_HYDROTRAY_SET_SEED "hydrotray_set_seed"
///from base of /obj/machinery/hydroponics/set_self_sustaining() : (new_value)
#define COMSIG_HYDROTRAY_SET_SELFSUSTAINING "hydrotray_set_selfsustaining"
///from base of /obj/machinery/hydroponics/set_weedlevel() : (new_value)
#define COMSIG_HYDROTRAY_SET_WEEDLEVEL "hydrotray_set_weedlevel"
///from base of /obj/machinery/hydroponics/set_pestlevel() : (new_value)
#define COMSIG_HYDROTRAY_SET_PESTLEVEL "hydrotray_set_pestlevel"
///from base of /obj/machinery/hydroponics/set_waterlevel() : (new_value)
#define COMSIG_HYDROTRAY_SET_WATERLEVEL "hydrotray_set_waterlevel"
///from base of /obj/machinery/hydroponics/set_plant_health() : (new_value)
#define COMSIG_HYDROTRAY_SET_PLANT_HEALTH "hydrotray_set_plant_health"
///from base of /obj/machinery/hydroponics/set_toxic() : (new_value)
#define COMSIG_HYDROTRAY_SET_TOXIC "hydrotray_set_toxic"
///from base of /obj/machinery/hydroponics/set_plant_status() : (new_value)
#define COMSIG_HYDROTRAY_SET_PLANT_STATUS "hydrotray_set_plant_status"
///from base of /obj/machinery/hydroponics/update_tray() : (mob/user, product_count)
#define COMSIG_HYDROTRAY_ON_HARVEST "hydrotray_on_harvest"
///from base of /obj/machinery/hydroponics/plantdies()
#define COMSIG_HYDROTRAY_PLANT_DEATH "hydrotray_plant_death"
///from base of obj/item/attack(): (/mob/living/target, /mob/living/user)
/// Called by plant gene holders when getting a stat's value. (stat, base_val)
#define COMSIG_PLANT_GENE_HOLDER_GET_STAT "pgh_get_stat"
8 changes: 4 additions & 4 deletions code/__DEFINES/dcs/signals/signals_object.dm
Original file line number Diff line number Diff line change
Expand Up @@ -107,10 +107,10 @@
#define COMPONENT_ITEM_BLOCK_UNEQUIP (1<<0)
///called on [/obj/item] AFTER unequip from base of [mob/proc/tryUnequipItem]: (force, atom/newloc, no_move, invdrop, silent)
#define COMSIG_ITEM_POST_UNEQUIP "item_post_unequip"
///from base of obj/item/on_grind(): ())
#define COMSIG_ITEM_ON_GRIND "on_grind"
///from base of obj/item/on_juice(): ()
#define COMSIG_ITEM_ON_JUICE "on_juice"
///from base of obj/item/grind(): ())
#define COMSIG_ITEM_PRE_GRIND "pre_grind"
///from base of obj/item/juice(): ()
#define COMSIG_ITEM_PRE_JUICE "pre_juice"
///from /obj/machinery/hydroponics/attackby(obj/item/O, mob/user, params) when an object is used as compost: (mob/user)
#define COMSIG_ITEM_ON_COMPOSTED "on_composted"
///Called when an item is dried by a drying rack:
Expand Down
40 changes: 40 additions & 0 deletions code/__DEFINES/hydroponics.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
// Plant states
#define PLANT_DEAD "dead"
#define PLANT_PLANTED "planted"
#define PLANT_GROWING "growing"
#define PLANT_MATURE "mature"
#define PLANT_HARVESTABLE "harvestable"

// Plant stats
#define PLANT_STAT_MATURATION "maturation"
#define PLANT_STAT_PRODUCTION "production"
#define PLANT_STAT_YIELD "yield"
#define PLANT_STAT_HARVEST_AMT "harvest_amt"
#define PLANT_STAT_ENDURANCE "endurance"
#define PLANT_STAT_POTENCY "potency"

#define PLANT_STAT_PROB_ROUND(num) (trunc(num) + prob(fract(num) * 100) * SIGN(num))
#warn undo this

Check warning on line 17 in code/__DEFINES/hydroponics.dm

View workflow job for this annotation

GitHub Actions / Run Linters

#warn undo this
/proc/psbr(num)
return PLANT_STAT_PROB_ROUND(num)

/// The functional maximum value from SCALE_PLANT_POTENCY
#define POTENCY_SCALE_FUNCTIONAL_MAXIMUM 200
/// The value returned by SCALE_PLANT_POTENCY when given 100 potency
#define POTENCY_SCALE_AT_100 100

#define POTENCY_SCALE_FACTOR (((100 * POTENCY_SCALE_FUNCTIONAL_MAXIMUM) / POTENCY_SCALE_AT_100) - 100)
/// Scales a potency value according to the above values.
#define SCALE_PLANT_POTENCY(given_potency) round((POTENCY_SCALE_FUNCTIONAL_MAXIMUM / (given_potency + POTENCY_SCALE_FACTOR)) * given_potency)

/// Water level above this is considered drowning the plant.
#define HYDRO_WATER_DROWNING_LIMIT 50

/// Growth per process tick (1 second) base
#define HYDRO_BASE_GROWTH_RATE 1
/// Damage per process tick (1 second) if the plant has no water.
#define HYDRO_NO_WATER_DAMAGE 1

// Plant damage types
/// Lack of water during process tick
#define PLANT_DAMAGE_NO_WATER "no_water"
8 changes: 8 additions & 0 deletions code/__DEFINES/reagents.dm
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,14 @@
////Used to force an equlibrium to end a reaction in reaction_step() (i.e. in a reaction_step() proc return END_REACTION to end it)
#define END_REACTION "end_reaction"

//flags used by holder.dm to locate an reagent
///Direct type
#define REAGENT_STRICT_TYPE 1
///Parent type but not sub types for e.g. if param is obj/item it will look for obj/item/stack but not obj/item/stack/sheet
#define REAGENT_PARENT_TYPE 2
///same as istype() check
#define REAGENT_SUB_TYPE 3

/// Helper for converting realtime seconds into reagent cycles.
#define SECONDS_TO_REAGENT_CYCLES(seconds) round(seconds / (/datum/controller/subsystem/mobs::wait / 10))

Expand Down
5 changes: 5 additions & 0 deletions code/__DEFINES/traits_hydroponics.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
/// get_effective_stat returns half for Yield.
#define TRAIT_HALF_YIELD "half_yield"

/// Sourced from a plant gene.
#define PLANT_GENE_SOURCE "plant_gene"
1 change: 0 additions & 1 deletion code/__HELPERS/randoms.dm
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
/obj/item/food/clothing,
/obj/item/food/meat/slab/human/mutant,
/obj/item/food/grown/nettle,
/obj/item/food/grown/shell
)

return pick(subtypesof(/obj/item/food) - blocked)
Expand Down
2 changes: 1 addition & 1 deletion code/_compile_options.dm
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@
/////////////////////// MISC PERFORMANCE

//uncomment this to load centcom and runtime station and thats it.
// #define LOWMEMORYMODE
#define LOWMEMORYMODE

//uncomment to enable the spatial grid debug proc.
// #define SPATIAL_GRID_ZLEVEL_STATS
Expand Down Expand Up @@ -269,7 +269,7 @@
#endif

#ifdef LOWMEMORYMODE
#warn LOWMEMORYMODE is enabled!

Check warning on line 272 in code/_compile_options.dm

View workflow job for this annotation

GitHub Actions / Run Linters

#warn LOWMEMORYMODE is enabled!
#endif

#ifdef DEBUG_AI
Expand Down
44 changes: 44 additions & 0 deletions code/controllers/subsystem/processing/hydroponics.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
PROCESSING_SUBSYSTEM_DEF(hydroponics)
name = "Hydroponics"
flags = SS_HIBERNATE


var/list/gene_list = list()

var/list/mutation_list = list()

var/list/non_abstract_plant_types = list()

/datum/controller/subsystem/processing/hydroponics/Initialize(start_timeofday)
. = ..()
for(var/datum/plant_gene/path as anything in subtypesof(/datum/plant_gene))
if(isabstract(path))
continue

gene_list[path] = new path

for(var/datum/plant_mutation/path as anything in subtypesof(/datum/plant_mutation))
if(isabstract(path))
continue

mutation_list[path] = new path

for(var/datum/plant/path as anything in subtypesof(/datum/plant))
if(isabstract(path))
continue
non_abstract_plant_types += path

/datum/controller/subsystem/processing/hydroponics/proc/splice_alleles(allele_one, allele_two, value_one, value_two)
if(allele_one == allele_two)
// Both were dominant or recessive, average them
return round((allele_one + allele_two) / 2)

var/dominance = allele_one - allele_two

// Allele 1 was dominant. (1 - 0 == 1)
if(dominance > 0)
return value_one

// Allele 1 was recessive. (0 - 1 == -1)
else
return value_two
4 changes: 2 additions & 2 deletions code/datums/elements/food/food_trash.dm
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@
RegisterSignal(target, COMSIG_ITEM_ATTACK_SELF, PROC_REF(open_trash))
if(flags & FOOD_TRASH_POPABLE)
RegisterSignal(target, COMSIG_FOOD_CROSSED, PROC_REF(food_crossed))
RegisterSignal(target, COMSIG_ITEM_ON_GRIND, PROC_REF(generate_trash))
RegisterSignal(target, COMSIG_ITEM_ON_JUICE, PROC_REF(generate_trash))
RegisterSignal(target, COMSIG_ITEM_PRE_GRIND, PROC_REF(generate_trash))
RegisterSignal(target, COMSIG_ITEM_PRE_JUICE, PROC_REF(generate_trash))
RegisterSignal(target, COMSIG_ITEM_ON_COMPOSTED, PROC_REF(generate_trash))
RegisterSignal(target, COMSIG_ITEM_SOLD_TO_CUSTOMER, PROC_REF(generate_trash))

Expand Down
8 changes: 4 additions & 4 deletions code/datums/elements/plant_backfire.dm
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@
*
* returns FALSE if none of the checks are successful.
*/
/datum/element/plant_backfire/proc/plant_safety_check(obj/item/plant, mob/living/carbon/user)
/datum/element/plant_backfire/proc/plant_safety_check(obj/item/product, mob/living/carbon/user)
if(!istype(user))
return TRUE

Expand All @@ -112,10 +112,10 @@
if(HAS_TRAIT(user, checked_trait))
return TRUE

var/obj/item/seeds/our_seed = plant.get_plant_seed()
if(our_seed)
var/datum/plant/our_plant = product.get_plant_datum()
if(our_plant)
for(var/checked_gene in extra_genes)
if(!our_seed.get_gene(checked_gene))
if(!our_plant.gene_holder.has_active_gene_of_type(checked_gene))
return TRUE

for(var/obj/item/clothing/worn_item in user.get_equipped_items())
Expand Down
1 change: 0 additions & 1 deletion code/game/machinery/autolathe.dm
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,6 @@
/datum/design/plant_analyzer,
/datum/design/shovel,
/datum/design/spade,
/datum/design/secateurs,
/datum/design/blood_filter,
/datum/design/scalpel,
/datum/design/circular_saw,
Expand Down
6 changes: 4 additions & 2 deletions code/game/machinery/recycler.dm
Original file line number Diff line number Diff line change
Expand Up @@ -172,16 +172,18 @@
var/obj/item/grown/log/L = I
if(istype(L))
var/seed_modifier = 0
if(L.seed)
seed_modifier = round(L.seed.potency / 25)
if(L.plant_datum)
seed_modifier = round(L.cached_potency / 25)
new L.plank_type(loc, 1 + seed_modifier)

else
var/datum/component/material_container/materials = GetComponent(/datum/component/material_container)
var/material_amount = materials.get_item_material_amount(I, BREAKDOWN_FLAGS_RECYCLER)
if(!material_amount)
return
materials.insert_item(I, material_amount, multiplier = (amount_produced / 100), breakdown_flags=BREAKDOWN_FLAGS_RECYCLER)
materials.retrieve_all()

qdel(I)


Expand Down
Loading
Loading