From fe8faa64256b98b0dcc34eb563d215ece5b5d574 Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Sun, 6 Sep 2020 05:58:13 +0200 Subject: [PATCH] [MIRROR] Wild Mutation crops now carry over traits from the parent plant. (#663) * Wild Mutation crops now carry over traits from the parent plant. (#53413) This results in wild mutation carrying over possible traits from parent to child, in a way that will also be displayed by the plant analyzer. This means if you gene splice a parent plant and it wild mutates into a different species, the wild mutation will take the trait genes of the parent, with none of the reagents as reagents are specific to the species in most cases, but can be bred back in via cross-pollination. * Wild Mutation crops now carry over traits from the parent plant. Co-authored-by: ArcaneMusic <41715314+ArcaneMusic@users.noreply.github.com> --- code/modules/hydroponics/seeds.dm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/code/modules/hydroponics/seeds.dm b/code/modules/hydroponics/seeds.dm index 1c06ba94237..06197e47d1e 100644 --- a/code/modules/hydroponics/seeds.dm +++ b/code/modules/hydroponics/seeds.dm @@ -221,11 +221,13 @@ t_prod.seed.name = initial(new_prod.name) t_prod.seed.desc = initial(new_prod.desc) t_prod.seed.plantname = initial(new_prod.plantname) + for(var/datum/plant_gene/trait/trait in parent.myseed.genes) + if(trait.can_add(t_prod.seed)) + t_prod.seed.genes += trait t_prod.transform = initial(t_prod.transform) t_prod.transform *= TRANSFORM_USING_VARIABLE(t_prod.seed.potency, 100) + 0.5 t_amount++ if(t_prod.seed) - //t_prod.seed = new new_prod t_prod.seed.instability = round(instability * 0.5) continue else