code:
:: The Slavegirl School [nobr]

<<set $nextButton = "Back", $nextLink = "Buy Slaves", $returnTo = "Buy Slaves", $showEncyclopedia = 1, $encyclopedia = "Slave Schools">>
/* Multi-Purchase Support */
<<if ndef $newSlaves>><<set $newSlaves = []>><</if>>
<<if $newSlaves.length > 0>>
	<<set $nextButton = "Continue", $nextLink = "Bulk Slave Intro", $slaveMarket = "TSS", $returnTo = "Main", $newSlaveIndex = 0>>
<</if>>

//The Slavegirl School is the newest slave school operating in the Free Cities. Its business model is to offer simpler, cheaper wares than its competitors. All Slavegirl School graduates are natural-born females without surgical modifications. Their training emphasizes elimination of any serious psychological deformities. They are promptly enslaved and sold as soon as they reach their majorities, and are marketed as complete virgins. <<if $TSS.schoolUpgrade != 0>>

You have endowed <<if $TSS.schoolUpgrade == 1>>an alternative college at The Slavegirl School, which focuses on retraining good MILF stock into mature slave girls.<<else>>an improvement in the simplistic school's approach that teaches good basic skills without losing too much efficiency.<</if>> As a major <<if $PC.title == 0>>benefactrix<<else>>benefactor<</if>> of the institution, you also receive a discount on them.<</if>>//

The Slavegirl School offers a fresh graduate for inspection via video call. The interview takes place in a faculty member's office. Absurdly, it's barely distinguishable from an office at any traditional institution of higher education. The only giveaway is the profusion of sex toys on the desk and the pornography on the walls.

<<= generateMarketSlave("TSS")>>
<<set $slaveCost = slaveCost($activeSlave)>>
<<if $TSS.schoolSale != 0>>
	<<set $slaveCost = Math.trunc($slaveCost*0.5)>>
<<elseif $TSS.schoolUpgrade != 0>>
	<<set $slaveCost = Math.trunc($slaveCost*0.8)>>
<</if>>
<<if $slavesSeen > $slaveMarketLimit>><<set $slaveCost += Math.trunc($slaveCost*(($slavesSeen-$slaveMarketLimit)*0.1))>><</if>>

The price is <<print cashFormat($slaveCost)>>.<<if $slavesSeen > $slaveMarketLimit>> You have cast such a wide net for slaves this week that it is becoming more expensive to find more for sale. Your reputation helps determine your reach within the slave market.<</if>>

<<setLocalPronouns $activeSlave>>
<<buyingFromSchoolControls $TSS "slave" "slaves">>


code:
:: Twins Workaround

Your new pair of slaves look frightened and uncertain, but seem encouraged by each other's presence.

<<run newSlave($activeSlave)>>

<<set _secondSlave = clone($activeSlave)>>
<<unset $activeSlave>>
<<if _secondSlave.slaveSurname>><<set _familyName = _secondSlave.slaveSurname>><</if>>
<<set _familyBirthSurname = _secondSlave.birthSurname>>
<<run nationalityToName(_secondSlave)>>
<<if _familyName>><<set _secondSlave.slaveSurname = _familyName>><</if>>
<<set _secondSlave.birthSurname = _familyBirthSurname>>
<<run nationalityToAccent(_secondSlave)>>

<<set _secondSlave.ID = _secondSlave.ID + 1000>>
<<if $familyTesting == 0>>
	<<set _secondSlave.relation = "twin">>
	<<set _secondSlave.relationTarget = _secondSlave.ID - 1000>>
<</if>>

<<run newSlave(_secondSlave)>>

repo_name: AmbrosiaCheesecake/fc


code:
:: Universal Rules [nobr]

__Universal rules__

<<set $nextButton = "Back">>
<<set $nextLink = "Main">>

<<if $universalRulesRest == 0>>
	Slaves will ''remain on assignment'' when unhealthy. [[Allow automatic rest when unhealthy|Universal Rules][$universalRulesRest = 1]]
<<else>>
	Slaves will ''automatically rest'' at $assistantName's discretion when unhealthy. [[Require all slaves to stay on assignment|Universal Rules][$universalRulesRest = 0]]
<</if>>

<<if $universalRulesConsent == 0>>
	Slaves are ''not required'' to get consent before fucking other slaves. [[Restrain slave on slave molestation|Universal Rules][$universalRulesConsent = 1]]
<<else>>
	Slaves are ''generally required'' to get consent before fucking other slaves. [[Encourage slave on slave molestation|Universal Rules][$universalRulesConsent = 0]]
<</if>>

Slave nicknames are
<<if ($nicknamesAllowed == 0)>>
	@@.red;FORBIDDEN.@@ [[Allow|Universal Rules][$nicknamesAllowed = 1]]
