diff --git a/src/facilities/nursery/reports/childrenReport.js b/src/facilities/nursery/reports/childrenReport.js index bfcc5dc3dfaf890b2d56f5f786dc80da32c008de..d034fd0aa3ab19dd3061bfc3d69049e74539d654 100644 --- a/src/facilities/nursery/reports/childrenReport.js +++ b/src/facilities/nursery/reports/childrenReport.js @@ -13,14 +13,7 @@ App.Facilities.Nursery.childrenReport = function childrenReport() { r = []; for (const child of V.cribs) { - const - { he, his, He, His } = getPronouns(child); - - if (child.growTime > 0) { - r.push(`<span class="pink">${child.slaveName}</span> is growing steadily. ${He} will be ready for release in about ${years(child.growTime)}.`); - } else { - r.push(`<span class="pink">${child.slaveName}</span> is <span class="lime">ready for release.</span> ${He} will be removed from ${V.nurseryName} upon your approach.`); - } + r.push(childGrowTime(child)); if (child.actualAge >= 3) { if (Matron) { @@ -78,6 +71,16 @@ App.Facilities.Nursery.childrenReport = function childrenReport() { } } + function childGrowTime(child) { + const { He } = getPronouns(child); + + if (child.growTime > 0) { + return `<span class="pink">${child.slaveName}</span> is growing steadily. ${He} will be ready for release in about ${years(child.growTime)}.`; + } else { + return `<span class="pink">${child.slaveName}</span> is <span class="lime">ready for release.</span> ${He} will be removed from ${V.nurseryName} upon your approach.`; + } + } + // TODO: add relation checks function childFriendshipRivalries() { for (const target of V.cribs) { // alias for second child @@ -157,7 +160,9 @@ App.Facilities.Nursery.childrenReport = function childrenReport() { // MARK: Matron Effects function matronFetishEffects() { - const chance = jsRandom(1, 100); + const + { He } = getPronouns(child), + chance = jsRandom(1, 100); if (Matron.fetish !== "none") { if (chance > 90) {