diff --git a/devNotes/VersionChangeLog-Premod+LoliMod.txt b/devNotes/VersionChangeLog-Premod+LoliMod.txt index dead10c7db8cdd8649421625f558b7ea21229b6d..739cdd96aa953a25db465728dd37810146d44ad6 100644 --- a/devNotes/VersionChangeLog-Premod+LoliMod.txt +++ b/devNotes/VersionChangeLog-Premod+LoliMod.txt @@ -1,5 +1,24 @@ Pregmod +0.10.7.1-1.6.x + +01/21/2019 + + 3 + -fixes + -sufficiently grown children may survive slave bursting + + 2 + -more budget fixes to seeUnit and pPeaceKeepersDeficit + + 1 + -fixed an error with cloning + + 0 + -overhauled budget tracking + -embedded vector art now handled in JS + -fixes + 0.10.7.1-1.5.x 01/16/2019 diff --git a/devTools/makeTwineJSPassage.sh b/devTools/makeTwineJSPassage.sh index fe27af530671cbc8c89f0fe1bffa81e3b388bb00..408018e4a158471e200fa5211e1c417c955edf71 100755 --- a/devTools/makeTwineJSPassage.sh +++ b/devTools/makeTwineJSPassage.sh @@ -6,8 +6,8 @@ # $1: root repo dir # $2: output file name collectJSForTwine() { - echo ":: TwineJS [script]" > "$2" - find . -name '*.js' -exec echo -e "\n/* {} */\n" \; -a -exec sed -nf "$1"/devTools/stripComments.sed {} \; >> "$2" + echo "" > "$2" + find . -path ./art/assistantArt.js -prune -o -name '*.js' -exec echo -e "\n/* {} */\n" \; -a -exec sed -nf "$1"/devTools/stripComments.sed {} \; >> "$2" } ROOT_REPO_DIR="$(git rev-parse --show-toplevel)" diff --git a/devTools/stripComments.sed b/devTools/stripComments.sed index c9ceb3dc0c37b50f2f2a429829c5c717e504b0a0..a289e43b1de5feecd0d46d5b21257cd906f38fac 100755 --- a/devTools/stripComments.sed +++ b/devTools/stripComments.sed @@ -13,8 +13,9 @@ :loop +# ezsh: commented out because it removes '//' and everything after that in string literals # This line is sufficient to remove C++ comments! -/^\/\// s,.*,, +#/^\/\// s,.*,, /^$/{ x diff --git a/src/SecExp/seeUnit.tw b/src/SecExp/seeUnit.tw index 0a5d17ef3a303c01635bbf11e0c9bcc5db6677eb..dce90b6036d1a1faf99638cbba077c5792ddc98f 100644 --- a/src/SecExp/seeUnit.tw +++ b/src/SecExp/seeUnit.tw @@ -28,7 +28,7 @@ <br> <<link "Refine the drone network with $SF.Lower assistance" "seeUnit">> <<set $secBots.maxTroops += 10>> - <<run cashX(forceNeg(5000 + 10 * $secBotsUpgradeCost * $secBots.equip), "securityExpansion")>> + <<run cashX(forceNeg(5000 + 10 * $secBotsUpgradeCost * $secBots.equip)), "securityExpansion")>> <</link>> Utilize the technological developments made by $SF.Lower to further improve the control matrix of the security drones. <br>//Costs <<print cashFormat(5000 + 10 * $secBotsUpgradeCost * $secBots.equip)>> and will increase the max by 10// @@ -41,7 +41,7 @@ <br> <<link "Improve drone weaponry and armor" "seeUnit">> <<set $secBots.equip += 1>> - <<run cashX(forceNeg((($secBotsUpgradeCost * $secBots.maxTroops) + 1000)), "securityExpansion")>> + <<run cashX(forceNeg(($secBotsUpgradeCost * $secBots.maxTroops) + 1000), "securityExpansion")>> <</link>> Invest in better equipment for your drones to increase their battle effectiveness. <br>//Costs <<print cashFormat(($secBotsUpgradeCost * $secBots.maxTroops) + 1000)>> and will increase attack and defense value of the unit by 15% for every upgrade.// @@ -247,7 +247,7 @@ <br> <<link "Improve weaponry and equipment">> <<set $slaveUnits[$targetIndex].equip += 1>> - <<run cashX(forceNeg($equipUpgradeCost * $slaveUnits[$targetIndex].maxTroops) + 1000), "securityExpansion")>> + <<run cashX(forceNeg($equipUpgradeCost * $slaveUnits[$targetIndex].maxTroops + 1000), "securityExpansion")>> <<goto "seeUnit">> <</link>> Invest in better equipment for your soldiers to increase their battle effectiveness. @@ -453,7 +453,7 @@ <br> <<link "Attach Special Force advisors" "seeUnit">> <<set $mercUnits[$targetIndex].SF = 1>> - <<run cashX(forceNeg($equipUpgradeCost * $mercUnits[$targetIndex].maxTroops) + 5000), "securityExpansion")>> + <<run cashX(forceNeg(($equipUpgradeCost * $mercUnits[$targetIndex].maxTroops) + 5000), "securityExpansion")>> <</link>> Attach $SF.Lower advisors to the unit. <br>//Costs <<print cashFormat(($equipUpgradeCost * $mercUnits[$targetIndex].maxTroops) + 5000)>> and will slightly increase the base stats of the unit.// diff --git a/src/pregmod/cloningWorkaround.tw b/src/pregmod/cloningWorkaround.tw index 68e2aae85eff58a91b22a1f08a40f13c92a46321..b8fcd9e8fe5bd970e6ad0773df6cbe654db6dde8 100644 --- a/src/pregmod/cloningWorkaround.tw +++ b/src/pregmod/cloningWorkaround.tw @@ -11,7 +11,7 @@ <<for _cw = 0; _cw < $slaves.length; _cw++>> <<capture _cw>> <<set _name = SlaveFullName($slaves[_cw])>> - <br><<print "[[_name|Cloning Workaround][$donatrix = $slaves[" + _cw + "]]]">> + <br>[[_name|Cloning Workaround][$donatrix = $slaves[_cw]]] <</capture>> <</for>> @@ -25,7 +25,7 @@ __Chosen surrogate: _receive __ <<capture _cw1>> <<if ($slaves[_cw1].ovaries > 0 || $slaves[_cw1].mpreg > 0) && isSlaveAvailable($slaves[_cw1]) && $slaves[_cw1].preg >= 0 && $slaves[_cw1].preg < 4 && $slaves[_cw1].pregWeek >= 0 && $slaves[_cw1].pubertyXX == 1 && $slaves[_cw1].pregType < 12 && $slaves[_cw1].bellyImplant == -1 && $slaves[_cw1].broodmother == 0 && $slaves[_cw1].inflation <= 2 && $slaves[_cw1].physicalAge < 70>> <<set _name2 = SlaveFullName($slaves[_cw1])>> - <br><<print "[[_name2|Cloning Workaround][$receptrix = $slaves[" + _cw1 + "]]]">> <<if $slaves[_cw1].pregType >= 4>>//Using a slave carrying multiples is unadvisable//<</if>> + <br>[[_name2|Cloning Workaround][$receptrix = $slaves[_cw1]]] <<if $slaves[_cw1].pregType >= 4>>//Using a slave carrying multiples is unadvisable//<</if>> <<set _eligibility = 1>> <</if>> <</capture>> @@ -43,5 +43,5 @@ __Chosen surrogate: _receive __ _impreg will be cloned and _receive shall act as the incubator. <<if _impreg != "Undecided" && _receive != "Undecided">> - [[Implant clone ovum|Surrogacy][cashX(forceNeg($surgeryCost*2), "slaveSurgery", _receive), $surgeryType = 'clone']] + [[Implant clone ovum|Surrogacy][cashX(forceNeg($surgeryCost*2), "slaveSurgery"), $surgeryType = 'clone']] <</if>> \ No newline at end of file diff --git a/src/pregmod/ovaTransplantWorkaround.tw b/src/pregmod/ovaTransplantWorkaround.tw index 335d100478b9c8783ee3caa0599ef28ce630effb..870c9bde06ffbe390d79798cf1d116152bcdbdcb 100644 --- a/src/pregmod/ovaTransplantWorkaround.tw +++ b/src/pregmod/ovaTransplantWorkaround.tw @@ -14,7 +14,7 @@ __Select a slave to serve as the host__ <<capture _otw>> <<if ($donatrix.ID != $slaves[_otw].ID && $slaves[_otw].ovaries > 0 || $slaves[_otw].mpreg > 0) && isSlaveAvailable($slaves[_otw]) && $slaves[_otw].preg >= 0 && $slaves[_otw].preg < $slaves[_otw].pregData.normalBirth/10 && $slaves[_otw].pregWeek >= 0 && $slaves[_otw].pubertyXX == 1 && $slaves[_otw].pregType < 12 && $slaves[_otw].bellyImplant == -1 && $slaves[_otw].broodmother == 0 && $slaves[_otw].inflation <= 2 && $slaves[_otw].physicalAge < 70>> <<set _name = SlaveFullName($slaves[_otw])>> - <br><<print "[[_name|Surrogacy][$receptrix = $slaves[" + _otw + "], cashX(forceNeg($surgeryCost*2), "slaveSurgery"), $surgeryType = 'transplant']]">> <<if $slaves[_otw].pregType >= 4>>//Using a slave carrying multiples is unadvisable//<</if>> + <br>[[_name|Surrogacy][$receptrix = $slaves[_otw], cashX(forceNeg($surgeryCost*2), "slaveSurgery"), $surgeryType = "transplant"]] <<if $slaves[_otw].pregType >= 4>>//Using a slave carrying multiples is unadvisable//<</if>> <<set _eligibility = 1>> <</if>> <</capture>> diff --git a/src/pregmod/seBurst.tw b/src/pregmod/seBurst.tw index 73a84bb8f98ccf9283595e2d186c9d09eaa38a9c..707783ca4fb7ff4511adeea968ff4213ebff298b 100644 --- a/src/pregmod/seBurst.tw +++ b/src/pregmod/seBurst.tw @@ -6,7 +6,288 @@ <<if $slaves[_b].burst == 1>> <<if (($slaves[_b].belly > ($slaves[_b].pregAdaptation*3200)) || $slaves[_b].bellyPreg > 600000)>> - $slaves[_b].slaveName's straining womb finally gave out and burst, taking $his life and that of $his children. //Placeholder// + + <<set $slaves[_b].curBabies = WombBirth($slaves[_b], $slaves[_b].pregData.minLiveBirth)>> + <<set $slaves[_b].curStillBirth = 0 >> + <<set _curBabies = $slaves[_b].curBabies.length>> /*just to improve speed and usability here.*/ + <<set $birthsTotal += _curBabies>> + + <<set _others = 0, _PC = 0, _citizens = 0, _oldMaster = 0, _arcOwner = 0, _lab = 0, _fathers = [], _babyFatherLink = []>> + <<for _cb = 0; _cb < $slaves[_b].curBabies.length; _cb++>> + <<if $slaves[_b].curBabies[_cb].fatherID == 0 || $slaves[_b].curBabies[_cb].fatherID == -5>> + <<set _others++>> + <<set _fathers.push("some man's")>> + <<elseif $slaves[_b].curBabies[_cb].fatherID == -1>> + <<set $PC.slavesFathered++>> + <<set _PC++>> + <<set _fathers.push("your")>> + <<elseif $slaves[_b].curBabies[_cb].fatherID == -2>> + <<set _citizens++>> + <<set _fathers.push("your arcology's")>> + <<elseif $slaves[_b].curBabies[_cb].fatherID == -3>> + <<set _oldMaster++>> + <<set _fathers.push("your former Master's")>> + <<elseif $slaves[_b].curBabies[_cb].fatherID == -4>> + <<set _arcOwner++>> + <<set _fathers.push("another arcology owner's")>> + <<elseif $slaves[_b].curBabies[_cb].fatherID == -7>> + <<set _lab++>> + <<set _fathers.push("the gene lab's")>> + <<else>> + <<set _babyDaddy = findFather($slaves[_b].curBabies[_cb].fatherID)>> + <<if def _babyDaddy>> + <<if _babyDaddy.ID == $slaves[_b].ID>> + <<set _fathers.push(String($his + " own"))>> + <<for _cb2 = 0; _cb2 < _babyFatherLink.length; _cb2++>> + <<if _babyFatherLink[_cb2].string == String($his + " own")>> + <<set _babyFatherLink[_cb2].count++>> + <<else>> + <<set _babyFatherLink[_cb2] = {string: String($his + " own"), count: 1}>> + <</if>> + <</for>> + <<else>> + <<set _fathers.push(String(_babyDaddy.slaveName+ "'s"))>> + <<for _cb2 = 0; _cb2 < _babyFatherLink.length; _cb2++>> + <<if _babyFatherLink[_cb2].string == String(_babyDaddy.slaveName+ "'s")>> + <<set _babyFatherLink[_cb2].count++>> + <<else>> + <<set _babyFatherLink[_cb2] = {string: String(_babyDaddy.slaveName+ "'s"), count: 1}>> + <</if>> + <</for>> + <</if>> + <<set _adjust = _babyDaddy.slavesFathered++>> + <<set adjustFatherProperty(_babyDaddy, "slavesFathered", _adjust)>> + <<else>> + <<set _others++>> + <<set _fathers.push("some man's")>> + <</if>> + <</if>> + <</for>> + <<set _fathersReduced = removeDuplicates(_fathers)>> + <<for _cb = 0; _cb < _fathersReduced.length; _cb++>> + <<set _num = 0>> + <<if _fathersReduced[_cb] == "some man's">> + <<set _num = _others>> + <<elseif _fathersReduced[_cb] == "your">> + <<set _num = _PC>> + <<elseif _fathersReduced[_cb] == "your arcology's">> + <<set _num = _citizens>> + <<elseif _fathersReduced[_cb] == "your former Master's">> + <<set _num = _oldMaster>> + <<elseif _fathersReduced[_cb] == "another arcology owner's">> + <<set _num = _arcOwner>> + <<elseif _fathersReduced[_cb] == "the gene lab's">> + <<set _num = _lab>> + <<else>> + <<set _cb2 = _babyFatherLink.findIndex(function(s) {_fathersReduced[_cb] == _babyFatherLink[s].string; })>> + <<if _cb2 != -1>> + <<set _num = _babyFatherLink[_cb2].count>> + <</if>> + <</if>> + <<if _num == 1>> + <<set _fathersReduced[_cb] += " baby">> + <<elseif _num >= 40>> + <<set _fathersReduced[_cb] += String(" massive brood of " + _num + " babies")>> + <<elseif _num >= 20>> + <<set _fathersReduced[_cb] += String(" brood of " + _num + " babies")>> + <<elseif _num >= 10>> + <<set _fathersReduced[_cb] += String(" impressive group of " + _num + " babies")>> + <<elseif _num == 9>> + <<set _fathersReduced[_cb] += " nonuplets">> + <<elseif _num == 8>> + <<set _fathersReduced[_cb] += " octuplets">> + <<elseif _num == 7>> + <<set _fathersReduced[_cb] += " septuplets">> + <<elseif _num == 6>> + <<set _fathersReduced[_cb] += " sextuplets">> + <<elseif _num == 5>> + <<set _fathersReduced[_cb] += " quintuplets">> + <<elseif _num == 4>> + <<set _fathersReduced[_cb] += " quadruplets">> + <<elseif _num == 3>> + <<set _fathersReduced[_cb] += " triplets">> + <<elseif _num == 2>> + <<set _fathersReduced[_cb] += " twins">> + <</if>> + <</for>> + + <<if $slaves[_b].broodmother < 1>> + <<set $slaves[_b].curStillBirth = $slaves[_b].womb.length>> + <<set WombFlush($slaves[_b])>> + <</if>> + + <<set _incubated = 0>> + <<set _cToIncub = 0, _cToNursery = 0>> + <<for _csec = 0; _csec < _curBabies; _csec++>> + <<if $slaves[_b].curBabies[_csec].reserve === "incubator">> + <<set _cToIncub++>> + <<elseif $slaves[_b].curBabies[_csec].reserve === "nursery">> + <<set _cToNursery++>> + <</if>> + <</for>> + + /* ------------------------------------------------ */ + + $slaves[_b].slaveName's straining womb finally gave out and burst, taking $his + + <<if _curBabies > 0>> + life, but not <<if _curBabies <= 1>>that of $his child<<else>>those of all $his children<</if>>; + <<if _fathersReduced.length > 2>> + <<for _cb = 0; _cb < _fathersReduced.length; _cb++>> + <<if _cb < _fathersReduced.length-1>> + _fathersReduced[_cb], + <<else>> + and _fathersReduced[_cb] + <</if>> + <</for>> + <<elseif _fathersReduced.length > 1>> + _fathersReduced[0] and _fathersReduced[1] + <<else>> + _fathersReduced[0] + <</if>> + + <<if _curBabies <= 1>>has<<else>>have<</if>> + promptly been + + <<set _incubated = 0>> + <<if _cToIncub == _curBabies>> + taken to $incubatorName. + <<elseif _cToIncub < _curBabies && _cToIncub > 0>> + split between $incubatorName and + <<if _cToNursery == _curBabies-_cToIncub && _incubated > 0>> + $nurseryName. + <<elseif _cToNursery < _curBabies-_cToIncub && _cToNursery > 0>> + $nurseryName, and the medical suite. + <</if>> + <<elseif _cToNursery == _curBabies>> + taken to $nurseryName. + <<elseif _cToNursery < _curBabies && _cToNursery > 0>> + split between $nurseryName and the medical suite. + <<else>> + taken to the medical suite. + <</if>> + + <<set $mom = $slaves[_b]>> + <<if _cToIncub > 0 || _cToNursery > 0>> + <<for _cb = 0; _cb < _curBabies; _cb++>> /* if there is no reserved children, code in loop will not trigger */ + <<if $mom.curBabies[_cb].reserve == "incubator">> + <<set $slaves[_b] = generateChild($mom, $mom.curBabies[_cb], 1)>> + <<include "Incubator Workaround">> + <<run $mom.curBabies.splice($mom.curBabies[_cb], 1)>> + <<set _cb--, _curBabies-->> + <<elseif $mom.curBabies[_cb].reserve == "nursery">> + <<set $slaves[_b] = generateChild($mom, $mom.curBabies[_cb])>> + <<include "Nursery Workaround">> + <<run $mom.curBabies.splice($mom.curBabies[_cb], 1)>> + <<set _cb--, _curBabies-->> + <</if>> + <</for>> + <</if>> + <<set $slaves[_b] = $mom>> + + <<else>> + life and <<if _curBabies <= 1>>that of $his child<<else>>those of $his children<</if>>. + <</if>> + + <<set _curBabies = $slaves[_b].curBabies.length>> + + <<if _curBabies > 0>> + <<set _count = _curBabies>> + <br><br> + <<span $dispositionId>> + <<if $arcologies[0].FSRestart != "unset" && $slaves[[_b].breedingMark == 1 && $propOutcome == 1 && $slaves[$i].pregSource == -1>> + <<set _lostBabies = 1>> + From there, $his child<<if _curBabies > 1>>ren are<<else>> is<</if>> collected by the Societal Elite to be raised into upstanding members of the new society. + <<elseif $Cash4Babies == 1 && $DefaultBirthDestination !== "the market">> + <<set _lostBabies = 1>> + <<set _babyCost = random(-12,12)>> + <<if $slaves[$i].prematureBirth == 1>><<set _babyCost = -45>><</if>> + $His <<if _curBabies > 1>>babies<<else>>baby<</if>> sold for <<if _curBabies > 1>>a total of <</if>>@@.yellowgreen;<<print cashFormat(_curBabies*(50+_babyCost))>>.@@<<if $slaves[$i].prematureBirth == 1>> A low price due to the added costs of caring for them.<</if>> + <<run cashX((_curBabies*(50+_babyCost)), "babyTransfer")>> + <</if>> + <<if _lostBabies != 1 && $universalRulesChildrenBecomeBreeders > 0 && $arcologies[0].FSRepopulationFocus > 40 && $DefaultBirthDestination === "individually decided fates">> + <<set _lostBabies = 1>> + $His child<<if _curBabies > 1>>ren are<<else>> is<</if>> sent to one of $arcologies[0].name's future minded schools, to be administered fertility and virility treatments as well as be brought up to take pride in reproduction. Hopefully there they will be trained to not suffer the same fate. + <<set $breederOrphanageTotal += _count>> + <<elseif _lostBabies != 1 && $DefaultBirthDestination === "individually decided fates" && $universalRulesChildrenBecomeBreeders < 1>> + <<set $slaveOrphanageTotal += _curBabies>> + Unless you provide otherwise, the child<<if _curBabies > 1>>ren<</if>> will be remanded to one of $arcologies[0].name's slave orphanages. + <<capture $i, $dispositionId, _count>> + <br> + <<if $arcologies[0].FSRepopulationFocus > 40>> + <<link 'Send them to a breeder school'>> + <<replace `"#" + $dispositionId`>> + The child<<if _count > 1>>ren are<<else>> is<</if>> sent to one of $arcologies[0].name's future minded schools, to be administered fertility and virility treatments as well as be brought up to take pride in reproduction. Hopefully there they will be trained to not suffer the same fate. + <<set $breederOrphanageTotal += _count, $slaveOrphanageTotal -= _count>> + <</replace>> + <</link>> + //Will cost a one-time <<print cashFormat(50)>>// | + <</if>> + <<link 'Send them to a citizen school'>> + <<replace `"#" + $dispositionId`>> + The child<<if _count > 1>>ren are<<else>> is<</if>> sent to one of $arcologies[0].name's citizen schools, to be brought up coequal with the arcology's other young people. + <<set $slaves[$i].devotion += 4, $citizenOrphanageTotal += _count, $slaveOrphanageTotal -= _count>> + <</replace>> + <</link>> + //Will cost <<print cashFormat(100)>> weekly// + | <<link 'Have them raised privately'>> + <<replace `"#" + $dispositionId`>> + The child<<if _count > 1>>ren are<<else>> is<</if>> sent to be privately raised, to be brought up as a future high class citizen. + <<set $slaves[$i].devotion += 6, $privateOrphanageTotal += _count, $slaveOrphanageTotal -= _count>> + <</replace>> + <</link>> + //Will cost <<print cashFormat(500)>> weekly// + <<if $Cash4Babies == 1>> + <<if $slaves[$i].prestige > 1 || $slaves[$i].pornPrestige > 2>> + | <<link 'Send them to auction'>> + <<replace `"#" + $dispositionId`>> + <<<set _babyCost = random(-12,12)>> + <<if $slaves[$i].prematureBirth == 1>><<set _babyCost = -45>><</if>> + $His <<if _curBabies > 1>>babies<<else>>baby<</if>> sold for <<if _curBabies > 1>>a total of <</if>>@@.yellowgreen;<<print cashFormat(_curBabies*(50+_babyCost))>>.@@<<if $slaves[$i].prematureBirth == 1>> A low price due to the added costs of caring for them.<</if>> + <<run cashX((_curBabies*(50+_babyCost)), "babyTransfer")>> + <<set $slaveOrphanageTotal -= _count>> + <</replace>> + <</link>> + <<else>> + | <<link 'Sell them anyway'>> + <<replace `"#" + $dispositionId`>> + <<set _babyCost = random(-12,12)>> + <<if $slaves[$i].prematureBirth == 1>><<set _babyCost = -45>><</if>> + $His <<if _curBabies > 1>>babies<<else>>baby<</if>> sold for <<if _curBabies > 1>>a total of <</if>>@@.yellowgreen;<<print cashFormat(_curBabies*(50+_babyCost))>>.@@<<if $slaves[$i].prematureBirth == 1>> A low price due to the added costs of caring for them.<</if>> + <<run cashX((_curBabies*(50+_babyCost)), "babyTransfer")>> + <<set $slaveOrphanageTotal -= _count>> + <</replace>> + <</link>> + <</if>> + <</if>> + <</capture>> + <</if>> + <</span>> + <<elseif $Cash4Babies == 1 && _curBabies > 0 && $DefaultBirthDestination === "individually decided fates" && $universalRulesChildrenBecomeBreeders < 1>> + <br><br> + <<set _babyCost = random(-12,12)>> + <<if $slaves[$i].prematureBirth == 1>><<set _babyCost = -45>><</if>> + $His <<if _curBabies > 1>>babies<<else>>baby<</if>> were sold for <<if _curBabies > 1>>a total of <</if>>@@.yellowgreen;<<print cashFormat(_curBabies*(50+_babyCost))>>.@@<<if $slaves[$i].prematureBirth == 1>> A low price due to the added costs of caring for them.<</if>> + <<run cashX((_curBabies*(50+_babyCost)), "babyTransfer")>> + <</if>> + + <<if $arcologies[0].FSRestart != "unset" && _curBabies > 0 && $eugenicsFullControl != 1>> + <br><br> + <<if $slaves[_b].breedingMark == 1 && ($slaves[_b].pregSource == -1 || $slaves[_b].pregSource == -6) && $propOutcome == 1>> + The Societal Elite @@.green;are pleased@@ at the new additions to their class, despite it claiming a promising breeder. + <<set $failedElite -= _curBabies>> + <<else>> + The Societal Elite @@.red;are disappointed@@ that you would allow subhuman filth to dirty society under your watch. Society @@.red;frowns@@ on the unwelcome addition of more subhumans into the world. At least the "birth" claimed the wretched $girl's life. + <<if $eugenicsFullControl != 1>> + <<set $failedElite += 5*_curBabies>> + <</if>> + <<set $rep -= 10*_curBabies>> + <</if>> + <</if>> + + <<set $reservedChildren = FetusGlobalReserveCount("incubator")>> + <<set $reservedChildrenNursery = FetusGlobalReserveCount("nursery")>> + <<elseif $slaves[_b].inflation != 0>> <<pop $slaves[_b]>> <</if>> diff --git a/src/pregmod/slaveSlaveSwapWorkaround.tw b/src/pregmod/slaveSlaveSwapWorkaround.tw index 944894cc83c36179016540b535f1456b2e6b9155..8cf478a42428668d47f58a227254277b70d3c7d5 100644 --- a/src/pregmod/slaveSlaveSwapWorkaround.tw +++ b/src/pregmod/slaveSlaveSwapWorkaround.tw @@ -10,12 +10,14 @@ The surgeon awaits the pair of slaves to be strapped into the surgery. So far on <br><br> __Select an eligible slave:__ <<for _i = 0; _i < $slaves.length; _i++>> +<<capture _i>> <<if isSlaveAvailable($slaves[_i])>> <<if $slaves[_i].fuckdoll == 0>> <<if ($slaves[_i].ID != $activeSlave.ID)>> <<set _name = SlaveFullName($slaves[_i])>> - <br><<print "[[_name|Slave Slave Swap][$swappingSlave = $slaves[" + _i + "], cashX(-10000, "slaveSurgery", $slaves[_i])]]">> + <br>[[_name|Slave Slave Swap][$swappingSlave = $slaves[_i], cashX(-10000, "slaveSurgery", $slaves[_i])]] <</if>> <</if>> <</if>> +<</capture>> <</for>> \ No newline at end of file diff --git a/src/pregmod/surrogacyWorkaround.tw b/src/pregmod/surrogacyWorkaround.tw index 22735efba7f34b3c0918999cf6213b60c357b388..eefc4047a44b3312b55be964797939ccbb3294dc 100644 --- a/src/pregmod/surrogacyWorkaround.tw +++ b/src/pregmod/surrogacyWorkaround.tw @@ -16,7 +16,7 @@ _impreg will provide the seed and _receive shall carry it. <<if _impreg != "Undecided" && _receive != "Undecided">> - [[Implant fertilized ovum|Surrogacy][cashX(forceNeg($surgeryCost*2), "slaveSurgery", _receive), $surgeryType = 'surrogacy']] + [[Implant fertilized ovum|Surrogacy][cashX(forceNeg($surgeryCost*2), "slaveSurgery"), $surgeryType = 'surrogacy']] <</if>> <br><br> @@ -28,7 +28,7 @@ __Semen donatrix: _impreg __ <<capture _sw>> <<if $slaves[_sw].balls > 0 && $slaves[_sw].pubertyXY == 1 && isSlaveAvailable($slaves[_sw]) && canBreed($donatrix, $slaves[_sw])>> <<set _name = SlaveFullName($slaves[_sw])>> - <br><<print "[[_name|Surrogacy Workaround][$impregnatrix = $slaves[" + _sw + "]]]">> + <br>[[_name|Surrogacy Workaround][$impregnatrix = $slaves[_sw]]] <<set _eligibility = 1>> <</if>> <</capture>> @@ -47,7 +47,7 @@ __Semen donatrix: _impreg __ <<capture _sw3>> <<if $tanks[_sw3].balls > 0 && $tanks[_sw3].dick > 0 && canBreed($donatrix, $tanks[_sw3])>> <<set _name3 = $tanks[_sw3].slaveName>> - <<print "[[_name3|Surrogacy Workaround][$impregnatrix = $tanks[" + _sw3 + "]]]">> + [[_name3|Surrogacy Workaround][$impregnatrix = $tanks[_sw3]]] <<set _eligibilityI = 1>> <</if>> <</capture>> @@ -72,7 +72,7 @@ __Chosen surrogate: _receive __ <<capture _sw1>> <<if ($slaves[_sw1].ovaries > 0 || $slaves[_sw1].mpreg > 0) && isSlaveAvailable($slaves[_sw1]) && $slaves[_sw1].preg >= 0 && $slaves[_sw1].preg < 4 && $slaves[_sw1].pregWeek >= 0 && $slaves[_sw1].pubertyXX == 1 && $slaves[_sw1].pregType < 12 && $slaves[_sw1].bellyImplant == -1 && $slaves[_sw1].broodmother == 0 && $slaves[_sw1].inflation <= 2 && $slaves[_sw1].physicalAge < 70>> <<set _name2 = SlaveFullName($slaves[_sw1])>> - <br><<print "[[_name2|Surrogacy Workaround][$receptrix = $slaves[" + _sw1 + "]]]">> <<if $slaves[_sw1].pregType >= 4>>//Using a slave carrying multiples is unadvisable//<</if>> + <br>[[_name2|Surrogacy Workaround][$receptrix = $slaves[_sw1]]] <<if $slaves[_sw1].pregType >= 4>>//Using a slave carrying multiples is unadvisable//<</if>> <<set _eligibility2 = 1>> <</if>> <</capture>> diff --git a/src/pregmod/widgets/seBirthWidgets.tw b/src/pregmod/widgets/seBirthWidgets.tw index 59cd953e1da72e3e07fd745dc5b1fafdf4c38339..77e433f1b47811571679a75dc41e916077edd587 100644 --- a/src/pregmod/widgets/seBirthWidgets.tw +++ b/src/pregmod/widgets/seBirthWidgets.tw @@ -919,7 +919,7 @@ All in all, <<if _lostBabies != 1 && $universalRulesChildrenBecomeBreeders > 0 && $arcologies[0].FSRepopulationFocus > 40 && $DefaultBirthDestination === "individually decided fates">> <<set _lostBabies = 1>> $His <<= BirthDestinationText("Orphanage",$slaves[$i])>> - <<set $breederOrphanageTotal += _count, $slaveOrphanageTotal -= _count>> + <<set $breederOrphanageTotal += _curBabies>> <<elseif _lostBabies != 1 && $DefaultBirthDestination === "individually decided fates" && $universalRulesChildrenBecomeBreeders < 1>> <<set $slaveOrphanageTotal += _curBabies>> Unless you provide otherwise, the child<<if _curBabies > 1>>ren<</if>> will be remanded to one of $arcologies[0].name's slave orphanages. @@ -954,12 +954,14 @@ All in all, | <<link 'Send them to auction'>> <<replace `"#" + $dispositionId`>> <<= BirthDestinationText("Sold",$slaves[$i])>> + <<set $slaveOrphanageTotal -= _count>> <</replace>> <</link>> <<else>> | <<link 'Sell them anyway'>> <<replace `"#" + $dispositionId`>> <<= BirthDestinationText("Sold",$slaves[$i])>> + <<set $slaveOrphanageTotal -= _count>> <</replace>> <</link>> <</if>> diff --git a/src/uncategorized/pPeacekeepersDeficit.tw b/src/uncategorized/pPeacekeepersDeficit.tw index 18819bd22859d4e237ca0bfd9f7c513c57c2cc89..f6924ef32c123c9df3d036159454ee20212fe886 100644 --- a/src/uncategorized/pPeacekeepersDeficit.tw +++ b/src/uncategorized/pPeacekeepersDeficit.tw @@ -28,7 +28,8 @@ The singular solution to the two problems is obvious. It's equally obvious that Understanding that the general needs to couch the situation in a way he can justify in public, and perhaps in a way he can justify to himself, you offer to house the prisoners on a contract basis, with immediate payment to the general so he can meet his forces' immediate needs. Naturally, the prisoners will be kept busy while you keep them; menial labor seems appropriate. It's unlikely that the situation will ever stabilize to the point where they can be released, so for safety, they should all be detained indefinitely. And of course, each prisoner's individual detention will be available for resale. Just like any other slave's. <br><br> The general is unable to keep from smiling slightly when he hears that you understand perfectly and are willing and able to assist. There's some bitterness there, but not much. The two of you adjust the terms. The new menial slaves will be delivered immediately, several hundred of them; the general prefers to have this be a one-time transfer. After all, having an ongoing prisoner pipeline between his prisoner pens and the Free City might draw unwanted political attention. For now, he has the funds he needs, not to mention an empty prison camp. - <<set $peacekeepers.attitude += 5, cashX(-100000, "peacekeepers") $menials += 200>> + <<set $peacekeepers.attitude += 5, $menials += 200>> + <<run cashX(-100000, "peacekeepers")>> <</replace>> <</link>> //This will cost <<print cashFormat(100000)>> and provide a number of menial slaves// <<else>>