code:
:: bodyswap widgets [nobr widget]

/* It's too fucking big jesus christ */

/* first arg is slave getting swapped, second is body she is being swapped to. The second body's physical traits overwrite the originals */
<<widget "BodySwap">>

<<set WombInit($args[1])>> /*Just to be sure.*/
<<set $args[0].genes = $args[1].genes>>
<<set $args[0].physicalAge = $args[1].physicalAge>>
<<set $args[0].visualAge = $args[1].visualAge>>
<<set $args[0].ageImplant = $args[1].ageImplant>>
<<set $args[0].health.condition = $args[1].health.condition>>
<<set $args[0].health.shortDamage = $args[1].health.shortDamage>>
<<set $args[0].health.longDamage = $args[1].health.longDamage>>
<<set $args[0].health.illness = $args[1].health.illness>>
<<set $args[0].health.tired = $args[1].health.tired>>
<<set $args[0].health.health = $args[1].health.health>>
<<set $args[0].weight = $args[1].weight>>
<<set $args[0].muscles = $args[1].muscles>>
<<set $args[0].height = $args[1].height>>
<<set $args[0].heightImplant = $args[1].heightImplant>>
<<set $args[0].race = $args[1].race>>
<<set $args[0].origRace = $args[1].origRace>>
<<set $args[0].pubicHColor = $args[1].pubicHColor>>
<<set $args[0].skin = $args[1].skin>>
<<set $args[0].origSkin = $args[1].origSkin>>
<<set $args[0].markings = $args[1].markings>>
<<set $args[0].eye = $args[1].eye>>
<<set $args[0].hears = $args[1].hears>>
<<set $args[0].earImplant = $args[1].earImplant>>
<<set $args[0].earShape = $args[1].earShape>>
<<set $args[0].earT = $args[1].earT>>
<<set $args[0].earTColor = $args[1].earTColor>>
<<set $args[0].smells = $args[1].smells>>
<<set $args[0].tastes = $args[1].tastes>>
<<set $args[0].horn = $args[1].horn>>
<<set $args[0].hornColor = $args[1].hornColor>>
<<set $args[0].PTail = $args[1].PTail>>
<<set $args[0].tail = $args[1].tail>>
<<set $args[0].tailShape = $args[1].tailShape>>
<<set $args[0].tailColor = $args[1].tailColor>>
<<set $args[0].origHColor = $args[1].origHColor>>
<<set $args[0].hColor = $args[1].hColor>>
<<set $args[0].hLength = $args[1].hLength>>
<<set $args[0].hStyle = $args[1].hStyle>>
<<set $args[0].pubicHStyle = $args[1].pubicHStyle>>
<<set $args[0].waist = $args[1].waist>>
<<set $args[0].corsetPiercing = $args[1].corsetPiercing>>
<<set $args[0].arm = $args[1].arm>>
<<set $args[0].leg = $args[1].leg>>
<<set $args[0].PLimb = $args[1].PLimb>>
<<set $args[0].readyProsthetics = $args[1].readyProsthetics>>
<<set $args[0].heels = $args[1].heels>>
<<set $args[0].voice = $args[1].voice>>
<<set $args[0].voiceImplant = $args[1].voiceImplant>>
<<set $args[0].shoulders = $args[1].shoulders>>
<<set $args[0].shouldersImplant = $args[1].shouldersImplant>>
<<set $args[0].boobs = $args[1].boobs>>
<<set $args[0].boobsImplant = $args[1].boobsImplant>>
<<set $args[0].boobsImplantType = $args[1].boobsImplantType>>
<<set $args[0].boobShape = $args[1].boobShape>>
<<set $args[0].nipples = $args[1].nipples>>
<<set $args[0].nipplesPiercing = $args[1].nipplesPiercing>>
<<set $args[0].nipplesAccessory = $args[1].nipplesAccessory>>
<<set $args[0].areolae = $args[1].areolae>>
<<set $args[0].areolaePiercing = $args[1].areolaePiercing>>
<<set $args[0].areolaeShape = $args[1].areolaeShape>>
<<set $args[0].boobsTat = $args[1].boobsTat>>
<<set $args[0].lactation = $args[1].lactation>>
<<set $args[0].lactationDuration = $args[1].lactationDuration>>
<<set $args[0].induceLactation = $args[1].induceLactation>>
<<set $args[0].boobsMilk = $args[1].boobsMilk>>
<<set $args[0].lactationAdaptation = $args[1].lactationAdaptation>>
<<set $args[0].hips = $args[1].hips>>
<<set $args[0].hipsImplant = $args[1].hipsImplant>>
<<set $args[0].butt = $args[1].butt>>
<<set $args[0].buttImplant = $args[1].buttImplant>>
<<set $args[0].buttImplantType = $args[1].buttImplantType>>
<<set $args[0].buttTat = $args[1].buttTat>>
<<set $args[0].face = $args[1].face>>
<<set $args[0].faceImplant = $args[1].faceImplant>>
<<set $args[0].faceShape = $args[1].faceShape>>
<<set $args[0].lips = $args[1].lips>>
<<set $args[0].lipsImplant = $args[1].lipsImplant>>
<<set $args[0].lipsPiercing = $args[1].lipsPiercing>>
<<set $args[0].lipsTat = $args[1].lipsTat>>
<<set $args[0].teeth = $args[1].teeth>>
<<set $args[0].tonguePiercing = $args[1].tonguePiercing>>
<<set $args[0].vagina = $args[1].vagina>>
<<set $args[0].vaginaLube = $args[1].vaginaLube>>
<<set $args[0].vaginaPiercing = $args[1].vaginaPiercing>>
<<set $args[0].vaginaTat = $args[1].vaginaTat>>
<<set $args[0].fertKnown = $args[1].fertKnown>>
<<set $args[0].fertPeak = $args[1].fertPeak>>
<<set $args[0].broodmother = $args[1].broodmother>>
<<set $args[0].broodmotherFetuses = $args[1].broodmotherFetuses>>
<<set $args[0].broodmotherOnHold = $args[1].broodmotherOnHold>>
<<set $args[0].broodmotherCountDown = $args[1].broodmotherCountDown>>
<<set $args[0].labia = $args[1].labia>>
<<set $args[0].clit = $args[1].clit>>
<<set $args[0].clitPiercing = $args[1].clitPiercing>>
<<set $args[0].dick = $args[1].dick>>
<<set $args[0].foreskin = $args[1].foreskin>>
<<set $args[0].anus = $args[1].anus>>
<<set $args[0].analArea = $args[1].analArea>>
<<set $args[0].dickPiercing = $args[1].dickPiercing>>
<<set $args[0].dickTat = $args[1].dickTat>>
<<set $args[0].prostate = $args[1].prostate>>
<<set $args[0].balls = $args[1].balls>>
<<set $args[0].scrotum = $args[1].scrotum>>
<<set $args[0].ovaries = $args[1].ovaries>>
<<set $args[0].anusPiercing = $args[1].anusPiercing>>
<<set $args[0].anusTat = $args[1].anusTat>>
<<set $args[0].brand = $args[1].brand>>
<<set $args[0].nosePiercing = $args[1].nosePiercing>>
<<set $args[0].eyebrowPiercing = $args[1].eyebrowPiercing>>
<<set $args[0].navelPiercing = $args[1].navelPiercing>>
<<set $args[0].shouldersTat = $args[1].shouldersTat>>
<<set $args[0].armsTat = $args[1].armsTat>>
<<set $args[0].legsTat = $args[1].legsTat>>
<<set $args[0].backTat = $args[1].backTat>>
<<set $args[0].stampTat = $args[1].stampTat>>
<<set $args[0].hormones = $args[1].hormones>>
<<set $args[0].chem = $args[1].chem>>
<<set $args[0].vaginalAttachment = $args[1].vaginalAttachment>>
<<set $args[0].chastityVagina = $args[1].chastityVagina>>
<<set $args[0].chastityPenis = $args[1].chastityPenis>>
<<set $args[0].chastityAnus = $args[1].chastityAnus>>
<<if (def $args[0].custom) && (def $args[1].custom)>>
	<<set $args[0].custom.tattoo = $args[1].custom.tattoo>>