<<else>>
	@@.cyan;ALLOWED.@@ [[Forbid|Universal Rules][$nicknamesAllowed = 0]]
<</if>>

<<if $surnamesForbidden == 0>>

	<<link "Strip all slaves of their surnames, both new and old">>
		<<for _i = 0; _i < $slaves.length; _i++>>
			<<set $slaves[_i].slaveSurname = 0>>
		<</for>>
		<<set $surnamesForbidden = 1>>
		<<replace "#strip">>
			Surnames taken.
		<</replace>>
	<</link>>

<<else>>
	[[Allow future slaves to keep their surnames|Universal Rules][$surnamesForbidden = 0]]
<</if>>

Slave requests for body mods are
<<if ($modRequestsAllowed == 0)>>
	@@.red;FORBIDDEN.@@ [[Allow|Universal Rules][$modRequestsAllowed = 1]]
<<else>>
	@@.cyan;ALLOWED.@@ [[Forbid|Universal Rules][$modRequestsAllowed = 0]]
<</if>>

Slave requests for growth hormones are
<<if ($expansionRequestsAllowed == 0)>>
	@@.red;FORBIDDEN.@@ [[Allow|Universal Rules][$expansionRequestsAllowed = 1]]
<<else>>
	@@.cyan;ALLOWED.@@ [[Forbid|Universal Rules][$expansionRequestsAllowed = 0]]
<</if>>

<<if $FSAnnounced > 0>>

	<<if ($useFSNames == 0)>>
		Future society names for new slaves are currently @@.red;NOT APPLIED.@@ [[Apply|Universal Rules][$useFSNames = 1]]
	<<else>>
		Future society names for new slaves are currently @@.cyan;APPLIED.@@ [[Stop applying|Universal Rules][$useFSNames = 0]]
	<</if>>
<</if>>

<<if $brothel+$club+$dairy+$farmyard+$servantsQuarters+$arcade+$schoolroom+$spa+$nursery+$clinic+$masterSuite+$cellblock > 0>>

	<<if $universalRulesFacilityWork == 0>>
		Slaves ''will not'' cooperate with staffed facilities to improve their performance. [[Allow cooperation|Universal Rules][$universalRulesFacilityWork = 1]]
	<<else>>
		Slaves ''will'' cooperate with staffed facilities to improve their performance. [[Stop cooperation|Universal Rules][$universalRulesFacilityWork = 0]]
	<</if>>
<</if>>

<<if $brothel+$club+$dairy+$farmyard+$servantsQuarters+$arcade+$schoolroom+$spa+$nursery+$clinic+$masterSuite+$cellblock > 0>>

	<<if $universalRulesAssignsSelfFacility == 1>>
		Slaves ''are'' permitted to assign themselves to facilities when choosing their assignment. [[Deny self assignment to facilities|Universal Rules][$universalRulesAssignsSelfFacility = 0]]
	<<else>>
		Slaves ''are not'' permitted to assign themselves to facilities when choosing their assignment. [[Permit self assignment to facilities|Universal Rules][$universalRulesAssignsSelfFacility = 1]]
	<</if>>
<</if>>

<<if $universalRulesNewSlavesRA == 0>>
	The Rules Assistant ''will not apply'' automatically to newly acquired slaves. [[Apply to new slaves|Universal Rules][$universalRulesNewSlavesRA = 1]]
<<else>>
	The Rules Assistant ''will apply'' automatically to newly acquired slaves [[Stop applying to new slaves|Universal Rules][$universalRulesNewSlavesRA = 0]]
<</if>>

<<if $seePreg != 0>>

<<if $universalRulesImpregnation == "HG">>
	<<setLocalPronouns $HeadGirl>>
	Fertile slaves will be ''systematically impregnated by your Head Girl,'' if $he is able to do so. [[Cancel insemination regime|Universal Rules][($universalRulesImpregnation = "none"),($universalHGImpregnateMasterSuiteToggle = 0)]]<<if $PC.dick > 0>> | [[Inseminate them yourself|Universal Rules][($universalRulesImpregnation = "PC"),($universalHGImpregnateMasterSuiteToggle = 0)]]<</if>>

	<<if $universalHGImpregnateMasterSuiteToggle == 1>>
		Your Head Girl, if able, ''is not'' inseminating slaves in the Master Suite. [["Allow "+$him+" to inseminate Master Suite slaves"|Universal Rules][$universalHGImpregnateMasterSuiteToggle = 0]]
	<<else>>
		Your Head Girl, if able, ''is'' inseminating slaves in the Master Suite. [["Forbid "+$him+" from inseminating Master Suite slaves"|Universal Rules][$universalHGImpregnateMasterSuiteToggle = 1]]
	<</if>>
<<elseif $universalRulesImpregnation == "PC">>
	Fertile slaves will be ''systematically impregnated by you.'' [[Cancel insemination regime|Universal Rules][$universalRulesImpregnation = "none"]]<<if $seeDicks != 0>> | [[Delegate insemination to your Head Girl|Universal Rules][$universalRulesImpregnation = "HG"]]<</if>>
