diff --git a/js/003-data/slaveGeneData.js b/js/003-data/slaveGeneData.js index 6aad0d6634f2eeb83a13111d2ca10b24f6f15ad5..84656be8defc38d8d71dcc8e4f80f3a3b10af828 100644 --- a/js/003-data/slaveGeneData.js +++ b/js/003-data/slaveGeneData.js @@ -27,7 +27,8 @@ App.Data.genes = new Map([ title: "neoteny", abbreviation: "ntny", description: "retention of childlike characteristics", - get requirements() { return (V.seeAge === 1); } + get requirements() { return (V.seeAge === 1); }, + pubertyActivated: true } ], ["progeria", @@ -35,7 +36,8 @@ App.Data.genes = new Map([ title: "progeria", abbreviation: "progeria", description: "rapid bodily aging", - get requirements() { return (V.seeAge === 1); } + get requirements() { return (V.seeAge === 1); }, + pubertyActivated: true } ], ["heterochromia", @@ -110,21 +112,24 @@ App.Data.genes = new Map([ { title: "macromastia", abbreviation: "mmast", - description: "an abnormal rate of breast growth" + description: "an abnormal rate of breast growth", + pubertyActivated: true } ], ["gigantomastia", { title: "gigantomastia", abbreviation: "gmast", - description: "an abnormally high rate of breast growth" + description: "an abnormally high rate of breast growth", + pubertyActivated: true } ], ["galactorrhea", { title: "galactorrhea", abbreviation: "rlact", - description: "the onset of unexpected lactation" + description: "the onset of unexpected lactation", + pubertyActivated: true } ], ["wellHung", diff --git a/src/facilities/surgery/analyzePregnancy.js b/src/facilities/surgery/analyzePregnancy.js index ff97cdc12be1588ce466ec1686100d3ab189d124..2ee6a0688ad11690b810b51ce573c02b325fe04d 100644 --- a/src/facilities/surgery/analyzePregnancy.js +++ b/src/facilities/surgery/analyzePregnancy.js @@ -108,6 +108,9 @@ globalThis.analyzePregnancies = function(mother, cheat) { const el = new DocumentFragment(); const options = new App.UI.OptionsGroup(); for (const [key, obj] of App.Data.genes) { + if (obj.hasOwnProperty("requirements") && !obj.requirements) { + continue; + } option = options.addOption(capFirstChar(obj.title), key, genes.geneticQuirks) .addComment(capFirstChar(obj.description)) .addValue("off", 0).off() @@ -118,7 +121,7 @@ globalThis.analyzePregnancies = function(mother, cheat) { option.addValue(capFirstChar(color), color); } } else { - option.addValue("on", 2).on(); + option.addValue("on", (obj.pubertyActivated) ? 3 : 2).on(); } } el.append(options.render()); @@ -260,7 +263,7 @@ globalThis.analyzePregnancies = function(mother, cheat) { const geneObj = App.Data.genes.get(gene); const quirkName = (geneObj && geneObj.abbreviation) ? geneObj.abbreviation : gene; const quirkColor = (geneObj && geneObj.goodTrait) ? "green" : "red"; - if (genes.geneticQuirks[gene] === 2 || typeof genes.geneticQuirks[gene] === "string") { // String check is for heterochromia + if (genes.geneticQuirks[gene] >= 2 || typeof genes.geneticQuirks[gene] === "string") { // String check is for heterochromia abnormalitySpans.push(App.UI.DOM.makeElement("span", quirkName, quirkColor)); } else if (genes.geneticQuirks[gene] === 1 && V.geneticMappingUpgrade >= 2) { abnormalitySpans.push(App.UI.DOM.makeElement("span", quirkName, "yellow"));