<</if>>
<<set $args[0].bellyTat = $args[1].bellyTat>>
<<set $args[0].abortionTat = $args[1].abortionTat>>
<<set $args[0].birthsTat = $args[1].birthsTat>>
<<set $args[0].pubertyAgeXX = $args[1].pubertyAgeXX>>
<<set $args[0].pubertyXX = $args[1].pubertyXX>>
<<set $args[0].pubertyAgeXY = $args[1].pubertyAgeXY>>
<<set $args[0].pubertyXY = $args[1].pubertyXY>>
<<set $args[0].breedingMark = $args[1].breedingMark>>
<<set $args[0].underArmHColor = $args[1].underArmHColor>>
<<set $args[0].underArmHStyle = $args[1].underArmHStyle>>
<<set $args[0].counter.publicUse = $args[1].counter.publicUse>>
<<set $args[0].ballType = $args[1].ballType>>
<<set $args[0].eggType = $args[1].eggType>>
<<set $args[0].bald = $args[1].bald>>
<<set $args[0].hormoneBalance = $args[1].hormoneBalance>>
<<set $args[0].breastMesh = $args[1].breastMesh>>
<<set $args[0].vasectomy = $args[1].vasectomy>>
<<set $args[0].haircuts = $args[1].haircuts>>
<<set $args[0].ovaryAge = $args[1].ovaryAge>>
<<set $args[0].readyOva = $args[1].readyOva>>
<<set $args[0].womb = $args[1].womb>> /* this is array assigned by reference, if slave body that is $args[1] will be still used anywhere in code (not discarded) — it's WRONG (they now technically share one womb object). Please tell me about it then. But if old body $args[1] just discarded — it's no problem then.*/
<<set $args[0].counter.laborCount = $args[1].counter.laborCount>>
<<set $args[0].pregAdaptation = $args[1].pregAdaptation>>
<<set $args[0].geneMods = $args[1].geneMods>>
<<set $args[0].NCSyouthening = $args[1].NCSyouthening>>
<<set $args[0].eyebrowHColor = $args[1].eyebrowHColor>>
<<set $args[0].eyebrowHStyle = $args[1].eyebrowHStyle>>
<<set $args[0].eyebrowFullness = $args[1].eyebrowFullness>>
<<set $args[0].wombImplant = $args[1].wombImplant>>
<<set $args[0].ovaImplant = $args[1].ovaImplant>>
<<set $args[0].geneticQuirks = $args[1].geneticQuirks>>
<<set $args[0].albinismOverride = $args[1].albinismOverride>>
<<set $args[0].clone = $args[1].clone>>
<<set $args[0].cloneID = $args[1].cloneID>>
<<set $args[0].inbreedingCoeff = $args[1].inbreedingCoeff>>

<<set $args[0].canRecruit = 0>>

<<if $args[2] != 1>> /* swapping NOT gene pool records */
	<<set $args[0].porn = $args[1].porn>>
	<<set $args[0].aphrodisiacs = $args[1].aphrodisiacs>>
	<<set $args[0].curatives = $args[1].curatives>>
	<<set $args[0].drugs = $args[1].drugs>>
	<<set $args[0].prestige = $args[1].prestige>>
	<<set $args[0].porn.viewerCount = $args[1].porn.viewerCount>>
	<<set $args[0].porn.prestige = $args[1].porn.prestige>>
	<<set $args[0].porn.prestigeDesc = $args[1].porn.prestigeDesc>>
	<<set $args[0].prestigeDesc = $args[1].prestigeDesc>>
	<<set $args[0].minorInjury = $args[1].minorInjury>>
	<<set $args[0].eyewear = $args[1].eyewear>>
	<<set $args[0].earwear = $args[1].earwear>>
	<<set $args[0].earsPiercing = $args[1].earsPiercing>>
	<<set $args[0].armAccessory = $args[1].armAccessory>>
	<<set $args[0].legAccessory = $args[1].legAccessory>>
	<<set $args[0].bellyAccessory = $args[1].bellyAccessory>>
	<<set $args[0].preg = $args[1].preg>>
	<<set $args[0].pregSource = $args[1].pregSource>>
	<<set $args[0].pregType = $args[1].pregType>>
	<<set $args[0].labor = $args[1].labor>>
	<<set $args[0].clitSetting = $args[1].clitSetting>>
	<<set $args[0].diet = $args[1].diet>>
	<<set $args[0].dietCum = $args[1].dietCum>>
	<<set $args[0].dietMilk = $args[1].dietMilk>>
	<<set $args[0].clothes = $args[1].clothes>>
	<<set $args[0].collar = $args[1].collar>>
	<<set $args[0].faceAccessory  = $args[1].faceAccessory>>
	<<set $args[0].mouthAccessory  = $args[1].mouthAccessory>>
	<<set $args[0].shoes = $args[1].shoes>>
	<<set $args[0].makeup = $args[1].makeup>>
	<<set $args[0].nails = $args[1].nails>>
	<<set $args[0].vaginalAccessory = $args[1].vaginalAccessory>>
	<<set $args[0].dickAccessory = $args[1].dickAccessory>>
	<<set $args[0].buttplug = $args[1].buttplug>>
	<<set $args[0].buttplugAttachment = $args[1].buttplugAttachment>>
	<<set $args[0].induce = $args[1].induce>>
	<<set $args[0].mpreg = $args[1].mpreg>>
	<<set $args[0].pregKnown = $args[1].pregKnown>>
	<<set $args[0].pregWeek = $args[1].pregWeek>>
	<<set $args[0].belly = $args[1].belly>>
	<<set $args[0].bellyPreg = $args[1].bellyPreg>>
	<<set $args[0].bellyFluid = $args[1].bellyFluid>>
	<<set $args[0].bellyImplant = $args[1].bellyImplant>>
	<<set $args[0].bellySag = $args[1].bellySag>>
	<<set $args[0].bellySagPreg = $args[1].bellySagPreg>>
	<<set $args[0].bellyPain = $args[1].bellyPain>>
	<<set $args[0].cervixImplant = $args[1].cervixImplant>>
	<<set $args[0].scar = $args[1].scar>>
	<<set $args[0].pregControl = $args[1].pregControl>>
	<<run deflate($args[0])>>
<</if>>
/*
<<if def $args[2]>>
	<<= assignJob($args[0], "rest")>>
<</if>>
*/

<</widget>>

<<widget "BodySwapName">>