<<elseif $seePreg != 0>>
	Fertile slaves will ''not be systematically impregnated.'' <<if $PC.dick > 0>>[[Inseminate them yourself|Universal Rules][$universalRulesImpregnation = "PC"]]<</if>><<if ($PC.dick > 0) && ($seeDicks != 0)>> | <</if>><<if $seeDicks != 0>>[[Delegate insemination to your Head Girl|Universal Rules][$universalRulesImpregnation = "HG"]]<</if>>
<</if>>

<<if $universalRulesBirthing == 1>>
	Heavily pregnant slaves will be ''scanned daily'' for signs of labor and moved to a birthing area immediately if any are detected.
	[[Stop scanning|Universal Rules][$universalRulesBirthing = 0]]
<<else>>
	Heavily pregnant slaves will be ''required to work'' right up until they feel contractions.
	[[Apply daily scanning|Universal Rules][$universalRulesBirthing = 1]]

	//This will increase upkeep costs for these slaves//
<</if>>

<<if $universalRulesCSec == 1>>
	Pregnant slaves will be ''given Caesarean sections'' rather than allowed to give birth naturally in order to minimize health issues and to preserve their vaginas.
	[[Only perform c-sections when necessary|Universal Rules][$universalRulesCSec = 0]]
<<else>>
	Pregnant slaves will ''give birth naturally'' unless health issues pose a threat.
	[[Always perform c-sections|Universal Rules][$universalRulesCSec = 1]]

	//Will lessen medical costs, at the expense of scarring//
<</if>>

Upon birth slave babies will be sent to $DefaultBirthDestination.

You can decide on a new policy:
	<<if $DefaultBirthDestination != "individually decided fates">>
		[[Decide individually|Universal Rules][$DefaultBirthDestination = "individually decided fates",$universalRulesChildrenBecomeBreeders = 0]]
	<</if>>
	<<if $DefaultBirthDestination != "an orphanage">>
		| [[Slave orphanage|Universal Rules][$DefaultBirthDestination = "an orphanage",$universalRulesChildrenBecomeBreeders = 0]]
	<</if>>
	<<if $DefaultBirthDestination != "a citizen school">>
		| [[Citizen school|Universal Rules][$DefaultBirthDestination = "a citizen school",$universalRulesChildrenBecomeBreeders = 0]]
	<</if>>
	<<if $DefaultBirthDestination != "a private school">>
		| [[Private school|Universal Rules][$DefaultBirthDestination = "a private school",$universalRulesChildrenBecomeBreeders = 0]]
	<</if>>
	<<if $Cash4Babies > 0>>
		<<if $DefaultBirthDestination != "the market">>
		| [[Market|Universal Rules][$DefaultBirthDestination = "the market",$universalRulesChildrenBecomeBreeders = 0]]
		<</if>>
	<</if>>
	<<if $arcologies[0].FSRepopulationFocus > 40>>

		<<if $DefaultBirthDestination != "breeder schools">>
			| [[Breeder schools|Universal Rules][$DefaultBirthDestination = "breeder schools",$universalRulesChildrenBecomeBreeders = 1]]
			//Will require a <<print cashFormat(50)>> donation per week once enrollment begins//
		<</if>>
	<</if>>

	//Children reserved for the Incubator or Nursery will not be affected//

<</if>>/*Closes seePreg check*/

<<if $universalRulesImmobileSlavesMaintainMuscles == 1>>
	Immobile slaves ''will maintain'' their muscles rather than allow themselves to become soft.
	[[Stop mandatory workouts|Universal Rules][$universalRulesImmobileSlavesMaintainMuscles = 0]]
<<else>>
	Immobile slaves ''will not maintain'' their musculature and will gradually lose it.
	[[Mandatory workouts|Universal Rules][$universalRulesImmobileSlavesMaintainMuscles = 1]]
<</if>>

<<if $dojo > 0>>

	<<if $bodyguardTrains == 0>>
		Your Bodyguard ''is not allowed'' to train potential successors. [[Allow training|Universal Rules][$bodyguardTrains = 1]]
	<<else>>
		Your Bodyguard ''is allowed'' to train potential successors. [[Stop training|Universal Rules][$bodyguardTrains = 0]]
	<</if>>
<</if>>

<<if $nursery > 0>>

	<<if $nurserySex == 1 && $extremeUnderage == 1>>
		$nurseryNameCaps staff are ''allowed'' to molest the children. [[Forbid|Universal Rules][$nurserySex = 0]]
	<<else>>
		$nurseryNameCaps staff are ''not allowed'' to molest the children. [[Allow|Universal Rules][$nurserySex = 1]]
	<</if>>
<</if>>