<<if $args[1].bodySwap == 0>>
	<<if $args[1].birthSurname>>
		<<if $args[1].birthName !== "">>
			<<set $args[0].origBodyOwner = SlaveFullBirthName($args[1])>>
		<<else>>
			<<set $args[0].origBodyOwner = $args[1].slaveName + " " + $args[1].birthSurname>>
		<</if>>
	<<elseif $args[1].birthName>>
		<<if $args[1].slaveSurname>>
			<<if (($surnameOrder != 1 && ["Cambodian", "Chinese", "Hungarian", "Japanese", "Korean", "Mongolian", "Taiwanese", "Vietnamese"].includes($args[1].nationality)) || ($surnameOrder == 2)>>
				<<set $args[0].origBodyOwner = $args[1].slaveSurname + " " + $args[1].birthName>>
			<<else>>
				<<set $args[0].origBodyOwner = $args[1].birthName + " " + $args[1].slaveSurname>>
			<</if>>
		<<else>>
			<<set $args[0].origBodyOwner = $args[1].birthName>>
		<</if>>
	<<elseif $args[1].slaveSurname>>
		<<set $args[0].origBodyOwner = SlaveFullName($args[1])>>
	<<else>>
		<<set $args[0].origBodyOwner = $args[1].slaveName>>
	<</if>>
<<else>>
	<<set $args[0].origBodyOwner = $args[1].origBodyOwner>>
<</if>>

<</widget>>

repo_name: NovX/fc

license: mit


code:
:: death widgets [widget nobr]

<<widget "pop">>

	/* 000-250-006 */
	<<if $seeImages && $seeReportImages>>

			<<= SlaveArt($args[0], 0, 0)>>

	<</if>>
	/* 000-250-006 */
	As $args[0].slaveName is going about $his business with $his overfilled $args[0].inflationType belly, $he can't help but feel exhausted. $His health has been poor lately and the pressure in $his organs is not helping things. $He immediately knows something is wrong when an intense pain runs through $his middle and $his load shifts threateningly. Blood and $args[0].inflationType leak from $his rear as $his body cavity fills with the contents of $his digestive tract. The skin of $his taut belly reddens as the pressure against it builds. As $he takes $his last breath, $he falls forward, $his weight landing upon $his straining stomach. With a gush, $he ruptures, flooding the area around $him with blood, guts and $args[0].inflationType. Word of the late slave and $his gruesome fate spread fast, @@.gold;terrifying@@ your untrusting slaves.
	<<for _dw = 0; _dw < $slaves.length; _dw++>>
		<<if ($slaves[_dw].trust <= 50)>>
			<<if ($slaves[_dw].inflation >= 0)>>
				<<set $slaves[_dw].trust -= (Math.pow($slaves[_dw].inflation,3)*5)>>
			<<else>>
				<<set $slaves[_dw].trust -= 10>>
			<</if>>
		<</if>>
	<</for>>
<</widget>>

<<widget "DeathOldAge">>
	/* 000-250-006 */
	<<if $seeImages && $seeReportImages>>

			<<= SlaveArt($args[0], 0, 0)>>

	<</if>>
	/* 000-250-006 */
	<<setLocalPronouns $args[0]>>
	<<if $args[0].assignment == "be confined in the arcade">>
		You are notified by $arcadeName staff that one of the cabinets has broken down and will need to be replaced. It would seem ''@@.pink;$args[0].slaveName@@'', the fucktoy encased in it, died <<if $args[0].physicalAge >= 70>>naturally of old age despite<<else>>suddenly, unrelated to<</if>> $his living conditions. $He was a good unit; logs show $he was taking dick up until the very end.
	<<elseif $args[0].assignment == "work in the dairy" && $dairyRestraintsSetting > 1>>
		You are notified by $dairyName staff that one of the occupied milkers has ceased producing. Upon inspection, it would seem ''@@.pink;$args[0].slaveName@@'', the cow restrained in it, died <<if $args[0].physicalAge >= 70>>naturally of old age despite<<else>>suddenly, unrelated to<</if>> $his living conditions. $He was a good cow; $he gave milk up until $his death.
	<<elseif $args[0].fuckdoll > 0>>
		One of your Fuckdolls' monitoring systems alerts you that the slave contained within has died. It would seem ''@@.pink;$args[0].slaveName@@'' has died <<if $args[0].physicalAge >= 70>>naturally of old age despite<<else>>suddenly, unrelated to<</if>> $his living conditions. Thankfully the suit notifies its owner of such things; especially with the rumors of earlier models and necrophilia you hear occasionally.
	<<else>>
		''@@.pink;$args[0].slaveName@@'' failed to report in for a routine inspection, something that rarely occurs under your watch. It doesn't take long to track down the wayward slave.
		<<set _deathSeed = random(1,100)>>
		<<if _deathSeed > 75>>
			$He is found dead in $his bed, having died sometime during the previous night.
		<<elseif _deathSeed > 50>>
			$He is found dead in a stairwell, having had a heart attack while trying to climb it.
		<<elseif _deathSeed > 25>>
			$He is found dead in the showers, having slipped sometime earlier.
		<<else>>
			<<if App.Utils.hasNonassignmentSex($args[0])>>
				$He is found dead in the bed of another slave, having died during intercourse. $His lover is not taking it well.
			<<else>>
				$He is found dead in the cafeteria, having died during breakfast; $he ruined the day for a number of your slaves.
			<</if>>
		<</if>>
		$args[0].slaveName died at the age of $args[0].actualAge;
		<<if $args[0].actualAge < 10>>
			$he lived a tragically short life.
		<<elseif $args[0].actualAge < 20>>
			$he died far too young.
		<<elseif $args[0].actualAge < 30>>
			$he died in what would be a sex slave's prime.
		<<elseif $args[0].actualAge < 50>>
			$he died in $his prime.
		<<elseif $args[0].actualAge < 65>>
			$he lived a fair life, good or bad.
		<<elseif $args[0].actualAge < 90>>
			$he lived a long life and experienced much during it.
		<<else>>
			$he lived a very long life that few get to see.
		<</if>>
	<</if>>
<</widget>>

<<widget "DeathOverdose">>
	<<setLocalPronouns $args[0]>>
	/* 000-250-006 */
	<<if $seeImages && $seeReportImages>>

			<<= SlaveArt($args[0], 0, 0)>>

	<</if>>
	/* 000-250-006 */
	<<if $args[0].assignment == "be confined in the arcade">>
		You are notified by $arcadeName staff that one of the cabinets has broken down and will need to be replaced. It would seem ''@@.pink;$args[0].slaveName@@'', the fucktoy encased in it, died of an aphrodisiac overdose from the constant aphrodisiac injections. $He was a good unit; logs show $he was taking dick up until the very end.
	<<elseif $args[0].assignment == "work in the dairy" && $dairyRestraintsSetting > 1>>
		You are notified by $dairyName staff that one of the occupied milkers has ceased producing. Upon inspection, it would seem ''@@.pink;$args[0].slaveName@@'', the cow restrained in it, died of an aphrodisiac overdose. How $he managed to get them is unknown, but $he was a good cow; $he gave milk up until $his death.
	<<elseif $args[0].fuckdoll > 0>>
		One of your Fuckdolls' monitoring systems alerts you that the slave contained within has died. It would seem ''@@.pink;$args[0].slaveName@@'' has died of an aphrodisiac overdose. Thankfully the suit notifies its owner of such things; especially with the rumors of earlier models and necrophilia you hear occasionally. It does little to deal with the resulting mess of the orgasm $he died during, however.
	<<else>>
		''@@.pink;$args[0].slaveName@@'' failed to report in for a routine inspection, something that rarely occurs under your watch. It doesn't take long to track down the wayward slave.
		$He is found dead in $his bed, having died sometime earlier. Judging by the mess and the expression on $his face, $he died of a heart attack during a particularly intense orgasm bought about by the massive amount of aphrodisiacs in $his system. $args[0].slaveName died at the age of $args[0].actualAge;
		<<if $args[0].actualAge < 10>>
			$he lived a tragically short life.
		<<elseif $args[0].actualAge < 20>>
			$he died far too young.
		<<elseif $args[0].actualAge < 30>>
			$he died in what would be a sex slave's prime.
		<<elseif $args[0].actualAge < 50>>
			$he died in $his prime.
		<<elseif $args[0].actualAge < 65>>
			$he lived a fair life, good or bad.
		<<elseif $args[0].actualAge < 90>>
			$he lived a long life and experienced much during it.
		<<else>>
			$he lived a very long life that few get to see.
		<</if>>
	<</if>>
<</widget>>

<<widget "DeathUnhealthy">>
	/* 000-250-006 */
	<<if $seeImages && $seeReportImages>>

			<<= SlaveArt($args[0], 0, 0)>>

	<</if>>
	/* 000-250-006 */
	<<setLocalPronouns $args[0]>>
	<<if $args[0].assignment == "be confined in the arcade">>
		You are notified by $arcadeName staff that one of the cabinets has broken down and will need to be replaced. It would seem ''@@.pink;$args[0].slaveName@@'', the fucktoy encased in it, died to poor health caused by $his living conditions. $He was a good unit; logs show $he was taking dick up until the very end.
	<<elseif $args[0].assignment == "work in the dairy" && $dairyRestraintsSetting > 1>>
		You are notified by $dairyName staff that one of the occupied milkers has ceased producing. Upon inspection, it would seem ''@@.pink;$args[0].slaveName@@'', the cow restrained in it, died to poor health caused by $his living conditions. $He was a good cow; $he gave milk up until $his death.
	<<elseif $args[0].fuckdoll > 0>>
		One of your Fuckdolls' monitoring systems alerts you that the slave contained within has died. It would seem ''@@.pink;$args[0].slaveName@@'' has died of general poor health. Thankfully the suit notifies its owner of such things; especially with the rumors of earlier models and necrophilia you hear occasionally. Clean up is easy enough, however.
	<<else>>
		''@@.pink;$args[0].slaveName@@'' failed to report in for a routine inspection, something that rarely occurs under your watch. It doesn't take long to track down the wayward slave.
		$He is found dead in $his bed, having died sometime during the night. $He has been in very poor health lately, so you knew this was a possibility. $args[0].slaveName died at the age of $args[0].actualAge;
		<<if $args[0].actualAge < 10>>
			$he lived a tragically short life.
		<<elseif $args[0].actualAge < 20>>
			$he died far too young.
		<<elseif $args[0].actualAge < 30>>
			$he died in what would be a sex slave's prime.
		<<elseif $args[0].actualAge < 50>>
			$he died in $his prime.
		<<elseif $args[0].actualAge < 65>>
			$he lived a fair life, good or bad.
		<<elseif $args[0].actualAge < 90>>
			$he lived a long life and experienced much during it.
		<<else>>
			$he lived a very long life that few get to see.
		<</if>>
		<<if ($arcologies[0].FSPaternalist != "unset") && ($args[0].actualAge < 75)>>
			Allowing a slave to die under your care @@.red;severely damages@@ your image as a caring slaveowner and @@.red;calls into question@@ your paternalistic resolve.
			<<= FutureSocieties.Change("Paternalist", -10)>>
		<</if>>
	<</if>>
<</widget>>

<<widget "DeathPregnancyBurst">>
<</widget>>


code:
:: pregmod widgets [nobr widget]

<<widget "setLocalPronouns">>
/*
	"He has a camera. The camera belongs to him. It is his camera. The camera is his."
	"She has a diamond ring. The diamond ring belongs to her. It is her diamond ring. The diamond ring is hers."

	Pronouns are tricky to get right, and this widget should make it easier to use variables naturally in writing. There are two problems in English pronouns that matter here:

	1. Her/her vs his/him. To solve this ambiguity, variables use male pronouns throughout, although players will of course see the contents of the variable. "$He glared" can be printed as "She glared."

	2. Her/hers vs his/his. Here, the opposite problem. In this one case and this alone, where you would use "hers," (the possessive pronoun) the variable is female, since the distinction is only important there. I am very sorry for English.
*/
	<<run App.Utils.setLocalPronouns($args[0], $args[1])>>
<</widget>>

<<widget "setNonlocalPronouns">>
	/* a fake slave object, we need the .pronoun attribute only */
	<<set _fSlave = {pronoun: App.Data.Pronouns.Kind.female}>>
	/* Used for generic slaves, citizens, security, etc. */
	<<if $diversePronouns == 1>>
		<<if $args[0] === 100>>
			<<set _fSlave.pronoun = App.Data.Pronouns.Kind.male>>
		<<elseif ($args[0] > 0) && (random(1,100) <= $args[0])>>
			<<set _fSlave.pronoun = App.Data.Pronouns.Kind.male>>
		<</if>>
	<</if>>
	<<run App.Utils.setLocalPronouns(_fSlave, 'U')>>
<</widget>>

<<widget "setPlayerPronouns">>
	<<set _pl = ["he", "his", "hers", "him", "himself", "woman", "women", "loli", "girl", "daughter", "sister", "wife", "wives",
		"He", "His", "Hers", "Him", "Himself", "Woman", "Women", "Loli", "Girl", "Daughter", "Sister", "Wife", "Wives"]>>
	<<run App.Utils.setLocalPronouns($PC, 'P', _pl)>>
	<<unset _pl>>
<</widget>>

<<widget "setAssistantPronouns">>
	<<set _apl = ["he", "his", "hers", "him", "himself", "woman", "women", "loli", "girl", "daughter", "sister", "wife", "wives",
		"He", "His", "Hers", "Him", "Himself", "Woman", "Women", "Loli", "Girl", "Daughter", "Sister", "Wife", "Wives"]>>

	<<run App.Utils.setLocalPronouns(assistant.pronouns().main, 'A', _apl)>>
	<<if $assistant.market>>
		<<run App.Utils.setLocalPronouns(assistant.pronouns().market, 'M', _apl)>>
	<</if>>
	<<unset _apl>>
<</widget>>

/*
	Should be called with two slave objects as arguments, the primary and secondary. E.g. <<setSpokenLocalPronouns $activeSlave $subSlave>>
	_primarySlaveLisp and _secondarySlaveLisp only exist so that we don't have to rely on using the exact variables $activeSlave and $subSlave
*/
<<widget "setSpokenLocalPronouns">>
	<<set _primarySlaveLisp = SlaveStatsChecker.checkForLisp($args[0])>>

	<<set _heLisp = lispReplace($he)>>
	<<set _hisLisp = lispReplace($his)>>
	<<set _hersLisp = lispReplace($hers)>>
	<<set _himselfLisp = lispReplace($himself)>>
	<<set _daughterLisp = lispReplace($daughter)>>
	<<set _sisterLisp = lispReplace($sister)>>
	<<set _loliLisp = lispReplace($loli)>>
	<<set _wifeLisp = lispReplace($wife)>>
	<<set _wivesLisp = lispReplace($wives)>>

	<<set _HeLisp = lispReplace($He)>>
	<<set _HisLisp = lispReplace($His)>>
	<<set _HersLisp = lispReplace($Hers)>>
	<<set _HimselfLisp = lispReplace($Himself)>>
	<<set _DaughterLisp = lispReplace($Daughter)>>
	<<set _SisterLisp = lispReplace($Sister)>>
	<<set _LoliLisp = lispReplace($Loli)>>
	<<set _WifeLisp = lispReplace($Wife)>>
	<<set _WivesLisp = lispReplace($Wives)>>

	<<if def _he2>>
		<<set _secondarySlaveLisp = SlaveStatsChecker.checkForLisp($args[1])>>

		<<set _he2Lisp = lispReplace(_he2)>>
		<<set _his2Lisp = lispReplace(_his2)>>
		<<set _hers2Lisp = lispReplace(_hers2)>>
		<<set _himself2Lisp = lispReplace(_himself2)>>
		<<set _daughter2Lisp = lispReplace(_daughter2)>>
		<<set _sister2Lisp = lispReplace(_sister2)>>
		<<set _loli2Lisp = lispReplace(_loli2)>>
		<<set _wife2Lisp = lispReplace(_wife2)>>
		<<set _wives2Lisp = lispReplace(_wives2)>>

		<<set _He2Lisp = lispReplace(_He2)>>
		<<set _His2Lisp = lispReplace(_His2)>>
		<<set _Hers2Lisp = lispReplace(_Hers2)>>
		<<set _Himself2Lisp = lispReplace(_Himself2)>>
		<<set _Daughter2Lisp = lispReplace(_Daughter2)>>
		<<set _Sister2Lisp = lispReplace(_Sister2)>>
		<<set _Loli2Lisp = lispReplace(_Loli2)>>
		<<set _Wife2Lisp = lispReplace(_Wife2)>>
		<<set _Wives2Lisp = lispReplace(_Wives2)>>
	<</if>>
<</widget>>

<<widget "setSpokenPlayerPronouns">>
	<<set _playerSlaveLisp = SlaveStatsChecker.checkForLisp($args[0])>>

	<<set _hePLisp = lispReplace(_heP)>>
	<<set _hisPLisp = lispReplace(_hisP)>>
	<<set _hersPLisp = lispReplace(_hersP)>>
	<<set _himselfPLisp = lispReplace(_himselfP)>>
	<<set _daughterPLisp = lispReplace(_daughterP)>>
	<<set _sisterPLisp = lispReplace(_sisterP)>>
	<<set _loliPLisp = lispReplace(_loliP)>>
	<<set _wifePLisp = lispReplace(_wifeP)>>
	<<set _wivesPLisp = lispReplace(_wivesP)>>

	<<set _HePLisp = lispReplace(_HeP)>>
	<<set _HisPLisp = lispReplace(_HisP)>>
	<<set _HersPLisp = lispReplace(_HersP)>>
	<<set _HimselfPLisp = lispReplace(_HimselfP)>>
	<<set _DaughterPLisp = lispReplace(_DaughterP)>>
	<<set _SisterPLisp = lispReplace(_SisterP)>>
	<<set _LoliPLisp = lispReplace(_LoliP)>>
	<<set _WifePLisp = lispReplace(_WifeP)>>
	<<set _WivesPLisp = lispReplace(_WivesP)>>
<</widget>>

<<widget "setSpokenAssistantPronouns">>
	<<set _assistantSlaveLisp = SlaveStatsChecker.checkForLisp($args[0])>>

	<<set _heALisp = lispReplace(_heA)>>
	<<set _hisALisp = lispReplace(_hisA)>>
	<<set _hersALisp = lispReplace(_hersA)>>
	<<set _himselfALisp = lispReplace(_himselfA)>>
	<<set _daughterALisp = lispReplace(_daughterA)>>
	<<set _sisterALisp = lispReplace(_sisterA)>>
	<<set _loliALisp = lispReplace(_loliA)>>
	<<set _wifeALisp = lispReplace(_wifeA)>>
	<<set _wivesALisp = lispReplace(_wivesA)>>

	<<set _HeALisp = lispReplace(_HeA)>>
	<<set _HisALisp = lispReplace(_HisA)>>
	<<set _HersALisp = lispReplace(_HersA)>>
	<<set _HimselfALisp = lispReplace(_HimselfA)>>
	<<set _DaughterALisp = lispReplace(_DaughterA)>>
	<<set _SisterALisp = lispReplace(_SisterA)>>
	<<set _LoliALisp = lispReplace(_LoliA)>>
	<<set _WifeALisp = lispReplace(_WifeA)>>
	<<set _WivesALisp = lispReplace(_WivesA)>>
<</widget>>

<<widget "InitStandards">>

<<set $activeStandard = {age: 24, weightMax: 0, weightMin: 0, musclesMin: 0, musclesMax: 0, raceSup: "white", raceSub: "white", boobs: 0, boobsImplant: 0, lactation: 0, hips: 0, hipsImplant: 0, butt: 0, buttImplant: 0, face: 0, faceImplant: 0, lips: 15, lipsImplant: 0, chem: 0, addict: 0, intelligence: 0, intelligenceImplant: 0, bellyImplant: -1, beauty: 0, dick: 0, balls: 0, health: 0, skill: 0, accent: 0, height: 150, energy: 100}>>

<<UpdateStandards>>
<<BreedingStandards>>
<</widget>>

<<widget "UpdateStandards">>
<<if $failedElite > 100>>
	<<set $activeStandard.intelligence = 95>>
	<<set $activeStandard.beauty = 120>>
	<<set $activeStandard.face = 95>>
<<else>>
	<<set $activeStandard.intelligence = 50>>
	<<set $activeStandard.beauty = 100>>
	<<set $activeStandard.face = 40>>
<</if>>
<<if $arcologies[0].FSIntellectualDependency > 20>>
	<<set $activeSlave.energy = 100>>
<<elseif $arcologies[0].FSSlaveProfessionalism > 20>>
	<<if $failedElite > 100>>
		<<set $activeStandard.skill = 500>>
	<<else>>
		<<set $activeStandard.skill = 400>>
	<</if>>
	<<set $activeStandard.accent = 1>>
<</if>>
<<if $arcologies[0].FSPetiteAdmiration > 20>>
	<<set $activeStandard.height = 150>>
<<elseif $arcologies[0].FSStatuesqueGlorification > 20>>
	<<set $activeStandard.height = 185>>
<</if>>
<<set $activeStandard.chem = 20>>
<<set $activeStandard.addict = 0>>
<<if $arcologies[0].FSSupremacist > 20>>
	<<set $activeStandard.raceSup = $arcologies[0].FSSupremacistRace>>
<</if>>
<<if $arcologies[0].FSSubjugationist > 20>>
	<<set $activeStandard.raceSub = $arcologies[0].FSSubjugationistRace>>
<</if>>
<<if $arcologies[0].FSGenderRadicalist > 20>>
	<<set $activeStandard.dick = 1>>
	<<set $activeStandard.balls = 1>>
<<elseif $arcologies[0].FSGenderFundamentalist > 20>>
	<<set $activeStandard.dick = 0>>
	<<set $activeStandard.balls = 0>>
<</if>>
<<if $arcologies[0].FSPaternalist > 20>>
	<<set $activeStandard.intelligenceImplant = 15>>
	<<set $activeStandard.health = 60>>
<<elseif $arcologies[0].FSDegradationist > 20>>
	<<set $activeStandard.intelligenceImplant = 15>>
	<<set $activeStandard.health = 0>>
<</if>>
<<if $arcologies[0].FSSlaveProfessionalism > 20>>
	<<set $activeStandard.intelligenceImplant = 30>>
<</if>>
<<if $arcologies[0].FSBodyPurist > 20>>
	<<if $failedElite > 100>>
		<<set $activeStandard.chem = 0>>
	<<else>>
		<<set $activeStandard.chem = 15>>
	<</if>>
	<<set $activeStandard.boobsImplant = 0>>
	<<set $activeStandard.buttImplant = 0>>
	<<set $activeStandard.lipsImplant = 0>>
	<<set $activeStandard.hipsImplant = 0>>
	<<set $activeStandard.shouldersImplant = 0>>
	<<set $activeStandard.faceImplant = 5>>
	<<set $activeStandard.bellyImplant = -1>>
<<elseif $arcologies[0].FSTransformationFetishist > 20>>
	<<set $activeStandard.chem = 20>>
<</if>>
<<if $arcologies[0].FSSlimnessEnthusiast > 20>>
	<<if $arcologies[0].FSHedonisticDecadence > 20>>
		<<set $activeStandard.weightMax = 30>>
	<<else>>
		<<set $activeStandard.weightMax = 0>>
	<</if>>
	<<set $activeStandard.butt = 2>>
	<<set $activeStandard.boobs = 400>>
<<elseif $arcologies[0].FSAssetExpansionist > 20>>
	<<set $activeStandard.butt = 6>>
	<<set $activeStandard.boobs = 1000>>
<</if>>
<<if $arcologies[0].FSPastoralist > 20>>
	<<set $activeStandard.lactation = 1>>
<</if>>
<<if $arcologies[0].FSPhysicalIdealist > 20>>
	<<if $arcologies[0].FSPhysicalIdealistLaw == 1>>
		<<set $activeStandard.weightMax = 30>>
		<<set $activeStandard.musclesMin = 20>>
		<<set $activeStandard.musclesMax = 50>>
	<<else>>
		<<set $activeStandard.musclesMin = 95>>
	<</if>>
<<elseif $arcologies[0].FSHedonisticDecadence > 20>>
	<<if $arcologies[0].FSSlimnessEnthusiast > 20>>
		<<set $activeStandard.weightMin = 10>>
	<<else>>
		<<set $activeStandard.weightMin = 95>>
	<</if>>
<</if>>
<</widget>>

<<widget "BreedingStandards">>

In order to be eligible to be bred, the potential breeding bitch must first satisfy the following conditions:
<<if $failedElite > 100>>

She must be of finest intelligence.

She must be unbelievably beautiful.

Her face must be breathtaking.
<<else>>

She must be very smart.

She must be beautiful.

Her face must be gorgeous.
<</if>>

Her health must not be overly impacted by drug use.

She must not be addicted to drugs.
<<if $arcologies[0].FSPetiteAdmiration > 20>>

She must be very short. (150cm)

She must be very short for her age.

She must not have had height altering surgery to reach it.
<<elseif $arcologies[0].FSStatuesqueGlorification > 20>>

She must be very tall. (186cm)

She must not have had height altering surgery to reach it.
<</if>>
<<if $arcologies[0].FSSupremacist > 20>>

She must be $arcologies[0].FSSupremacistRace.
<</if>>
<<if $arcologies[0].FSSubjugationist > 20>>

She must not be $arcologies[0].FSSubjugationistRace.
<</if>>
<<if $arcologies[0].FSGenderRadicalist > 20>>

She must have a functional penis.
<<elseif $arcologies[0].FSGenderFundamentalist > 20>>

She must be physically female.
<</if>>
<<if $arcologies[0].FSPaternalist > 20>>
	<<if $arcologies[0].FSSlaveProfessionalism > 20>>

She must be well educated.
	<<else>>

She must be educated.
	<</if>>

She must be in good health.
<<elseif $arcologies[0].FSSlaveProfessionalism > 20>>

She must be well educated.
<</if>>
<<if $arcologies[0].FSIntellectualDependency > 20>>

She must be sexually receptive at all times.
<<elseif $arcologies[0].FSSlaveProfessionalism > 20>>

She must be capable of mastering her skills.

She must be capable of eloquent and accurate speech.
<</if>>
<<if $arcologies[0].FSBodyPurist > 20>>

She must have low carcinogen levels.

She must be implant free.
<</if>>
<<if $arcologies[0].FSMaturityPreferentialist > 20>>

She must be older than 24.
<<elseif $arcologies[0].FSYouthPreferentialist > 20>>

She must be younger than 24.
<</if>>
<<if $arcologies[0].FSSlimnessEnthusiast > 20>>
	<<if $arcologies[0].FSHedonisticDecadence > 20>>

She may be no larger than "plush".
	<<else>>

She must be thin.
	<</if>>

She must have a trim rear.

She must have a sleek chest.
<<elseif $arcologies[0].FSAssetExpansionist > 20>>

She must have a naturally gigantic rear.

She must be naturally busty.
<</if>>
<<if $arcologies[0].FSPastoralist > 20>>

She must be lactating naturally.
<</if>>
<<if $arcologies[0].FSPhysicalIdealist > 20>>
	<<if $arcologies[0].FSPhysicalIdealistLaw == 1>>

She must not be overweight.

She must be fit, but not too muscular.
	<<else>>

She must be extremely muscular.
	<</if>>

<<elseif $arcologies[0].FSHedonisticDecadence > 20>>
	<<if $arcologies[0].FSSlimnessEnthusiast > 20>>

She must be more than "trim".
	<<else>>

She must be big, soft and fat.
	<</if>>
<</if>>

For each slave examined, a fee of @@.yellowgreen;<<print cashFormat(5000)>>@@ will be deducted from your account.

Failures will be sterilized. Please make sure your slave fits the criteria before submitting them for testing. We shall not be held responsible for time wasted.

Updates will be posted periodically. It is your responsibility to keep up to date with current standards.
<</widget>>

<<widget "BreedingEligibility">>
<<set _passing = 0>>

$activeSlave.slaveName is up for review:
<<if $activeSlave.intelligence+$activeSlave.intelligenceImplant >= $activeStandard.intelligence>>

$He @@.lime;PASSED@@ the intelligence test.
<<else>>

$He @@.red;FAILED@@ the intelligence test.
	<<set _passing-->>
<</if>>
<<if Beauty($activeSlave) >= $activeStandard.beauty>>

$He @@.lime;PASSED@@ the beauty test.
<<else>>

$He @@.red;FAILED@@ the beauty test.
	<<set _passing-->>
<</if>>
<<if $activeSlave.face >= $activeStandard.face>>

$He @@.lime;PASSED@@ the facial attractiveness test.
<<else>>

$He @@.red;FAILED@@ the facial attractiveness test.
	<<set _passing-->>
<</if>>
<<if $activeSlave.chem <= $activeStandard.chem>>

$He @@.lime;PASSED@@ the carcinogen test.
<<else>>

$He @@.red;FAILED@@ the carcinogen test.
	<<set _passing-->>
<</if>>
<<if $activeSlave.addict <= $activeStandard.addict>>

$He @@.lime;PASSED@@ the drug test.
<<else>>

$He @@.red;FAILED@@ the drug test.
	<<set _passing-->>
<</if>>
<<if $arcologies[0].FSSupremacist > 20>>
	<<if $activeSlave.race == $activeStandard.raceSup>>

$He @@.lime;PASSED@@ racial testing.
	<<else>>

$He @@.red;FAILED@@ racial testing.
		<<set _passing-->>
	<</if>>
<</if>>
<<if $arcologies[0].FSSubjugationist > 20>>
	<<if $activeSlave.race != $activeStandard.raceSub>>

$He @@.lime;PASSED@@ racial testing.
	<<else>>

$He @@.red;FAILED@@ racial testing.
		<<set _passing-->>
	<</if>>
<</if>>
<<if $arcologies[0].FSPetiteAdmiration > 20>>
	<<if ($activeSlave.height-($activeSlave.heightImplant*10)) < $activeStandard.height>>
		<<if ($activeSlave.height-($activeSlave.heightImplant*10)) < Height.mean($activeSlave)-15>>

$He @@.lime;MET@@ height requirements.
		<<else>>

$He @@.red;FAILED@@ to meet height requirements.
			<<set _passing-->>
		<</if>>
	<<else>>

$He @@.red;FAILED@@ to meet height requirements.
		<<set _passing-->>
	<</if>>
<<elseif $arcologies[0].FSStatuesqueGlorification > 20>>
	<<if ($activeSlave.height-($activeSlave.heightImplant*10)) > $activeStandard.height>>

$He @@.lime;MET@@ height requirements.
	<<else>>

$He @@.red;FAILED@@ to meet height requirements.
		<<set _passing-->>
	<</if>>
<</if>>
<<if $arcologies[0].FSGenderRadicalist > 20>>
	<<if $activeSlave.dick >= $activeStandard.dick && $activeSlave.balls >= $activeStandard.balls>>

$He @@.lime;PASSED@@ penis inspection.
	<<else>>

$He @@.red;FAILED@@ penis inspection.
		<<set _passing-->>
	<</if>>
<<elseif $arcologies[0].FSGenderFundamentalist > 20>>
	<<if $activeSlave.dick == $activeStandard.dick && $activeSlave.balls == $activeStandard.balls>>

$He @@.lime;PASSED@@ genital inspection.
	<<else>>

$He @@.red;FAILED@@ genital inspection.
		<<set _passing-->>
	<</if>>
<</if>>
<<if $arcologies[0].FSPaternalist > 20>>
	<<if $activeSlave.intelligenceImplant >= $activeStandard.intelligenceImplant>>

$He @@.lime;PASSED@@ educational trials.
	<<else>>

$He @@.red;FAILED@@ educational trials.
		<<set _passing-->>
	<</if>>
	<<if $activeSlave.health.condition >= $activeStandard.health>>

$He @@.lime;PASSED@@ health examinations.
	<<else>>

$He @@.red;FAILED@@ health examinations.
		<<set _passing-->>
	<</if>>
<<elseif $arcologies[0].FSSlaveProfessionalism > 20>>
	<<if $activeSlave.intelligenceImplant >= $activeStandard.intelligenceImplant>>

$He @@.lime;PASSED@@ educational trials.
	<<else>>

$He @@.red;FAILED@@ educational trials.
		<<set _passing-->>
	<</if>>
<</if>>
<<if $arcologies[0].FSIntellectualDependency > 20>>
	<<if $activeSlave.energy >= $activeStandard.energy>>

$He @@.lime;PASSED@@ libido testing.
	<<else>>

$He @@.red;FAILED@@ libido testing.
		<<set _passing-->>
	<</if>>
<<elseif $arcologies[0].FSSlaveProfessionalism > 20>>
	<<if $activeSlave.skill.vaginal + $activeSlave.skill.anal + $activeSlave.skill.oral + $activeSlave.skill.entertainment + $activeSlave.skill.whoring >= $activeStandard.skill>>

$He @@.lime;PASSED@@ skill retention trials.
	<<else>>

$He @@.red;FAILED@@ skill retention trials.
		<<set _passing-->>
	<</if>>
	<<if $activeSlave.accent <= $activeStandard.accent>>

$He @@.lime;PASSED@@ $his speech test.
	<<else>>

$He @@.red;FAILED@@ $his speech test.
		<<set _passing-->>
	<</if>>
<</if>>
<<if $arcologies[0].FSBodyPurist > 20>>
	<<if $activeSlave.chem <= $activeStandard.chem>>

$He @@.lime;PASSED@@ health examinations.
	<<else>>

$He @@.red;FAILED@@ health examinations.
		<<set _passing-->>
	<</if>>
	<<if $activeSlave.boobsImplant == 0 && $activeSlave.buttImplant == 0 && $activeSlave.lipsImplant == 0 && $activeSlave.hipsImplant == 0 && $activeSlave.shouldersImplant == 0 && $activeSlave.faceImplant <= 5 && $activeSlave.bellyImplant == -1>>

$He @@.lime;PASSED@@ implant examinations.
	<<else>>

$He @@.red;FAILED@@ implant examinations.
		<<set _passing-->>
	<</if>>
<</if>>
<<if $arcologies[0].FSMaturityPreferentialist > 20>>
	<<if $activeSlave.physicalAge > $activeStandard.age>>

$He @@.lime;PASSED@@ age examinations.
	<<else>>

$He @@.red;FAILED@@ age examinations.
		<<set _passing-->>
	<</if>>
<<elseif $arcologies[0].FSYouthPreferentialist > 20>>
	<<if $activeSlave.physicalAge < $activeStandard.age>>

$He @@.lime;PASSED@@ age examinations.
	<<else>>

$He @@.red;FAILED@@ age examinations.
		<<set _passing-->>
	<</if>>
<</if>>
<<if $arcologies[0].FSSlimnessEnthusiast > 20>>
	<<if $activeSlave.weight <= $activeStandard.weightMax>>

$He @@.lime;MET@@ weight limits.
	<<else>>

$He @@.red;EXCEEDED@@ weight limits.
		<<set _passing-->>
	<</if>>
	<<if $activeSlave.butt <= $activeStandard.butt>>

$He @@.lime;MET@@ ass measurements.
	<<else>>

$He @@.red;EXCEEDED@@ ass measurements.
		<<set _passing-->>
	<</if>>
	<<if $activeSlave.boobs <= $activeStandard.boobs>>

$He @@.lime;MET@@ chest measurements.
	<<else>>

$He @@.red;EXCEEDED@@ chest measurements.
		<<set _passing-->>
	<</if>>
<<elseif $arcologies[0].FSAssetExpansionist > 20>>
	<<if ($activeSlave.butt - $activeSlave.buttImplant) >= $activeStandard.butt>>

$He @@.lime;MET@@ ass measurements.
	<<else>>

$He @@.red;FAILED@@ to meet ass measurements.
		<<set _passing-->>
	<</if>>
	<<if ($activeSlave.boobs - $activeSlave.boobsImplant) >= $activeStandard.boobs>>

$He @@.lime;MET@@ chest measurements.
	<<else>>

$He @@.red;FAILED@@ to meet chest measurements.
		<<set _passing-->>
	<</if>>
<</if>>
<<if $arcologies[0].FSPastoralist > 20>>
	<<if $activeSlave.lactation == $activeStandard.lactation>>

$He @@.lime;MET@@ milk production standards.
	<<elseif $activeSlave.lactation > $activeStandard.lactation>>

$He @@.red;EXCEEDED@@ milk production standards.
		<<set _passing-->>
	<<else>>

$He @@.red;FAILED@@ to meet milk production standards.
		<<set _passing-->>
	<</if>>
<</if>>
<<if $arcologies[0].FSPhysicalIdealist > 20>>
	<<if $arcologies[0].FSPhysicalIdealistLaw == 1>>
		<<if $arcologies[0].FSSlimnessEnthusiast > 20>>
			<<if $activeSlave.weight <= $activeStandard.weightMax>>

$He @@.lime;MET@@ weight limits.
			<<else>>

$He @@.red;EXCEEDED@@ weight limits.
				<<set _passing-->>
			<</if>>
		<</if>>
		<<if $activeSlave.muscles > $activeStandard.musclesMin && $activeSlave.muscles < $activeStandard.musclesMax>>

$He @@.lime;MET@@ the required muscle standard.
		<<elseif ($activeSlave.muscles <= $activeStandard.musclesMin && $activeSlave.muscles > $activeStandard.musclesMin-20) || ($activeSlave.muscles >= $activeStandard.musclesMax && $activeSlave.muscles < $activeStandard.musclesMax+30)>>

$He @@.yellow;failed@@ to match the required muscle standard, but was deemed within fixable range.
			<<if _passing == 0>>
				<<set _passing = 2>>
			<</if>>
		<<else>>

$He @@.red;FAILED@@ to match the required muscle standard.
			<<set _passing-->>
		<</if>>
	<<else>>
		<<if $activeSlave.muscles > $activeStandard.musclesMin>>

$He @@.lime;MET@@ the required muscle mass.
		<<else>>

$He @@.red;FAILED@@ to meet the required muscle mass.
			<<set _passing-->>
		<</if>>
	<</if>>
<<elseif $arcologies[0].FSHedonisticDecadence > 20>>
	<<if $activeSlave.weight > $activeStandard.weightMin>>

$He @@.lime;MET@@ the minimum weight limit.
	<<else>>

$He @@.red;failed@@ to meet minimum weight limits.
		<<set _passing-->>
	<</if>>
<</if>>

<<if _passing == 2>>
	The slave known as "<<= SlaveFullName($activeSlave)>>" has been deemed @@.yellow;currently unsuitable@@ for breeding, but may be resubmitted after corrections are applied. We understand the subjective nature of "fit" and do not wish to preclude the use a viable breeder over such a trivial fix. $He has been placed on a contraceptive routine to protect against "accidents" in the interim.
<<elseif _passing != 0>>
	The slave known as "<<= SlaveFullName($activeSlave)>>" has been deemed @@.red;unsuitable@@ for breeding and has been @@.green;sterilized@@ as per agreement.
	<<set $activeSlave.preg = -3>>
<<else>>
	The slave known as "<<= SlaveFullName($activeSlave)>>" has been deemed @@.green;worthy@@ of being used for breeding and has been marked as such. Please note the increased restrictions on breeding slaves.

They are not permitted for public use or anything that may harm their growing child. The child within them is considered a member of the Elite class and as such, any harm that comes to them will result in severe penalties to the breeder's owner. Development of the child will be closely monitored; should the fetus be identified as not of the owner's blood (or any other member of the Elite class), said owner shall face severe fines.
	<<set $activeSlave.breedingMark = 1, $activeSlave.pregControl = "none">>
<</if>>

@@.yellowgreen;<<print cashFormat(5000)>>@@ has been deducted from your account as agreed.
<<= removeJob($activeSlave, $activeSlave.assignment)>>
<</widget>>

<<widget "PlayerRace">>
	<<replace #ethnicity>>
		You're $PC.race.
	<</replace>>
<</widget>>

<<widget "PlayerSkin">>
	<<replace #skin>>
		You have $PC.skin skin.
	<</replace>>
<</widget>>

<<widget "PlayerMarkings">>
	<<replace #markings>>
		<<if $PC.markings == "none">>
			Your skin is pure and clear of any freckles.
		<<elseif $PC.markings == "freckles">>
			You have some freckles on your cheeks and elsewhere.
		<<elseif $PC.markings == "heavily freckled">>
			You have dense freckles on your cheeks and elsewhere.
		<</if>>
	<</replace>>
<</widget>>

<<widget "ParentNames">>
<<set _currentSlaveNames = $slaves.map(s => s.slaveName)>>
<<if $allowMaleSlaveNames>>
	<<set _sanityCheck = '>>', /* to appease sanityCheck */
		$args[1].slaveName = generateName($args[0].nationality, $args[1].race, $args[1].genes === "XY", sn => !_currentSlaveNames.includes(sn))>>
	<<if !$args[1].slaveName>>
		/* we ran out of names ... How? */
		<<set _maxTries = 10>>
		<<for _maxTries > 0 && !$args[1].slaveName>>
			<<set _continentNationality = hashChoice($nationalities)>>
			<<set _sanityCheck = '>>', /* to appease sanityCheck */
				$args[1].slaveName = generateName(_continentNationality, $args[1].race, $args[1].genes === "XY", sn => !_currentSlaveNames.includes(sn))>>
		<</for>>
	<</if>>
	<<if !$args[1].slaveName>>
		/* give up, duplicate name is fine I guess */
		<<set $args[1].slaveName = generateName($args[0].nationality, $args[1].race, $args[1].genes === "XY")>>
	<</if>>
<<else>>
	<<set _sanityCheck = '>>', /* to appease sanityCheck */
		$args[1].slaveName = generateName($args[0].nationality, $args[1].race, false, sn => !_currentSlaveNames.includes(sn))>>
	<<if !$args[1].slaveName>>
		/* we ran out of names ... How? */
		<<set _maxTries = 10>>
		<<for _maxTries > 0 && !$args[1].slaveName>>
			<<set _continentNationality = hashChoice($nationalities)>>
			<<set _sanityCheck = '>>', /* to appease sanityCheck */
				$args[1].slaveName = generateName(_continentNationality, $args[1].race, false, sn => !_currentSlaveNames.includes(sn))>>
		<</for>>
	<</if>>
	<<if !$args[1].slaveName>>
		/* give up, duplicate name is fine I guess */
		<<set $args[1].slaveName = generateName($args[0].nationality, $args[1].race, false)>>
	<</if>>
<</if>>
<<unset _currentSlaveNames, _maxTries, _continentNationality>>
<</widget>>

<<widget "NewChildName">>
<<set $args[0].birthName = generateName($args[0].nationality, $args[0].race, $args[0].genes === "XY")>>
<<if $args[0].genes === "XY" && !$allowMaleSlaveNames && isMaleName($args[0].birthName, $args[0].nationality, $args[0].race)>>
	/* grab a female name for the slave name instead */
	<<set $args[0].slaveName = generateName($args[0].nationality, $args[0].race, false)>>
<<else>>
	<<set $args[0].slaveName = $args[0].birthName>>
<</if>>
<</widget>>

<<widget "AgePCEffects">>
<<switch $PC.actualAge>>
<<case 3>>
	<<set $AgeTrainingLowerBoundPC = 18, $AgeTrainingUpperBoundPC = 20, $AgeEffectOnTrainerPricingPC = .1, $AgeEffectOnTrainerEffectivenessPC = .1>>
<<case 4>>
	<<set $AgeTrainingLowerBoundPC = 17, $AgeTrainingUpperBoundPC = 19, $AgeEffectOnTrainerPricingPC = .15, $AgeEffectOnTrainerEffectivenessPC = .15>>
<<case 5>>
	<<set $AgeTrainingLowerBoundPC = 16, $AgeTrainingUpperBoundPC = 18, $AgeEffectOnTrainerPricingPC = .35, $AgeEffectOnTrainerEffectivenessPC = .35>>
<<case 6>>
	<<set $AgeTrainingLowerBoundPC = 15, $AgeTrainingUpperBoundPC = 17, $AgeEffectOnTrainerPricingPC = .55, $AgeEffectOnTrainerEffectivenessPC = .55>>
<<case 7>>
	<<set $AgeTrainingLowerBoundPC = 14, $AgeTrainingUpperBoundPC = 16, $AgeEffectOnTrainerPricingPC = .75, $AgeEffectOnTrainerEffectivenessPC = .75>>
<<case 8>>
	<<set $AgeTrainingLowerBoundPC = 13, $AgeTrainingUpperBoundPC = 15, $AgeEffectOnTrainerPricingPC = .85, $AgeEffectOnTrainerEffectivenessPC = .85>>
<<case 9>>
	<<set $AgeTrainingLowerBoundPC = 12, $AgeTrainingUpperBoundPC = 14, $AgeEffectOnTrainerPricingPC = 1.00, $AgeEffectOnTrainerEffectivenessPC = 1.00>>
<<case 10>>
	<<set $AgeTrainingLowerBoundPC = 11, $AgeTrainingUpperBoundPC = 13, $AgeEffectOnTrainerPricingPC = 1.0005, $AgeEffectOnTrainerEffectivenessPC = 1.0005>>
<<case 11>>
	<<set $AgeTrainingLowerBoundPC = 10, $AgeTrainingUpperBoundPC = 12, $AgeEffectOnTrainerPricingPC = 1.01, $AgeEffectOnTrainerEffectivenessPC = 1.01>>
<<case 12>>
	<<set $AgeTrainingLowerBoundPC = 9, $AgeTrainingUpperBoundPC = 11, $AgeEffectOnTrainerPricingPC = 1.02, $AgeEffectOnTrainerEffectivenessPC = 1.02>>
<<case 13>>
	<<set $AgeTrainingLowerBoundPC = 8, $AgeTrainingUpperBoundPC = 10, $AgeEffectOnTrainerPricingPC = 1.03, $AgeEffectOnTrainerEffectivenessPC = 1.03>>
<<case 14>>
	<<set $AgeTrainingLowerBoundPC = 7, $AgeTrainingUpperBoundPC = 9, $AgeEffectOnTrainerPricingPC = 1.04, $AgeEffectOnTrainerEffectivenessPC = 1.04>>
<<case 15>>
	<<set $AgeTrainingLowerBoundPC = 6, $AgeTrainingUpperBoundPC = 8, $AgeEffectOnTrainerPricingPC = 1.05, $AgeEffectOnTrainerEffectivenessPC = 1.05>>
<<case 16>>
	<<set $AgeTrainingLowerBoundPC = 5, $AgeTrainingUpperBoundPC = 7, $AgeEffectOnTrainerPricingPC = 1.06, $AgeEffectOnTrainerEffectivenessPC = 1.06>>
<<case 17>>
	<<set $AgeTrainingLowerBoundPC = 4, $AgeTrainingUpperBoundPC = 6, $AgeEffectOnTrainerPricingPC = 1.07, $AgeEffectOnTrainerEffectivenessPC = 1.07>>
<<case 18>>
	<<set $AgeTrainingLowerBoundPC = 3, $AgeTrainingUpperBoundPC = 5, $AgeEffectOnTrainerPricingPC = 1.08, $AgeEffectOnTrainerEffectivenessPC = 1.08>>
<</switch>>
<</widget>>


code:
all .tw passages that are included from other passages via the <<include>> macro should be stored in this folder or its subfolders for organizational purposes

for these included passages, it is not safe to assume that a temporary variable (starting with underscore _ character) will be confined in scope to that file alone

when passages are included by other passages, any variables that they set will override variables in the calling passage, so extra care should be taken in these passages if they use $i, _i, _j or other common variable names to ensure that callers are not expecting those variables to be unchanged after the include

all sa... passages

arcologyDescription
neighborDescription
officeDescription

surgeryDegradation

weekly

	persBusiness
	rulesAssistantReport

penthouse

	fullReport
	penthouseReport

neighbors

	neighborsDevelopment
	neighborsFSAdoption

facilities

	arcadeReport
	brothelReport
	cellblockReport
	clinicReport
	clubReport
	dairyReport
	labReport
	masterSuiteReport
	schoolroomReport
	servantsQuartersReport
	spaReport
	nurseryReport

economics

	corporationDevelopments
	marketsReport

npc

	hgApplication
	lawCompliance
	longSlaveDescription
	newSlaveIntro

init

	initRules
	BackwardsCompatibility