code:
:: HG Application [nobr]

<<setLocalPronouns _S.HeadGirl>>
<<setLocalPronouns $activeSlave 2>>

<<if ndef $HGSeverity>>
	<<set $HGSeverity = 0>>
<</if>>

<<set $activeSlave.training = Math.clamp($activeSlave.training, 0, 150)>>
<<set _effectiveness = _S.HeadGirl.actualAge+((_S.HeadGirl.intelligence+_S.HeadGirl.intelligenceImplant)/3)-(_S.HeadGirl.accent*5)+($HGSeverity*10)+(($activeSlave.intelligence+$activeSlave.intelligenceImplant)/4)-($activeSlave.accent*5)>>
<<if $AgePenalty == 0>>
	<<set _effectiveness += Math.max(0,(30-_S.HeadGirl.actualAge))>>
<</if>>
<<if _S.HeadGirl.sexualFlaw == "abusive" && $HGSeverity >= 0>>
	<<set _effectiveness += 10>>
<</if>>
<<if $HGtraining != "health">>
	<<set $activeSlave.health.tired += 25>>
<</if>>

    Your Head Girl _S.HeadGirl.slaveName notices that $activeSlave.slaveName
<<switch $HGtraining>>
<<case "health">>
	is unwell.
<<case "obedience">>
	is disobedient.
<<case "paraphilia">>
	has a paraphilia.
<<case "flaw">>
	has an unpleasant flaw worth fixing.
<<case "soften">>
	has an unpleasant flaw that $he can try to soften into a unique quirk.
<<case "oral skill">>
	isn't as orally skilled as $he is.
<<case "anal skill">>
	isn't as skilled at taking anal as $he is.
<<case "fuck skill">>
	isn't as skilled at vaginal intercourse as $he is.
<<case "whore skill">>
	isn't as skilled at the fine art of sex for money as $he is.
<<case "entertain skill">>
	isn't as skilled at entertainment as $he is.
<</switch>>

<<if $HGtraining == "health">>

$He helps $activeSlave.slaveName however $he can. The tender care has @@.green;improved $activeSlave.slaveName's health.@@
<<run improveCondition($activeSlave, 10)>>
<<set $activeSlave.health.tired = Math.clamp($activeSlave.health.tired-10, 0, 1000)>>
<<set $activeSlave.training = 0>>

<<else>>

<<if _S.HeadGirl.career == "an arcology owner">>
	$He was once an arcology owner $himself, making $him truly peerless as a Head Girl.
	<<set _effectiveness += 50>>
<<elseif setup.HGCareers.includes(_S.HeadGirl.career)>>
	$He was used to giving commands and being obeyed in $his life before $he was a slave, experience $he can call on now.
	<<set _effectiveness += 5>>
<<elseif _S.HeadGirl.skill.headGirl >= $masteredXP>>
	$He is used to giving commands and being obeyed through experience, rendering $him more effective.
	<<set _effectiveness += 5>>
<</if>>

<<if _S.HeadGirl.actualAge > 30>>
	$His age and experience help $him as $he works with $activeSlave.slaveName.
<<elseif _S.HeadGirl.actualAge < 25 && $AgePenalty > 0>>
	$His youth and inexperience impede $him as $he works with $activeSlave.slaveName.
<</if>>

<<if _S.HeadGirl.accent >= 3>>
	$He does $his best to give orders in $language, but has to resort to a lot of unseemly gesticulation and shouting, making $him much less effective.
<<elseif _S.HeadGirl.accent == 2>>
	$His heavy <<print aNational(_S.HeadGirl.nationality)>> accent impedes $his clarity in $language, making $him somewhat less effective.
<</if>>

<<if ($HGtraining == "obedience") || ($HGtraining == "flaw") || ($HGtraining == "soften")>>
	<<if _S.HeadGirl.intelligence+_S.HeadGirl.intelligenceImplant > 50>>
		<<if $activeSlave.intelligence+$activeSlave.intelligenceImplant > 50>>
			$He needs $his wits about $him to mold $activeSlave.slaveName, who's quite intelligent _himself2.
		<<elseif $activeSlave.intelligence+$activeSlave.intelligenceImplant >= -50>>
			$His intelligence helps $him mold $activeSlave.slaveName.
		<<else>>
			Molding $activeSlave.slaveName is very easy, especially for a smart Head Girl like $him.
		<</if>>
	<</if>>
<<else>>
	<<if _S.HeadGirl.intelligence+_S.HeadGirl.intelligenceImplant > 50>>
		<<if $activeSlave.intelligence+$activeSlave.intelligenceImplant > 50>>
			Both slaves are quite intelligent, making $his job much easier.
		<<elseif $activeSlave.intelligence+$activeSlave.intelligenceImplant >= -50>>
			$He's quite intelligent and can teach $activeSlave.slaveName well.
		<<else>>
			$He needs all $his considerable intelligence to get through to the idiot $he has to teach.
		<</if>>
	<</if>>
<</if>>

<<if $HGSeverity > 0>>
	Your directives encourage $him to rape any slave that fails in the slightest way, a task $he approaches
	<<if _S.HeadGirl.sexualFlaw == "abusive">>
		eagerly, since $he prefers to take $his pleasure without consent.
	<<elseif _S.HeadGirl.fetish == "sadist">>
		with sadistic enthusiasm.
	<<elseif _S.HeadGirl.fetish == "dom">>
		with confidence.
	<<elseif _S.HeadGirl.energy > 95>>
		as a convenient way to
		<<if (_S.HeadGirl.balls > 0)>>
			drain $his perpetually overfilled balls into a series of spasming holes.
		<<else>>
			sate $his excess sexual appetite.
		<</if>>
	<<else>>
		dutifully.
	<</if>>
	<<if $activeSlave.vagina == 0>>
		In $activeSlave.slaveName's case, $he's careful to limit _his2 sexual abuse to things that won't take the _girl2's virginity. The slave
	<<elseif $activeSlave.anus == 0>>
		$He's careful to molest $activeSlave.slaveName in ways that don't involve penetrating _his2 virgin ass. The slave
	<<else>>
		$activeSlave.slaveName
	<</if>>
	<<if $activeSlave.devotion > 50>>
		accepts the abuse, believing _he2 deserves to be raped.
	<<elseif $activeSlave.devotion >= -20>>
		is @@.gold;frightened@@ by the unceasing abuse.
		<<set $activeSlave.trust -= 1>>
	<<else>>
		@@.mediumorchid;hates@@ and @@.gold;fears@@ the constant abuse.
		<<set $activeSlave.trust -= 1>>
		<<set $activeSlave.devotion -= 1>>
	<</if>>
	_S.HeadGirl.slaveName makes sure $his victim hates it, every time, and $activeSlave.slaveName can't help but do _his2 very best to avoid this treatment.
<<elseif $HGSeverity == 0>>
	You allow $him to use $his own judgment when punishing failures,
	<<if _S.HeadGirl.sexualFlaw == "abusive">>
		and $he usually decides in favor of forcing misbehaving slaves to get $him off.
	<<elseif _S.HeadGirl.fetish == "sadist">>
		permission the sadist uses for $his own gratification.
	<<elseif _S.HeadGirl.fetish == "dom">>
		which the dominant $girl uses confidently.
	<<elseif _S.HeadGirl.energy > 95>>
		which $he uses to
		<<if (_S.HeadGirl.balls > 0)>>
			force $his subordinates to keep $his balls drained.
		<<else>>
			extract the constant sexual favors $his libido demands.
		<</if>>
	<<else>>
		and $he does $his best to be fair.
	<</if>>
	$activeSlave.slaveName
	<<if $activeSlave.devotion > 50>>
		is @@.mediumaquamarine;grateful@@ that _he2 is punished justly when _he2 makes mistakes.
		<<set $activeSlave.trust += 1>>
	<<elseif $activeSlave.devotion >= -20>>
		does _his2 best to learn quickly and avoid punishment.
	<<else>>
		is @@.gold;scared@@ by _his2 inability to get away with the smallest disobedience.
		<<set $activeSlave.trust -= 1>>
	<</if>>
<<else>>
	You require $him to use respect when punishing; $he does $his best to motivate, but is unable to use real fear as a tool. $activeSlave.slaveName understands this, and @@.mediumaquamarine;trusts@@ that if _he2 fails, the consequences won't be too awful.
	<<set $activeSlave.trust += 1>>
<</if>>

<<if $HGtraining == "obedience">>

<<set $activeSlave.training = 0>>
<<set _effectiveness -= ($activeSlave.intelligence+$activeSlave.intelligenceImplant)/3>>
<<if _effectiveness <= 0>>
	$activeSlave.slaveName is smart enough to complicate things; _he2 manages to outwit $him this week and makes no progress.
<<else>>
	<<set $activeSlave.devotion += Math.ceil(_effectiveness/4)>>
	<<if $activeSlave.devotion < -50>>
		$He helps watch and restrain the rebellious $activeSlave.slaveName, helping wear _him2 down, @@.gold;breaking $activeSlave.slaveName's rebelliousness.@@
	<<elseif $activeSlave.devotion < -20>>
		$He keeps $activeSlave.slaveName constantly aware of _his2 slavery, @@.gold;breaking $activeSlave.slaveName's resistance.@@
	<<else>>
		$He acts as another pair of eyes watching $activeSlave.slaveName and metes out punishments, @@.gold;improving $activeSlave.slaveName's servitude.@@
	<</if>>
<</if>>

<<elseif $HGtraining == "paraphilia">>

<<set _effectiveness -= ($activeSlave.intelligence+$activeSlave.intelligenceImplant)/3>>
<<set $activeSlave.training += _effectiveness>>
_S.HeadGirl.slaveName does $his best to get $activeSlave.slaveName past it with punishments and rewards,
<<if $activeSlave.training > 100>>
	and @@.green;resolves $activeSlave.slaveName's paraphilia.@@
	<<set $activeSlave.training = 0>>
	<<set $activeSlave.sexualFlaw = "none">>
<<else>>
	and makes partial progress.
<</if>>

<<elseif $HGtraining == "flaw">>

<<set _effectiveness -= ($activeSlave.intelligence+$activeSlave.intelligenceImplant)/3>>
<<set $activeSlave.training += _effectiveness>>
_S.HeadGirl.slaveName punishes $activeSlave.slaveName whenever $he catches _him2 indulging in _his2 bad habits,
<<if $activeSlave.training > 100>>
	and @@.green;fixes $activeSlave.slaveName's flaw.@@
	<<set $activeSlave.training = 0>>
	<<if $activeSlave.behavioralFlaw != "none">>
		<<set $activeSlave.behavioralFlaw = "none">>
	<<elseif $activeSlave.sexualFlaw != "none">>
		<<set $activeSlave.sexualFlaw = "none">>
	<</if>>
<<else>>
	and makes partial progress.
<</if>>

<<elseif $HGtraining == "soften">>

<<set _effectiveness -= ($activeSlave.intelligence+$activeSlave.intelligenceImplant)/3>>
<<set $activeSlave.training += _effectiveness>>
$He punishes $activeSlave.slaveName whenever $he sees _him2 breaking the rules yet does $his best to retain what makes the slave special,
<<if $activeSlave.training > 150>>
	<<set $activeSlave.training = 0>>
	and successfully @@.green;softens $activeSlave.slaveName's flaw.@@
	<<if $activeSlave.behavioralFlaw != "none">>
		<<run SoftenBehavioralFlaw($activeSlave)>>
	<<elseif $activeSlave.sexualFlaw != "none">>
		<<run SoftenSexualFlaw($activeSlave)>>
	<</if>>
<<else>>
	and makes partial progress.
<</if>>

<<elseif $HGtraining == "oral skill">>

<<set $activeSlave.training = 0>>
<<if (_S.HeadGirl.fetish == "cumslut") && (_S.HeadGirl.fetishStrength > 60)>>
	In spare moments $he teaches $activeSlave.slaveName how to suck cocks, cunts, and assholes. $His enthusiasm for oral sex is infectious. $activeSlave.slaveName's @@.green;oral skills have improved.@@
	<<= slaveSkillIncrease('oral', $activeSlave, random(5,10))>>
<<elseif (_S.HeadGirl.dick > 0) && canPenetrate(_S.HeadGirl)>>
	In spare moments $he teaches $activeSlave.slaveName how to suck cocks, cunts, and assholes. Your Head Girl uses $his penis as an effective teaching tool. $activeSlave.slaveName's @@.green;oral skills have improved.@@
	<<= slaveSkillIncrease('oral', $activeSlave, random(5,10))>>
<<elseif (_S.HeadGirl.clit > 2)>>
	In spare moments $he teaches $activeSlave.slaveName how to suck cocks, cunts, and assholes. Your Head Girl uses $his pseudophallus-sized clit as an effective teaching tool. $activeSlave.slaveName's @@.green;oral skills have improved.@@
	<<= slaveSkillIncrease('oral', $activeSlave, random(5,10))>>
<<else>>
	In spare moments $he teaches $activeSlave.slaveName how to suck cocks, cunts, and assholes. $activeSlave.slaveName's @@.green;oral skills have improved.@@
<</if>>
<<= slaveSkillIncrease('oral', $activeSlave, Math.ceil(_effectiveness/10))>>

<<elseif $HGtraining == "anal skill">>

<<set $activeSlave.training = 0>>
<<if (_S.HeadGirl.fetish == "buttslut") && (_S.HeadGirl.fetishStrength > 60)>>
	In spare moments $he teaches $activeSlave.slaveName how to take it up the ass. Your Head Girl's enthusiasm for backdoor loving is infectious. $activeSlave.slaveName's @@.green;anal skills have improved.@@
	<<= slaveSkillIncrease('anal', $activeSlave, random(5,10))>>
<<elseif (_S.HeadGirl.dick > 0) && canPenetrate(_S.HeadGirl)>>
	In spare moments $he teaches $activeSlave.slaveName how to take a dick up the butt. Your Head Girl uses $his penis as an effective teaching tool. $activeSlave.slaveName's @@.green;anal skills have improved.@@
	<<= slaveSkillIncrease('anal', $activeSlave, random(5,10))>>
<<elseif (_S.HeadGirl.clit > 2)>>
	In spare moments $he teaches $activeSlave.slaveName how to take a phallus up the butt. Your Head Girl uses $his pseudophallus-sized clit as an effective teaching tool. $activeSlave.slaveName's @@.green;anal skills have improved.@@
	<<= slaveSkillIncrease('anal', $activeSlave, random(5,10))>>
<<else>>
	In spare moments $he teaches $activeSlave.slaveName how to take a dick up the butt. $activeSlave.slaveName's @@.green;anal skills have improved.@@
<</if>>
<<= slaveSkillIncrease('anal', $activeSlave, Math.ceil(_effectiveness/10))>>

<<elseif $HGtraining == "fuck skill">>

<<set $activeSlave.training = 0>>
<<if (_S.HeadGirl.energy > 95)>>
	In spare moments $he teaches $activeSlave.slaveName how to take a dick. Your Head Girl's enthusiasm for sex is infectious. $activeSlave.slaveName's @@.green;vanilla sex skills have improved.@@
	<<= slaveSkillIncrease('vaginal', $activeSlave, random(5,10))>>
<<elseif (_S.HeadGirl.dick > 0) && canPenetrate(_S.HeadGirl)>>
	In spare moments $he teaches $activeSlave.slaveName how to take a dick. Your Head Girl uses $his penis as an effective teaching tool. $activeSlave.slaveName's @@.green;vanilla sex skills have improved.@@
	<<= slaveSkillIncrease('vaginal', $activeSlave, random(5,10))>>
<<elseif (_S.HeadGirl.clit > 2)>>
	In spare moments $he teaches $activeSlave.slaveName how to take a phallus. Your Head Girl uses $his pseudophallus-sized clit as an effective teaching tool. $activeSlave.slaveName's @@.green;vanilla sex skills have improved.@@
	<<= slaveSkillIncrease('vaginal', $activeSlave, random(5,10))>>
<<else>>
	In spare moments $he teaches $activeSlave.slaveName how to take a dick. $activeSlave.slaveName's @@.green;vanilla sex skills have improved.@@
<</if>>
<<= slaveSkillIncrease('vaginal', $activeSlave, Math.ceil(_effectiveness/10))>>

<<elseif $HGtraining == "whore skill">>

<<set $activeSlave.training = 0>>
In spare moments $he teaches $activeSlave.slaveName how to prostitute _himself2. $activeSlave.slaveName's @@.green;whoring skills have improved.@@
<<= slaveSkillIncrease('whoring', $activeSlave, Math.ceil(_effectiveness/10))>>

<<elseif $HGtraining == "entertain skill">>

<<set $activeSlave.training = 0>>
<<if (_S.HeadGirl.fetish == "humiliation") && (_S.HeadGirl.fetishStrength > 60)>>
	In spare moments $he teaches $activeSlave.slaveName how to entertain. Your Head Girl's enthusiasm for public display is infectious. $activeSlave.slaveName's @@.green;entertainment skills have improved.@@
	<<= slaveSkillIncrease('entertainment', $activeSlave, random(5,10))>>
<<else>>
	In spare moments $he teaches $activeSlave.slaveName how to entertain. $activeSlave.slaveName's @@.green;entertainment skills have improved.@@
<</if>>
<<= slaveSkillIncrease('entertainment', $activeSlave, Math.ceil(_effectiveness/10))>>

<</if>>
<</if>>

<<if ($activeSlave.devotion >= -20)>>
<<if ($activeSlave.attrKnown == 0)>>
	<<set $activeSlave.attrKnown = 1>>
	_S.HeadGirl.slaveName also investigates the slave's basic sexual orientation, finding that _he2 is
	<<if ($activeSlave.attrXY <= 40)>>
		@@.red;disgusted by men@@
	<<elseif ($activeSlave.attrXY <= 60)>>
		indifferent to men
	<<elseif ($activeSlave.attrXY <= 80)>>
		@@.green;attracted to men@@
	<<else>>
		@@.green;intensely attracted to men@@
	<</if>>
	and
	<<if ($activeSlave.attrXX <= 40)>>
		@@.red;disgusted by women.@@
	<<elseif ($activeSlave.attrXX <= 60)>>
		indifferent to women.
	<<elseif ($activeSlave.attrXX <= 80)>>
		@@.green;attracted to women.@@
	<<else>>
		@@.green;intensely attracted to women.@@
	<</if>>
<</if>>
<</if>>

<<if $HGPiercings>>
	<<if $activeSlave.devotion >= -20 && $activeSlave.genes == "XY" && $activeSlave.attrXY <= 35 && $arcologies[0].FSBodyPurist == "unset" && ($arcologies[0].FSPaternalist == "unset" || ($arcologies[0].FSPaternalist != "unset" && SlaveStatsChecker.modScore($activeSlave).total < 13))>>
		<<set _piercingForbidden = 0>>
		<<for _i = 0; _i < 1; _i++>>
			<<if $activeSlave.earPiercing == 0 && $activeSlave.earShape !== "none">>
				<<if $arcologies[0].FSDegradationist != "unset">>
					<<set $activeSlave.earPiercing = 2>>
				<<else>>
					<<set $activeSlave.earPiercing = 1>>
				<</if>>
				<<run RulesDeconfliction($activeSlave)>>
				<<if $activeSlave.earPiercing != $slaveAfterRA.earPiercing>>
					<<set _piercingForbidden = 1, $activeSlave.earPiercing = 0>>
				<<else>>
					<<if $arcologies[0].FSDegradationist != "unset">>
						_S.HeadGirl.slaveName knows that $activeSlave.slaveName needs to adjust to life as a slave _girl2, so $he has the slave's ears pierced. This will be a constant reminder that _he2 is simply a sexual object here.
					<<else>>
						_S.HeadGirl.slaveName knows that $activeSlave.slaveName needs help adjusting to life as a slave _girl2, so $he has the slave's ears pierced. A little feminine touch can make a big difference.
					<</if>>
					<<run cashX(forceNeg($modCost), "slaveMod", $activeSlave)>>
					<<break>>
				<</if>>
			<</if>>
			<<if $activeSlave.nosePiercing == 0>>
				<<if $arcologies[0].FSDegradationist != "unset">>
					<<set $activeSlave.nosePiercing = 2>>
				<<else>>
					<<set $activeSlave.nosePiercing = 1>>
				<</if>>
				<<run RulesDeconfliction($activeSlave)>>
				<<if $activeSlave.nosePiercing != $slaveAfterRA.nosePiercing>>
					<<set _piercingForbidden = 1, $activeSlave.nosePiercing = 0>>
				<<else>>
					<<if $arcologies[0].FSDegradationist != "unset">>
						_S.HeadGirl.slaveName knows that $activeSlave.slaveName needs to adjust to life as a slave _girl2, so $he gives the slave nasal studs and a large septum ring. It should push $activeSlave.slaveName to see _himself2 as a sexual object for others to use.
					<<else>>
						_S.HeadGirl.slaveName knows that $activeSlave.slaveName needs help adjusting to life as a slave _girl2, so $he gives the slave a cute little nose piercing. It should help $activeSlave.slaveName see _himself2 as a bit more feminine.
					<</if>>
					<<run cashX(forceNeg($modCost), "slaveMod", $activeSlave)>>
					<<break>>
				<</if>>
			<</if>>
			<<if $activeSlave.eyebrowPiercing == 0>>
				<<if $arcologies[0].FSDegradationist != "unset">>
					<<set $activeSlave.eyebrowPiercing = 2>>
				<<else>>
					<<set $activeSlave.eyebrowPiercing = 1>>
				<</if>>
				<<run RulesDeconfliction($activeSlave)>>
				<<if $activeSlave.eyebrowPiercing != $slaveAfterRA.eyebrowPiercing>>
					<<set _piercingForbidden = 1, $activeSlave.eyebrowPiercing = 0>>
				<<else>>
					<<if $arcologies[0].FSDegradationist != "unset">>
						_S.HeadGirl.slaveName knows that $activeSlave.slaveName needs to adjust to life as a slave _girl2, so $he gives the slave multiple eyebrow piercings. A slutty touch for a slave _girl2 should help _him2 feel a little hungrier for cock.
					<<else>>
						_S.HeadGirl.slaveName knows that $activeSlave.slaveName needs help adjusting to life as a slave _girl2, so $he gives the slave a cute little eyebrow piercing. A slutty touch for a slave _girl2 should help _him2 feel a little hungrier for cock.
					<</if>>
					<<run cashX(forceNeg($modCost), "slaveMod", $activeSlave)>>
					<<break>>
				<</if>>
			<</if>>
			<<if $activeSlave.lipsPiercing == 0>>
				<<if $arcologies[0].FSDegradationist != "unset">>
					<<set $activeSlave.lipsPiercing = 2>>
				<<else>>
					<<set $activeSlave.lipsPiercing = 1>>
				<</if>>
				<<run RulesDeconfliction($activeSlave)>>
				<<if $activeSlave.lipsPiercing != $slaveAfterRA.lipsPiercing>>
					<<set _piercingForbidden = 1, $activeSlave.lipsPiercing = 0>>
				<<else>>
					<<if $arcologies[0].FSDegradationist != "unset">>
						_S.HeadGirl.slaveName knows that $activeSlave.slaveName needs to adjust to life as a slave _girl2, so $he has the slave's lower lip pierced. _His2 mouth is for pleasing penises now, so it'll help _him2 if it looks like it.
					<<else>>
						_S.HeadGirl.slaveName knows that $activeSlave.slaveName needs help adjusting to life as a slave _girl2, so $he has the slave's lower lip pierced. _His2 mouth is for pleasing penises now, so it'll help _him2 if it looks like it.
					<</if>>
					<<run cashX(forceNeg($modCost), "slaveMod", $activeSlave)>>
					<<break>>
				<</if>>
			<</if>>
			<<if $activeSlave.navelPiercing == 0>>
				<<if $arcologies[0].FSDegradationist != "unset">>
					<<set $activeSlave.navelPiercing = 2>>
				<<else>>
					<<set $activeSlave.navelPiercing = 1>>
				<</if>>
				<<run RulesDeconfliction($activeSlave)>>
				<<if $activeSlave.navelPiercing != $slaveAfterRA.navelPiercing>>
					<<set _piercingForbidden = 1, $activeSlave.navelPiercing = 0>>
				<<else>>
					<<if $arcologies[0].FSDegradationist != "unset">>
						_S.HeadGirl.slaveName knows that $activeSlave.slaveName needs help adjusting to life as a slave _girl2, so $he has the slave's navel pierced with a big ring. Whatever _he2 thinks in _his2 mind, _S.HeadGirl.slaveName makes clear to _him2 that _his2 body belongs to you.
					<<else>>
						_S.HeadGirl.slaveName knows that $activeSlave.slaveName needs help adjusting to life as a slave _girl2, so $he has the slave's navel pierced. The prettier _his2 lower half looks, the less reluctant _he2 should feel to take it up the butt.
					<</if>>
					<<run cashX(forceNeg($modCost), "slaveMod", $activeSlave)>>
					<<break>>
				<</if>>
			<</if>>
			<<break>>
		<</for>>
		<<if _piercingForbidden>>
			<<if $arcologies[0].FSDegradationist != "unset">>
				_S.HeadGirl.slaveName thinks some piercings might push $activeSlave.slaveName to adjust to life as a slave _girl2, but $he also knows you have rules applied to this slave that forbid it.
			<<else>>
				_S.HeadGirl.slaveName thinks some cute piercings might help $activeSlave.slaveName adjust to life as a slave _girl2, but $he also knows you have rules applied to this slave that forbid it.
			<</if>>
		<</if>>
	<</if>>
<</if>>

<<set $slaves[$slaveIndices[$activeSlave.ID]] = $activeSlave>> /* save changes */


code:
:: HG Select [nobr jump-to-safe jump-hidden jump-from-safe]

<<set $nextButton = "Back to Main", $nextLink = "Main", $encyclopedia = "Head Girl">>

Head Girl Management

<<set _HGName = "Your Head Girl">>
<<if ($HeadGirlID != 0)>>
	<<setLocalPronouns _S.HeadGirl>>
	<<set _HGName = SlaveFullName(_S.HeadGirl)>>
	_HGName is serving as your Head Girl<<if $arcologies[0].FSEgyptianRevivalistLaw == 1>> and Consort; it is $his role to serve and comfort you at your side, in addition to performing normal Head Girl duties<</if>>.
	<<if ($HGSuite)>>

 Currently $he lives in <<link "<<= capFirstChar($HGSuiteName)>>""Head Girl Suite">><</link>>
	<</if>>

<</if>>

__Slave training__

//_HGName will prioritize enabled items in the following order.//

<<if $headGirlTrainsHealth>><<checkbox "$headGirlTrainsHealth" 0 1 checked>><<else>><<checkbox "$headGirlTrainsHealth" 0 1>><</if>>
Health

<<if $headGirlTrainsFlaws>><<checkbox "$headGirlTrainsFlaws" 0 1 checked>><<else>><<checkbox "$headGirlTrainsFlaws" 0 1>><</if>>
Flaws
<<if $headGirlSoftensFlaws>><<checkbox "$headGirlSoftensFlaws" 0 1 checked>><<else>><<checkbox "$headGirlSoftensFlaws" 0 1>><</if>>
Soften

<<if $headGirlTrainsParaphilias>><<checkbox "$headGirlTrainsParaphilias" 0 1 checked>><<else>><<checkbox "$headGirlTrainsParaphilias" 0 1>><</if>>
Paraphilias

<<if $headGirlTrainsObedience>><<checkbox "$headGirlTrainsObedience" 0 1 checked>><<else>><<checkbox "$headGirlTrainsObedience" 0 1>><</if>>
Obedience

<<if $headGirlTrainsSkills>><<checkbox "$headGirlTrainsSkills" 0 1 checked>><<else>><<checkbox "$headGirlTrainsSkills" 0 1>><</if>>
Skills

__Training methods__

_HGName will be
<<if ($HGSeverity > 0)>>
	''aggressive'' when punishing, with rape strongly encouraged. [[Moderate|HG Select][$HGSeverity = 0]]
<<elseif ($HGSeverity == 0)>>
	''moderate'' when punishing, carefully selecting appropriate consequences. [[Be aggressive|HG Select][$HGSeverity = 1]] | [["Restrict " + $him|HG Select][$HGSeverity = -1]]
<<else>>
	''respectful'' when punishing, treating slaves decently. [[Be stricter|HG Select][$HGSeverity = 0]]
<</if>>

_HGName is
<<if $HGPiercings>>
	''allowed'' to use piercings as a tool to improve slaves' attitudes. [[Disallow|HG Select][$HGPiercings = 0]]
<<else>>
	''not allowed'' to use piercings as a tool to improve slaves' attitudes. [[Allow|HG Select][$HGPiercings = 1]]
<</if>>

__Behavior towards you__

_HGName
<<if ($HGFormality != 0)>>
	will be ''formal'': $he will always call you <<= getWrittenTitle(_S.HeadGirl)>>, just like any other slave. [[Allow private informality|HG Select][$HGFormality = 0]]
<<else>>
	is allowed to be ''informal'': in private, $he may call you <<= properTitle()>>. [[Maintain complete formality|HG Select][$HGFormality = 1]]
<</if>>

<<if $seePreg != 0>>
	<<if $HeadGirlID != 0>>
		<<if $universalRulesImpregnation == "HG">>

_HGName is responsible for impregnating fertile slaves.
			<<set $HGCum = 2+Math.trunc((_S.HeadGirl.balls/5)+(_S.HeadGirl.energy/95)+(_S.HeadGirl.health.condition/95)+(_S.HeadGirl.devotion/95)+($reproductionFormula*5))>>
			<<if canPenetrate(_S.HeadGirl) && _S.HeadGirl.pubertyXY == 1>>
				To maximize the chances of impregnation, $he will fuck fertile pussies frequently during the week. _S.HeadGirl.slaveName can service $HGCum slaves this way.
				<<if _S.HeadGirl.devotion > 95>>$He loves you so much $he'll fuck them until $he's sore.<<else>>If $he were more devoted to you, $he might be able to drive $himself to get hard and service one more.<</if>>
				<<if _S.HeadGirl.balls >= 120>>$His unreal balls produce nearly an endless supply of semen; $his ability to impregnate is almost limitless.<<elseif _S.HeadGirl.balls >= 80>>$His inhuman balls produce so much semen $he can easily impregnate twenty girls in one sitting.<<elseif _S.HeadGirl.balls >= 50>>$His giant balls produce so much semen $he can easily impregnate twelve girls in one sitting.<<elseif _S.HeadGirl.balls >= 25>>$His oversized balls produce so much semen $he can cum repeatedly in a single session.<<elseif _S.HeadGirl.balls >= 5>>$His big balls produce so much semen $he can cum more before $he's drained.<<else>>Bigger balls would let $him cum more before $he's drained.<</if>>
				<<if _S.HeadGirl.health.condition > 95>>$His wonderful health lets $him get hard and stay hard all the time.<<else>>If $his health were perfect, $he might be able to get hard more often.<</if>>
				<<if _S.HeadGirl.energy > 95>>$His nymphomania drives $him to go above and beyond in this.<<else>>A more powerful sex drive could reduce $his refractory period.<</if>>
			<<else>>
				However, _S.HeadGirl.slaveName cannot perform this duty.
			<</if>>
			[["Rescind " + $his + " impregnation responsibility"|HG Select][$universalRulesImpregnation = "none"]] | [[See to it yourself|HG Select][$universalRulesImpregnation = "PC"]]
		<<else>>
			<<if canPenetrate(_S.HeadGirl) && _S.HeadGirl.pubertyXY == 1>>

_HGName is capable of impregnating slaves, but it's not part of $his responsibilities. [["Assign " + $him + " to impregnate"|HG Select][$universalRulesImpregnation = "HG"]]
			<</if>>
		<</if>>
	<</if>>
<</if>>

''Appoint a Head Girl from among your devoted slaves:''

[[None|Main][removeJob(_S.HeadGirl, "be your Head Girl")]]

<<includeDOM App.UI.SlaveList.facilityManagerSelection(App.Entity.facilities.headGirlSuite, "Main")>>

repo_name: Welptard/fc

license: mit


code:
:: Industrial Dairy Assignment Scene [nobr]

<<set $nextButton = "Continue", $nextLink = $returnTo>>

<<run App.Utils.setLocalPronouns(getSlave($AS))>>

	/* 000-250-006 */
	<<if $seeImages == 1>>
		<<if $imageChoice == 1>>

<<= SlaveArt(getSlave($AS), 2, 0)>>

		<<else>>

<<= SlaveArt(getSlave($AS), 2, 0)>>

		<</if>>
	<</if>>
	/* 000-250-006 */

When <<= getSlave($AS).slaveName>> reports to the dairy, it's to the <<if canSee(getSlave($AS))>>sight of an unoccupied milking machine waiting for $him<<else>>cold embrace of an unoccupied milking machine<</if>>, its straps ready to immure $him in what is to be $his new home.

<<if getSlave($AS).sexualFlaw == "self hating">> /* GETTING IN */

	As $he realizes $his fate, a kind of peace comes over the self hating slut.
	<<if !canTalk(getSlave($AS))>>
		$He <<if (!hasAnyArms(getSlave($AS)))>>mouths<<else>>gestures<</if>> $his thanks dreamily.
	<<else>>
		"Thank you, <<Master>>," $he <<say>>s simply. "I de<<s>>erve thi<<s>>," $he adds quietly, half to $himself.
	<</if>>
	Then $he falls silent and <<if canSee(getSlave($AS))>>stares at<<else>>faces<</if>> the machine. Though $he hates $himself and looks forward to the release of being unable to do anything but get fucked, that doesn't mean $he isn't afraid.
	<<if (hasAnyArms(getSlave($AS)))>>
		<<if ($dairyStimulatorsSetting > 1)>>
			$He gauges the size of the sodomizer with $his hand, finding that it's wider than $his fist, and then presses the fist against $his own anus. Realizing what's about to happen, $he gives a little shudder.
			<<if ($dairyPregSetting > 1) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
				$He does the same with the dildo that will keep $him pregnant and $his pussy, and $his lower lip starts to quiver.
			<</if>>
		<<else>>
			<<if ($dairyPregSetting > 1) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
				$He gauges the size of the dildo that will keep $him pregnant with $his hand, finding that it's wider than $his fist, and then presses the fist against $his pussy. Realizing what's about to happen, $he gives a little shudder.
			<</if>>
		<</if>>
		<<if ($dairyFeedersSetting > 1)>>
			<<if canSee(getSlave($AS))>>Looking at<<else>>As $he wraps $his lips around<</if>> the phallus that will feed $him, $he begins to cry softly.
		<</if>>
	<</if>>

	<<if (hasAnyArms(getSlave($AS)))>>
		$He strips and climbs into the machine's embrace,
	<<else>>
		Another slave helps $him strip and lays $him in the machine,
	<</if>>
	$his tears pattering onto the uncaring metal. When $he's in place, $his shoulders slump as $he gives up completely.
	<<if !canTalk(getSlave($AS))>>
		$He mouths 'Goodbye.'
	<<elseif SlaveStatsChecker.checkForLisp(getSlave($AS))>>
		"'Bye," $he lisps.
	<<else>>
		"'Bye," $he whispers.
	<</if>>

<<elseif (getSlave($AS).sexualFlaw == "breeder") && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>

	As $he realizes what's about to happen, $he begins to cry openly. A curious mix of arousal, joy, and abject horror is obvious on $his face, and $he deals with the conflicting feelings by sobbing.
	<<if !canTalk(getSlave($AS))>>
		$He <<if (!hasAnyArms(getSlave($AS)))>>mouths<<else>>gestures<</if>> $his thanks shakily.
	<<else>>
		"Th-thank you, <<Master>>," $he <<say>>s through $his tears. "I love you."
	<</if>>
	Then $he falls silent and <<if canSee(getSlave($AS))>>stares at<<elseif (hasAnyArms(getSlave($AS)))>>reaches out to touch<<else>>faces<</if>> the machine. $He's probably imagined this a thousand times, but the prospect is still frightening.
	<<if (hasAnyArms(getSlave($AS)))>>
		<<if ($dairyStimulatorsSetting > 1)>>
			$He gauges the size of the sodomizer with $his hand, finding that it's wider than $his fist, and then presses the fist against $his own anus. Realizing that $his anus is about to be permanently gaped, $he looks doubtful, but then visibly reassures $himself. $He'll need both $his mouth and $his ass to eat enough.
		<</if>>
		<<if ($dairyFeedersSetting > 1)>>
			<<if canSee(getSlave($AS))>>Looking at<<else>>Turning to<</if>> the phallus that will feed $him, $he inserts a finger into its faux urethra, measuring how fast it can pour nutrition in $him.
		<</if>>
		$He strokes the dildo that will keep $him pregnant like a lover, which, of course, it's about to be.
	<</if>>

	<<if (hasAnyArms(getSlave($AS)))>>
		$He strips and climbs into the machine's embrace, shaking with nerves.
	<<else>>
		Another slave helps $him strip and lays $him in the machine. $He shakes with nerves.
	<</if>>
	<<if getSlave($AS).pregKnown == 1>>
		$He <<if canSee(getSlave($AS))>>cranes around to look at<<else>>runs a hand down<</if>> $his already-pregnant belly, and looks impatient.
		<<if !canTalk(getSlave($AS))>>
			$He mouths 'hurry up, I need room.'
		<<else>>
			"Hurry up, I need the room," $he whispers.
		<</if>>
	<<else>>
		$He <<if canSee(getSlave($AS))>>cranes around to look at<<else>>runs a hand down<</if>> $his belly, and looks impatient.
		<<if !canTalk(getSlave($AS))>>
			$He mouths 'come on, I'm ready.'
		<<else>>
			"Come on, I'm ready," $he whispers.
		<</if>>
	<</if>>

<<elseif getSlave($AS).devotion > 95>> /* GETTING IN */

	As $he realizes $his fate, the worshipful slave squares $his shoulders, steeling $himself.
	<<if canTalk(getSlave($AS))>>
		"<<Master>>," $he <<say>>s, "I will do my best to <<s>>erve you."
	<<else>>
		$He gestures that $he'll do $his best for you.
	<</if>>
	<<if canWalk(getSlave($AS))>>
		$He steps over to the machine.
	<</if>>
	<<if canSee(getSlave($AS))>>
		$He looks it over clinically,
	<<elseif hasAnyArms(getSlave($AS))>>
		$He runs a hand over it exploratively,
	<<else>>
		$He takes a deep breath,
	<</if>>
	getting $himself into the right mindset.
	<<if (hasAnyArms(getSlave($AS)))>>
		<<if ($dairyStimulatorsSetting > 1)>>
			$He gauges the size of the massive phallus that will soon penetrate $his anus. It's broader than $his fist.
			<<if canTalk(getSlave($AS))>>
				"I think I can take thi<<s>>. It'll be tough, but I'll need all the hydration I can get."
			<<else>>
				$He nods $his head, understanding that it will need to fit to keep $him hydrated.
			<</if>>
		<</if>>
		<<if ($dairyPregSetting > 1) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
			$He considers the enormous dildo that will fill $him with cum when $he's fertile, and switch to ejaculating drugs when $he conceives.
			<<if canTalk(getSlave($AS))>>
				"I'll be a mother to a whole generation of <<s>>lave<<s>>," $he <<say>>s proudly, taking strength from it.
			<<else>>
				$He takes strength in knowing that $he'll birth a whole generation of new slaves.
			<</if>>
		<</if>>
		<<if ($dairyFeedersSetting > 1)>>
			$He moves $his hand to the dildo that will occupy $his throat, feeding $him.
			<<if canTalk(getSlave($AS))>>
				"I will need my mouth to take in a<<s>> much food a<<s>> I can," $he <<say>>s. "I won't be able to talk. <<S>>o, I'll <<s>>ay it one la<<s>>t time, <<Master>>: I love you."
			<<else>>
				$He focuses on just how much time $he'll need to spend with $his mouth full, so $he blows you one final kiss to show $his love.
			<</if>>
		<</if>>
	<</if>>

	<<if (hasAnyArms(getSlave($AS)))>>
		$He strips and climbs into the machine's embrace.
	<<else>>
		Another slave helps $him strip and lays $him in the machine.
	<</if>>
	$He does not hesitate or <<if canSee(getSlave($AS))>>glance back at<<else>>show any resistance to<</if>> you. You stand by as the straps automatically tighten, robbing $him of the ability to move.
	<<if canTalk(getSlave($AS))>>
		"<<Master>>," $he <<say>>s quietly, "I will try to be <<s>>trong enough to <<s>>tand up to thi<<s>>. But if I'm not, and I forget too much, plea<<s>>e leave me in here <<s>>o I can be u<<s>>eful."
	<<else>>
		$He swears to you that $he will try $his best, but implores you to leave $him to the machine should $his mind fade.
	<</if>>

<<elseif getSlave($AS).devotion > 60>>

	As $he realizes $his fate, the tears come quickly.
	<<if canTalk(getSlave($AS))>>
		"<<Master>>," $he <<say>>s quietly, "i<<s>> thi<<s>> for me?"
	<<else>>
		$He shakily gestures if this is where $he will be staying.
	<</if>>
	<<if canSee(getSlave($AS))>>
		You nod, and $he
		<<if canWalk(getSlave($AS))>>
			steps over to the machine.
		<<else>>
			accepts $his fate.
		<</if>>
	<<elseif canHear(getSlave($AS))>>
		You tell $him it is as $he
		<<if canWalk(getSlave($AS))>>
			steps over to the machine.
		<<else>>
			accepts $his fate.
		<</if>>
	<<else>>
		place a hand on $his shoulder in confirmation and guide $him to the machine.
	<</if>>
	<<if (hasAnyArms(getSlave($AS)))>>
		$He lightly traces its gleaming metal, looking wistful.
		<<if ($dairyStimulatorsSetting > 1)>>
			$He gently touches the head of the massive phallus that will soon penetrate $his anus. It's broader than $his fist.
			<<if canTalk(getSlave($AS))>>
				"M-my butthole i<<s>>n't going to be any good for anal after thi<<s>>."
			<<else>>
				$He gestures jokingly that nothing will fit $his rear hole after this.
			<</if>>
		<</if>>
		<<if ($dairyPregSetting > 1) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
			$He considers the enormous dildo that will fill $him with cum when $he's fertile, and switch to ejaculating drugs when $he conceives.
			<<if canTalk(getSlave($AS))>>
				"I gue<<ss>> that thing won't have any trouble reaching my <<c>>ervi<<x>>."
			<<else>>
				$He knows it won't have any trouble getting $him pregnant.
			<</if>>
		<</if>>
		<<if ($dairyFeedersSetting > 1)>>
			$He moves $his hand to the dildo that will occupy $his throat, feeding $him.
			<<if canTalk(getSlave($AS))>>
				"I-I won't be able to t-talk m-much," $he <<say>>s sadly. "<<S>>-<<s>>o, I'll <<s>>ay it one la<<s>>t time, <<Master>>: I love you."
			<<else>>
				$He knows $he won't have another chance at this, so $he gives you one last tearful 'I love you'.
			<</if>>
		<</if>>
	<</if>>

	<<if (hasAnyArms(getSlave($AS)))>>
		$He <<if getSlave($AS).clothes != "no clothing">>strips and<</if>> climbs into the machine's embrace.
	<<else>>
		Another slave helps $him <<if getSlave($AS).clothes != "no clothing">>strip and lays $him in<<else>>into<</if>> the machine.
	<</if>>
	<<if canTalk(getSlave($AS))>>
		"<<Master>>," $he gasps out, the tears coming fast now. "C-can you
		<<if (hasAnyArms(getSlave($AS)))>>
			h-hold my h-hand while it a-activate<<s>>? Plea<<s>>e?" You take $his hand as the straps automatically tighten, robbing $him of the ability to move. $He grips your hand tightly.
		<<else>>
			<<S>>-<<s>>tay with me while it activate<<s>>? Plea<<s>>e?" You stand by as the straps automatically tighten, robbing $him of the ability to move.
		<</if>>
	<<else>>
		You can tell by the tears streaming down $his face that $he doesn't want to leave you so soon.
		<<if (hasAnyArms(getSlave($AS)))>>
			You take $his hand as the straps automatically tighten, robbing $him of the ability to move. $He grips your hand tightly.
		<<else>>
			You stand by as the straps automatically tighten, robbing $him of the ability to move.
		<</if>>
	<</if>>

<<elseif getSlave($AS).devotion > 20>>

	$He desperately tries to be brave and obey, but as $his fate dawns on $him, $his courage and conditioning fail $him.
	<<if (!hasAnyLegs(getSlave($AS)))>>
		$He tries to wriggle away from the machine, so
	<<else>>
		$He turns and tries to run, so
	<</if>>
	<<if ($MilkmaidID != 0)>>
		_S.Milkmaid.slaveName is
	<<else>>
		you are
	<</if>>
	obliged to
	<<if (!isAmputee(getSlave($AS)))>>
		subdue $him and strap $him,
	<<else>>
		place $him,
	<</if>>
	begging and sobbing, into the machine's embrace.
	<<if canTalk(getSlave($AS))>>
		"Plea<<s>>e, <<Master>>!" $he begs. "Plea<<s>>e no!
		<<if ($dairyStimulatorsSetting > 1)>>
			I-it'll fuck my b-butthole <<s>>o wide I'll be u<<s>>ele<<ss>> for anal!
		<</if>>
		<<if ($dairyPregSetting > 2) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
			My w-womb c-c-can't take it! I'll b-bur<<s>>t! And m-my c-c-cunt will be ruined from the dildo and birthing!
		<<elseif ($dairyPregSetting > 1) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
			M-my c-c-cunt will be <<s>>-<<s>>o <<s>>tretched from the dildo and birthing!
		<</if>>
		I'll d-do anything!"
	<<else>>
		$He pitifully begs for anything but this, even going as far as trying to convey what the machine will do to $him, but it will do $him no good.
	<</if>>

<<else>>

	$He starts to weep as soon as $he realizes $his fate.
	<<if getSlave($AS).trust >= -20>>
		$He is afraid of you, but not afraid enough that $he will not resist this.
	<</if>>
	<<if (hasAnyLegs(getSlave($AS)))>>
		$He tries to wriggle away from the machine, so
	<<else>>
		$He turns and tries to run, so
	<</if>>
	<<if ($MilkmaidID != 0)>>
		_S.Milkmaid.slaveName is
	<<else>>
		you are
	<</if>>
	obliged to
	<<if (!isAmputee(getSlave($AS)))>>
		subdue $him and strap $him,
	<<else>>
		place $him,
	<</if>>
	begging and sobbing, into the machine's embrace.

	<<if canTalk(getSlave($AS))>>
		"Plea<<s>>e, <<Master>>!" $he begs. "Plea<<s>>e no!
		<<if ($dairyStimulatorsSetting > 1)>>
			I-it'll fuck my b-butthole so loo<<s>>e I'll be u<<s>>ele<<ss>> for anal! I p-promi<<s>>e I'll be a good little bitch from now on!
		<</if>>
		<<if ($dairyPregSetting > 2) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
			My w-womb c-c-can't take that many babie<<s>>! I'll b-bur<<s>>t! M-my c-c-cunt can't t-take that dildo either! I d-don't want to g-get p-pregnant over and over...
		<<elseif ($dairyPregSetting > 1) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
			M-my c-c-cunt can't t-take that dildo! I d-don't want to g-get p-pregnant over and over...
		<</if>>
		I'll d-do anything!"
	<<else>>
		$He pitifully begs for to have mercy on $him and not subject $him to the machines 'features', but it will do $him no good.
	<</if>>

<</if>> /* CLOSES DEVOTION */

<<if getSlave($AS).lactation > 0>>
	A big soft cup attaches itself <<if getSlave($AS).nipples == "fuckable">>over<<else>>to<</if>> each of $his nipples.
	<<if (getSlave($AS).nipples == "inverted")>>
		$He gasps with pain as suction unceremoniously hauls $his inverted nipples down into the cups.
	<<elseif (getSlave($AS).nipples == "fuckable")>>
		$He gasps with surprise as a phallic rods unceremoniously slip into $his nipples to better harvest $his milk.
	<</if>>
<</if>>
<<if getSlave($AS).balls > 0>>
	<<if getSlave($AS).dick > 0>>
		The first drugs hiss into $him,
		<<if getSlave($AS).dick > 8>>
			and $his eyes roll back as much of $his blood volume rushes into $his dick, though it remains soft.
		<<elseif getSlave($AS).dick > 6>>
			and $he goes limp as much of $his blood volume rushes to bring $him to half mast.
		<<else>>
			bringing $him to a full erection.
		<</if>>
		$He gasps as the warm, wet receptacle surrounds $his cock.
	<<else>>
		<<if getSlave($AS).lactation > 0>>Another<<else>>A big soft<</if>> cup is placed against $his little front cumhole.
	<</if>>
<</if>>
A visor lowers onto $his face to keep $his mind at least minimally stimulated.
<<if canHear(getSlave($AS)) && !canSee(getSlave($AS))>>
	It will play audio from
<<else>>
	It will display garish
<</if>>
hardcore pornography featuring
<<if ($dairyFeedersSetting > 1)>>
	throatfucking, cum swallowing,
<</if>>
<<if ($dairyPregSetting > 1) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
	bareback vaginal sex, pregnancy, childbirth,
<</if>>
<<if (getSlave($AS).balls > 0)>>
	cumming cocks, anal stimulation,
<</if>>
<<if (getSlave($AS).lactation > 0)>>
	breast expansion, women being milked,
<</if>>
and brutal sodomy.
<<if !canHear(getSlave($AS)) && !canSee(getSlave($AS))>>
	Of course, $he won't enjoy any of that and will be left entirely at the mercy of the sensations running through $his flesh.
<</if>>

<<if (getSlave($AS).anus < 3) || ((getSlave($AS).vagina < 3) && (getSlave($AS).vagina > -1))>>
	<<set getSlave($AS).anus = 3>>
	<<if getSlave($AS).vagina > -1>><<set getSlave($AS).vagina = 3>><</if>>
	The machine detects that $he requires the attention of the preparatory raper before it can penetrate $him successfully, and holds $him in place while the raper slides along its track in the ceiling. It comes to rest above the slave's defenseless body and extends its implements towards $him. $He can't see or hear it, but $he senses that something's happening and shivers.
	<<if ($dairyPregSetting > 1) && ($dairyPregSetting > 1) && isFertile(getSlave($AS)) && (getSlave($AS).vagina < 3) && getSlave($AS).mpreg != 1>>
		$His pussy is nowhere near ready to accept the passage of drugs and cum in and new slaves out. The new machine lubes $him thoroughly and then <<if getSlave($AS).vagina == 0>>takes $his virginity<<else>>starts to fuck $him<</if>> with a reasonably sized dildo.
	<</if>>
	<<if ($dairyStimulatorsSetting > 1) && (getSlave($AS).anus < 3)>>
		$He'll be drinking through $his mouth almost constantly, but that won't be enough. $He'll have to absorb hydration and nutrition from both ends to keep up with the outflow $he'll produce. <<if ($dairyPregSetting > 1) && ($dairyPregSetting > 1) && isFertile(getSlave($AS)) && (getSlave($AS).vagina < 3) && getSlave($AS).mpreg != 1>>It<<else>>The new machine<</if>> fills $his ass with lube and then penetrates $his <<if getSlave($AS).anus == 0>>virgin anus<<else>>rectum<</if>> gently.
	<</if>>
	$He's worked in gradually, but every time $he's loosened just slightly, the now-inadequate dildo is replaced by a larger one, and eventually more than one.
	<<if ($dairyPregSetting > 1) && isFertile(getSlave($AS)) && (getSlave($AS).vagina < 3) && getSlave($AS).mpreg != 1>>
		<<if ($dairyStimulatorsSetting > 1) && (getSlave($AS).anus < 3)>>
			$He goes from a dildo in the pussy and a dildo in the ass, through numerous interesting combinations of double penetration, until $he's got two porn star sized dildos sliding in and out of $his pussy and two more fucking $his ass.
		<<else>>
			$His womanhood goes from a normal dildo to a big dildo to two dildos, and so on, until $he's taking the equivalent of two porn star cocks.
		<</if>>
	<<else>>
		$His asshole goes from a normal dildo to a big dildo to two dildos, and so on, until $he's taking the equivalent of two porn star cocks up the butt.
	<</if>>
	This is a long process, and though
	<<if getSlave($AS).devotion > 95>>
		$he started out getting off on it,
	<<elseif getSlave($AS).devotion > 60>>
		$he did $his best to enjoy $himself for a while,
	<<elseif getSlave($AS).devotion > 20>>
		$he tried to relax and make it easier on $himself at the start,
	<<else>>
		$he cried and tried to break loose for a while,
	<</if>>
	$he's slumped against the machine from sheer exhaustion by the end. Its work completed, the preparatory raper withdraws and lets the milking machine begin its work. It's only been a few hours since <<= getSlave($AS).slaveName>>'s ordeal began, but now $he's ready to begin giving back. The machine revives $him with a hit of pharmaceuticals.

<</if>>

<<if ($dairyPregSetting > 1) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
	$His vagina goes first. $He relaxes $his loose cunt for the elephantine dildo, but despite $his best efforts, it forces a gasp out of $him as it slides in. It remains stationary for now, but <<= getSlave($AS).slaveName>> know it's just the beginning, and $he already feels full to bursting.
	<<if getSlave($AS).devotion > 95>>
		$He takes more deep breaths, doing $his best to remain calm.
	<<elseif getSlave($AS).devotion > 60>>
		Terrified, $he cries harder.
	<<elseif getSlave($AS).devotion > 20>>
		Terrified, $he cries harder.
	<<else>>
		Terrified, $he starts to <<if !canTalk(getSlave($AS))>>soundlessly <</if>>scream and cry.
	<</if>>
<<elseif ($dairyPregSetting > 0) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
	<<if getSlave($AS).devotion > 95>>
		$He moans with pleasure
	<<elseif getSlave($AS).devotion > 60>>
		$He gasps
	<<elseif getSlave($AS).devotion > 20>>
		$He moans with fear
	<<else>>
		$He moans with anguish
	<</if>>
	as the machine inserts a warm, lubricated dildo into $his vagina.
<</if>>
<<if ($dairyStimulatorsSetting > 1)>>
	$His anus is next. An auxiliary dildo the size of the largest human cocks goes first, assraping $him so hard $he'd probably be injured if $he wasn't already very loose.
	<<if getSlave($AS).devotion > 95>>
		$He relaxes and does $his best to enjoy $himself, $his cheeks flushing with arousal. Once $his sphincter is well stretched, the machine withdraws the dildo, and before $his anus can begin to close, the machine replaces it with the main instrument. Despite the preparation, it's so huge that $he moans with fear $he feels the head touch $his buttocks. The moan becomes a long low groan as $his butthole accommodates the enormous thing. When it's all the way in, the dildo begins to withdraw for its first stroke, and $he
		<<if canTalk(getSlave($AS))>>
			whispers, "<<Master>>, it's <<s>>-<<s>>o b-big." $He relaxes and recollects $himself, and then adds, "I can do thi<<s>>."
		<<else>>
			begins distressing over its size before relaxing and recollecting $himself. $He smiles to show you $he can do this.
		<</if>>
	<<elseif getSlave($AS).devotion > 60>>
		$He tries to <<if getSlave($AS).skill.anal > 10>>apply $his anal training<<else>>relax<</if>>, but it fucks $his butt so mercilessly that $he eventually gives up and relaxes completely. This is what the machine was aiming for; it withdraws the dildo, and before $his sphincter can close, it replaces it with the main instrument. Despite the preparation, it's so huge that $he begins to <<if !canTalk(getSlave($AS))>>silently <</if>>scream in terror as $he feels the head touch $his buttocks. $His
		<<if canTalk(getSlave($AS))>>
			yelling becomes a drawn-out shriek
		<<else>>
			pointless yelling turns to struggling
		<</if>>
		as $his butthole accommodates the enormous thing. When $he finally runs out of breath and slumps within $his restraints, the dildo begins to withdraw for its first stroke, and $he
		<<if canTalk(getSlave($AS))>>
			whispers, "<<Master>>, it'<<s>> too b-big. It hu-hurt<<s>>."
		<<else>>
			attempts to tell you that it is too big for $his hole.
		<</if>>
	<<elseif getSlave($AS).devotion > 20>>
		Crying, $he tries to <<if getSlave($AS).skill.anal > 10>>apply $his anal training<<else>>relax<</if>>, but it fucks $his butt so mercilessly that $he eventually gives up and relaxes completely. This is what the machine was aiming for; it withdraws the dildo, and before $his sphincter can close, it replaces it with the main instrument. Despite the preparation, it's so huge that $he begins to beg desperately as $he feels the head touch $his buttocks. $His
		<<if canTalk(getSlave($AS))>>
			whining becomes a drawn-out shriek
		<<else>>
			soundless whining turns to struggling
		<</if>>
		as $his butthole accommodates the enormous thing. When $he finally runs out of breath and slumps within $his restraints, the dildo begins to withdraw for its first stroke, and $he is racked with sobs.
	<<else>>
		$He obviously thinks this is what $his butt will suffer, and doesn't like it. $He's tragically wrong. When $he finally relaxes, the machine withdraws the dildo, and before $his sphincter can close, it replaces it with the main instrument.
		<<if canTalk(getSlave($AS))>>
			$He screams with the horror of realization and begins to beg desperately as $he feels its head touch $his buttocks. $His cries become a drawn-out shriek as $his butthole accommodates the enormous thing.
		<<else>>
			$He attempts to fling $himself from the machine with the horror of realization begins to flail desperately as $he feels its head touch $his buttocks. $His efforts double as $his butthole accommodates the enormous thing.
		<</if>>
		When $he finally runs out of breath and slumps within $his restraints, the dildo begins to withdraw for its first stroke, and $he is racked with weeping.
	<</if>>
	<<if ($dairyPregSetting > 1) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
		The dildo in $his vagina begins to fuck $him as well. Between $his terribly broadened holes, $his stretched perineum is barely visible at all.
	<</if>>
<<elseif ($dairyStimulatorsSetting > 0)>>
	<<if getSlave($AS).devotion > 95>>
		$He groans as the machine pushes a big dildo up $his butt and begins to sodomize $him powerfully.
	<<elseif getSlave($AS).devotion > 60>>
		$He sobs as the machine pushes a big dildo up $his butt and begins to sodomize $him powerfully.
	<<elseif getSlave($AS).devotion > 20>>
		$He sobs as the machine pushes a big dildo up $his butt and begins to sodomize $him powerfully.
	<<else>>
		$He cries as the machine pushes a big dildo up $his butt and begins to sodomize $him powerfully.
	<</if>>
<</if>>
<<if ($dairyFeedersSetting > 1)>>
	<<if getSlave($AS).devotion > 95>>
		A manipulator prods $his jaw open and a phallus slides into $his throat, working around for a while to find the optimal position for maximum penetration where $he can still breathe through $his nose. There is a hiss as the food begins rushing through the phallus and down $his throat.
	<<elseif getSlave($AS).devotion > 60>>
		<<if canTalk(getSlave($AS))>>
			$He tries to say something, but $he left it too late.
		<</if>>
		A manipulator forces $his jaw open and a phallus slides into $his throat, working around for a while to find the optimal position for maximum penetration where $he can still breathe through $his nose. There is a hiss as the food begins rushing through the phallus and down $his throat.
	<<elseif getSlave($AS).devotion > 20>>
		$His crying is abruptly cut off as a manipulator forces $his jaw open and a phallus slides into $his throat, working around for a while to find the optimal position for maximum penetration where $he can still breathe through $his nose.
	<<else>>
		$He cries hopelessly,
		<<if canTalk(getSlave($AS))>>
			"I'm n-never going t-to leave h-here, am I, —" $His noise
		<<else>>
			until $his sobbing
		<</if>>
		is abruptly cut off as a manipulator forces $his jaw open and a phallus slides into $his throat, working around for a while to find the optimal position for maximum penetration where $he can still breathe through $his nose.
	<</if>>
<<elseif ($dairyFeedersSetting > 0)>>
	<<if getSlave($AS).devotion > 95>>
		The machine gives $him a phallus to suck on.
	<<elseif getSlave($AS).devotion > 60>>
		<<if canTalk(getSlave($AS))>>
			$He tries to say something, but $he left it too late.
		<</if>>
		The machine gives $him a phallus to suck on.
	<<elseif getSlave($AS).devotion > 20>>
		$His crying is abruptly cut off as the machine gives $him a phallus to suck on.
	<<else>>
		$He cries hopelessly,
		<<if canTalk(getSlave($AS))>>
			"I'm n-never going t-to leave h-here, am I, —" $His noise
		<<else>>
			until $his sobbing
		<</if>>
		is abruptly cut off as the machine forces a phallus into $his mouth.
	<</if>>
<</if>>

With its various applicators inserted and working, the machine begins to ejaculate necessary fluids into $his body. You cannot see much direct evidence, but the inrush of fluids is clear from the draining reservoirs scattered around the machine.
<<if ($dairyStimulatorsSetting > 1)>>
	The gargantuan phallus fucking $his butthole ejaculates industrial lubricant, hydration, nutrition, and medication, to be absorbed by $his lower intestines.
<<elseif ($dairyStimulatorsSetting > 0)>>
	The phallus fucking $his ass ejaculates hydration, nutrition, and medication, to be absorbed by $his colon.
<</if>>
<<if ($dairyPregSetting > 1) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
	The dildo in $his vagina ejaculates cum, fertility drugs, and medication designed to cause uncontrollable natural lubrication, so it will not damage $him too severely.
<<elseif ($dairyPregSetting > 0) && isFertile(getSlave($AS)) && getSlave($AS).mpreg != 1>>
	The dildo in $his vagina ejaculates cum and fertility drugs.
<</if>>
<<if ($dairyFeedersSetting > 0)>>
	There is a hiss as still more fluid containing hydration, nutrition, and medication begins rushing through the phallus in $his mouth and down $his throat.
<</if>>
Finally, multiple drug injectors attach themselves to $him and begin to use hypersonic jets to drive pharmaceuticals into $him without needles.
<<if getSlave($AS).devotion > 95>>
	$His eyes fly wide as $he <<if canHear(getSlave($AS))>>hears and <</if>>feels the number of injections. $He knows these drugs are not without side effects, and $he's being injected with a normal day's dose every minute. $He musters $his resolve and relaxes again, relying on $his knowledge that you want $him to accept this fate.
<<elseif getSlave($AS).devotion > 60>>
	$His eyes fly wide and $he stiffens with fear as $he <<if canHear(getSlave($AS))>>hears and <</if>>feels the number of injections. $He knows these drugs are not without side effects, and $he's being injected with a normal day's dose every minute. $He visibly tries to accept it, knowing that you want $him to submit to this fate.
<<elseif getSlave($AS).devotion > 20>>
	The tears streaming out of $his eyes come faster as $he <<if canHear(getSlave($AS))>>hears and <</if>>feels the number of injections. $He knows these drugs are not without side effects, and $he's being injected with a normal day's dose every minute.
<<else>>
	$He begins to struggle desperately as $he <<if canHear(getSlave($AS))>>hears and <</if>>feels the number of injections. $He knows these drugs are not without side effects, and $he's being injected with a normal day's dose every minute.
<</if>>

Fluids begin to come out of $him. The drugs are strong, and despite everything $he experiences an orgasm so powerful that it's clear why the straps that bind $him are reinforced.
<<if getSlave($AS).balls > 0>>
	<<if getSlave($AS).dick > 0>>The anal dildo fucks $him even harder<<else>>If $he had a dick, it would be caressed by a nice warm receptacle, but $he doesn't. The milker is forced to rape $his ass without mercy to force $him to cum<</if>>, and $he tries to scream around the dildo in $his mouth. <<if getSlave($AS).scrotum > 0>>$His balls tighten as $he<<else>>$He<</if>> shoots rope after rope of semen into the machine.
<</if>>
<<if (getSlave($AS).vagina > -1)>>
	$He gives the machine a nice gush of femcum.
<</if>>
<<if (getSlave($AS).lactation > 0)>>
	The cups sucking $his nipples work away ceaselessly, $his milk whitening the clear piping running into the machine.
	<<set getSlave($AS).lactationDuration = 2>>
	<<set getSlave($AS).boobs -= getSlave($AS).boobsMilk, getSlave($AS).boobsMilk = 0>>
<</if>>
The machine continues fucking $him despite $his climax.
<<if getSlave($AS).devotion > 95>>
	Though it's difficult to tell, it's possible $he's smiling around the dildo in $his mouth. $He may be such a well-broken sex slave that $he can stand up to a life of nothing but drugs, milking, and an endless string of orgasms. To ease $his acclimation to $his new life, the drug cocktail is adjusted as $his orgasm fades,
<<elseif getSlave($AS).devotion > 60>>
	Despite $his attempt to be brave, tears begin to leak out from behind $his visor as $he realizes that there will be no respite from the penetration. The drug cocktail is adjusted as $his orgasm fades,
<<elseif getSlave($AS).devotion > 20>>
	To ease $his acclimation to $his new life, the drug cocktail is adjusted as $his orgasm fades,
<<else>>
	To allow $him some rest despite $his terror, the drug cocktail is adjusted as $his orgasm fades,
<</if>>
to put $him to sleep. $He slumps against the machine as $he drops off.
<<if (hasAnyArms(getSlave($AS)))>>$His painfully tight grip on your hand finally loosens<</if>>.
<<if ($dairyStimulatorsSetting > 1)>>
	$His anus has not yet stretched to take the necessary full power setting, so $he is gently sodomized as $he sleeps to get $his sphincter used to its permanent occupier.
<</if>>
<<if (getSlave($AS).belly < 1500)>>
	$His belly has already begun to distend from the mass of fluid ejaculated down $his throat and into $his stomach, <<if getSlave($AS).ovaries == 1>>inside $his womanhood and into $his womb, and <</if>>up $his butt and into $his lower intestine.
<</if>>

Silence returns to the dairy.


code:
:: JE slave dispute [nobr]

<<set $nextLink = "RIE Eligibility Check", $returnTo = "RIE Eligibility Check", $nextButton = "Continue", _event = $justiceEvents.pluck()>> /* pick a random event and remove it from the array so it will not occur again */

<<switch _event>>
<<case "slave deal">>
	<<set _ContractCost = 5000>>
	<<set _slave = GenerateNewSlave("XX", {minAge: 24, maxAge: 42, ageOverridesPedoMode: 1, disableDisability: 1})>>
	<<set _slave.origin = "$He sold $himself into slavery to buy medical care for $his daughter.">>
	<<set _slave.devotion = random(25,30)>>
	<<set _slave.trust = _slave.devotion-20>>
	<<set _slave.oldDevotion = _slave.devotion>>
	<<run setHealth(_slave, jsRandom(0, 20))>>
	<<set _slave.earPiercing = 1>>
	<<set _slave.vagina = random(1,2)>>
	<<set _slave.ovaries = 1>>
	<<set _slave.counter.birthsTotal = 1>>
	<<set _slave.shouldersTat = either("flowers", "tribal patterns")>>
	<<set _slave.stampTat = either("flowers", "tribal patterns")>>
<<case "breeding deal">>
	<<set _ContractCost = 40000>>
	<<set _slave = GenerateNewSlave("XX", {minAge: $fertilityAge+3, maxAge: 42, ageOverridesPedoMode: 1, disableDisability: 1})>>
	<<set _slave.origin = "$He was raised to be a mother.">>
	<<set _slave.career = "a breeder">>
	<<set _slave.devotion = random(10,25)>>
	<<set _slave.trust = _slave.devotion>>
	<<run setHealth(_slave, jsRandom(80, 90), 0, 0, 0, jsRandom(10, 30))>>
	<<set _slave.anus = 0>>
	<<set _slave.vagina = 3>>
	<<set _slave.skill.anal = 0>>
	<<set _slave.skill.oral = 0>>
	<<set _slave.skill.whoring = 0>>
	<<set _slave.skill.vaginal = 0>>
	<<set _slave.skill.entertainment = 0>>
	<<set _slave.bellySag = 10>>
	<<set _slave.bellySagPreg = 10>>
	<<set _slave.counter.birthsTotal = 3>>
	<<set _slave.hips = 2>>
	<<set _slave.boobs = random(4,6)*100>>
	<<if $seePreg == 1>>
		<<set _slave.belly = 18000>>
	<</if>>
<<case "slave training">>
	<<set _ContractCost = 10000>>
	<<set _slave = GenerateNewSlave("XY", {disableDisability: 1})>>
	<<set _slave.origin = "You bought out a deal involving $him training to be an expert gelded sex slave.">>
	<<set _slave.devotion = random(30,40)>>
	<<set _slave.trust = _slave.devotion>>
	<<set _slave.oldDevotion = _slave.devotion>>
	<<run setHealth(_slave, jsRandom(60, 80), 0, 0, 0, jsRandom(10, 30))>>
	<<set _slave.balls = 0>>
	<<set _slave.anus = 2>>
	<<set _slave.skill.anal = 35>>
	<<set _slave.skill.oral = 35>>
	<<set _slave.skill.whoring = 35>>
	<<set _slave.skill.entertainment = 35>>
	<<set _slave.nipplesPiercing = 1>>
	<<set _slave.clitPiercing = 1>>
	<<set _slave.dickPiercing = 1>>
	<<set _slave.anusPiercing = 1>>
	<<set _slave.lipsPiercing = 1>>
	<<set _slave.tonguePiercing = 1>>
	<<set _slave.earPiercing = 1>>
	<<set _slave.nosePiercing = 1>>
	<<set _slave.eyebrowPiercing = 1>>
	<<set _slave.navelPiercing = 1>>
	<<set _slave.boobsTat = either("advertisements", "degradation", "rude words")>>
	<<set _slave.buttTat = either("advertisements", "degradation", "rude words")>>
	<<set _slave.vaginaTat = either("advertisements", "degradation", "rude words")>>
	<<set _slave.dickTat = either("advertisements", "degradation", "rude words")>>
	<<set _slave.lipsTat = either("advertisements", "degradation", "rude words")>>
	<<set _slave.anusTat = either("advertisements", "degradation", "rude words")>>
	<<set _slave.shouldersTat = either("advertisements", "degradation", "rude words")>>
	<<set _slave.armsTat = either("advertisements", "degradation", "rude words")>>
	<<set _slave.legsTat = either("advertisements", "degradation", "rude words")>>
	<<set _slave.stampTat = either("advertisements", "degradation", "rude words")>>
<<case "majority deal">>
	<<set _ContractCost = 20000>>
	<<set _slave = GenerateNewSlave("", {minAge: $minimumSlaveAge, maxAge: 18, disableDisability: 1})>>
	<<set _slave.origin = "$He was raised to be a slave, since $he was mistakenly thought to be from good slave stock.">>
	<<set _slave.career = "a slave">>
	<<set _slave.devotion = random(10,15)>>
	<<set _slave.trust = _slave.devotion>>
	<<set _slave.oldDevotion = _slave.devotion>>
	<<run setHealth(_slave, jsRandom(80, 90), 0, 0, 0, jsRandom(10, 30))>>
	<<if _slave.dick == 0>>
		<<set _slave.vagina = 0>>
		<<set _slave.ovaries = 1>>
	<<elseif _slave.balls == 0>>
		<<set _slave.balls = 1>>
	<</if>>
	<<set _slave.anus = 0>>
	<<set _slave.skill.anal = 0>>
	<<set _slave.skill.oral = 0>>
	<<set _slave.skill.whoring = 0>>
	<<set _slave.skill.vaginal = 0>>
	<<set _slave.skill.entertainment = 0>>
<<case "indenture deal">>
	<<set _ContractCost = 7500>>
	<<set _slave = GenerateNewSlave("", {minAge: 24, maxAge: 42, disableDisability: 1})>>
	<<run setHealth(_slave, jsRandom(-20, 20))>>
	<<set _slave.anus = 2>>
	<<if _slave.vagina > -1>>
		<<set _slave.vagina = 2>>
	<</if>>
	<<set _slave.skill.vaginal = 15>>
	<<set _slave.skill.oral = 15>>
	<<set _slave.skill.anal = 15>>
	<<set _slave.skill.whoring = 0>>
	<<set _slave.skill.entertainment = 15>>
	<<set _slave.boobs += 600>>
	<<set _slave.boobsImplant = 600>>
	<<set _slave.boobsImplantType = "normal">>
	<<set _slave.butt += 1>>
	<<set _slave.buttImplant = 1>>
	<<set _slave.buttImplantType = "normal">>
	<<set _slave.lips += 10>>
	<<set _slave.lipsImplant = 10>>
	<<set _slave.lipsPiercing = 1>>
	<<set _slave.tonguePiercing = 1>>
	<<set _slave.earPiercing = 1>>
	<<set _slave.nosePiercing = 1>>
	<<set _slave.eyebrowPiercing = 1>>
	<<set _slave.navelPiercing = 1>>
	<<set _slave.nipplesPiercing = 1>>
	<<set _slave.clitPiercing = 1>>
	<<set _slave.stampTat = either("flowers", "tribal patterns")>>
<<default>>
	<<set _ContractCost = 10000>>
	<<set _slave = GenerateNewSlave("", {maxAge: 22, disableDisability: 1})>>
	<<set _slave.origin = "You bought out a deal for $his sale after the seller took $his virginity and the buyer no longer wanted $him.">>
	<<set _slave.counter.publicUse += 10>>
	<<set _slave.devotion = random(25,30)>>
	<<set _slave.trust = _slave.devotion-20>>
	<<set _slave.oldDevotion = _slave.devotion>>
	<<run setHealth(_slave, jsRandom(0, 20))>>
	<<set _slave.anus = 2>>
	<<if _slave.dick == 0>>
		<<set _slave.vagina = 2>>
		<<set _slave.ovaries = 1>>
		<<if isFertile(_slave) && $seePreg == 1>>
			<<= knockMeUp(_slave, 100, 2, -2, 1)>>
		<</if>>
	<</if>>
<</switch>>

/* 000-250-006 */
<<if $seeImages == 1>>
<<if $imageChoice == 1>>

<<= SlaveArt(_slave, 2, 0)>>

<<else>>

<<= SlaveArt(_slave, 2, 0)>>

<</if>>
<</if>>
/* 000-250-006 */

<<run App.Utils.setLocalPronouns(_slave)>>

<<= capFirstChar($assistant.name)>> breaks in on your sleep with an urgent message. You push a slave off you and sit up to take it. As the owner of the arcology, you perform some functions that would traditionally be the province of a government. In this anarcho-liberal polity, it's still necessary for people making deals to have someone to appeal to when disputes arise. Part of your agreement with your tenants is that you will perform this duty on deals between two tenants. The message is about just such a disagreement; they always seem to happen in the middle of the night, and they're always urgent.

<<switch _event>>
<<case "slave deal">>
	An older $woman who has signed an enslavement contract with a slave trader is accusing her of not living up to the terms. The contract requires that the trader pay the medical costs of the $woman's daughter in return for the $woman's voluntary enslavement. The $woman claims that the payments have not been made and the trader is still insisting on enslavement.

	The trader states that the daughter was thought to only have a minor condition, but has proven to be suffering from a serious cancer. She protests that she will lose a great deal of money, and that there's no way she would have made the deal if the $woman had been honest with her about how bad $his daughter's condition was. The $woman responds that $he didn't know.
<<case "breeding deal">>
	A small-time slave breeder is accusing a customer of reneging on their agreement. For the last nine months, one of his best breeders has been busy growing his client's future slave and now
	<<if $seePreg == 1>>
		that $he's ready to give birth,
		<<set _slave.belly = 0>>
		<<set _slave.pregWeek = -3>>
	<<else>>
		that it's born,
	<</if>>
	he's refusing to transfer the funds, placing the entire operation in jeopardy.

	The father<<if $seePreg == 1>>-to-be<</if>> claims that the child is not his and as such, the contract has not been fulfilled. Despite offers from the breeder to perform a paternity test, he adamantly insists on using his private, and rather expensive, physician to run the test; a cost high enough to put them out of business anyway.
<<case "slave training">>
	One of your prominent tenants is accusing another of failing to train a slave for him according to the terms of a slave training contract. He highlights a part of the contract that requires that the slave be expert in "all common sexual skills." He self-righteously declares that the delivered slave has no vaginal skills to speak of, that he doesn't want $him as a result, and requests that you release him from the contract.

	The trainer replies with some aspersion that the accuser is technically correct: the slave has no vaginal skills at all. This is, however, due to the fact that the slave has no vagina. He claims that the accuser verbally requested a gelded slave, though there's nothing about that either way in the contract. He protests that he did his best to train an expert gelding, and offers many lengthy videos to prove that he did.
<<case "majority deal">>
	A prominent citizen is accusing a slave school of lying to him about the pedigree of a $girl about to reach $his majority. $He'll be enslaved once $he's of age, and he owns the rights to $him. He produces many messages from the school about $his progress; they all reference $his excellent bloodline. The slave's genes were sequenced recently for an unrelated treatment, and it appears $he's not the child of the slaves the school stated $he was. He angrily demands compensation for the effort he's put into planning for $him.

	The school's representative is apologetic, but firm. The school readily admits an error, but he protests that they weren't aware of the confusion, either. They've offered to buy $him back, with interest, but reject what they call an exorbitant demand for compensation. They produce the original pedigree, protesting that it shows that they were lied to, too. The slave does resemble the supposed parents closely; only an unusually invasive check would have disclosed the fraud.
<<case "indenture deal">>
	A slutty-looking $girl appears, bearing a split lip and a black eye, accusing a slave trader of tricking $him. $He sends you a lengthy contract of indentured servitude. Nothing seems out of order, though indentured servants are becoming less common, since slave labor is usually cheaper and less limited. The angry accuser claims that the trader told $him that $he wouldn't be required to have sex while indentured. The promise doesn't seem to be in writing, but the $girl bitterly insists that it was made. "And now," $he almost shrieks, "he's making me be a whore. I got assfucked five times yesterday. Five!"

	The trader indignantly denies ever making any such commitment, and points out, correctly, that $he has no proof. He protests that he only made the indentured servitude deal as a favor to $him, and is angry that $he's repaying his courtesy in not insisting on enslavement by this ingratitude. "I see here in the record that $he was indeed used anally five times yesterday," he observes acidly. "But that's $his job."
<<default>>
	A wealthy slaveowner, clearly nursing a ferocious hangover, is accusing a less prominent citizen of refusing to honor the terms of a sale they signed in the early hours of the morning. Already shaking your head, you pull up the security logs with his permission. You verify that yes, indeed, they're visible at a loud party hosted by the wealthy slaveowner, talking over a tablet for a long time before shaking hands and signing.

	The putative buyer protests that though the terms of sale don't show it, their conversation before the sale focused on the slave's virginity. The logs show that this, too, is true. And then, he rages, the slaveowner got even drunker, and brought the slave up to join the party, encouraging other guests to gangbang $him. The logs show this too; the slave is definitely not a virgin any longer. The would-be buyer says he understands that he should have gotten the part about the virginity in writing and guaranteed up until he got his hands on $him, but requests that you honor the spirit of the deal by letting him out of a contract to buy a now-ruined slave.
<</switch>>

<<switch _event>>
<<case "slave deal">>
	<<link "Privately inform both parties you'll settle this in favor of the most generous">>
		<<replace "#result">>
		You privately inform both parties you'll settle this in favor of the most generous. You instantly receive a single notice of escrow payment contingent on the case going the payer's way. You select the @@.yellowgreen;bigger of the two@@ and decide the matter before returning to bed in a good mood. However, the next day it becomes apparent that although $he isn't stupid enough to make a public accusation of corruption, the older $woman made use of $his few remaining hours of freedom to @@.red;slander@@ your administration of justice.
		<<run repX(-100, "event")>>
		<<run cashX(random(150,200)*10, "event")>>
		<</replace>>
	<</link>>

<<link "Settle the dispute in favor of the older $woman">>
		<<replace "#result">>
		You settle the dispute in favor of the slave-to-be. $He is resigned, knowing that $he's now owned by a woman who almost certainly hates $him, but $his daughter's treatments are assured. The story gets around quickly, @@.green;capturing the hearts@@ of more romantic citizens. The angry slave trader leaves the arcology, @@.red;reducing prosperity.@@
		<<set $arcologies[0].prosperity -= 5>>
		<<run repX(2500, "event")>>
		<</replace>>
	<</link>>

<<link "Settle the dispute in favor of the slave trader">>
		<<replace "#result">>
		You settle the dispute in favor of the slave trader. The story of the mother's enslavement, along with the prompt death of the daughter due to inadequate treatment, gets around the Free Cities, @@.red;appalling@@ more romantic citizens. The trader lets it be known amongst her peers that you do not brook uppity behavior from poor bitches, and that slave traders can expect to do well in your arcology, @@.green;increasing prosperity.@@
		<<set $arcologies[0].prosperity += 5>>
		<<run repX(-500, "event")>>
		<</replace>>
	<</link>>

<<link "Offer to buy out the contract">>
		<<run cashX(forceNeg(_ContractCost), "slaveTransfer")>>
		<<replace "#result">>
		You offer to simply buy out the contract, taking the slave for yourself, letting the slave trader out of her side of the deal, and providing for the daughter's medical care. The trader lets it be known amongst her peers that you will make things right no matter the cost to yourself, @@.green;increasing prosperity.@@ The story of the mother willing to be enslaved gets around quickly, @@.green;capturing the hearts@@ of more romantic citizens. The mother, meanwhile, presents $himself for enslavement, @@.hotpink;very grateful@@ that you've saved $his daughter's life.

		<<set $arcologies[0].prosperity += 5>>
		<<run repX(2500, "event")>>
		<<includeDOM App.UI.newSlaveIntro(_slave)>>
		<</replace>>
	<</link>> //This will cost <<print cashFormat(_ContractCost)>> and give you the slave//
<<case "breeding deal">>
	<<link "Privately inform both parties you'll settle this in favor of the most generous">>
		<<replace "#result">>
		You privately inform both parties you'll settle this in favor of the most generous. You instantly receive two notices of escrow payments contingent on the case going the payer's way. You select the @@.yellowgreen;bigger of the two,@@ a clear choice, and decide the matter before returning to bed in a good mood. However, the next day it becomes apparent that although he isn't stupid enough to make a public accusation of corruption, the loser is proclaiming that he is @@.red;not pleased@@ with your administration of justice.
		<<run repX(-100, "event")>>
		<<run cashX(random(150,200)*10, "event")>>
		<</replace>>
	<</link>>

<<link "Settle the dispute in favor of the accuser">>
		<<replace "#result">>
		You settle the dispute in favor of the wealthy accuser. While he is a little disappointed that he didn't get the slave he wanted, he speaks @@.green;positively@@ in public about how you helped protect his investments from potential mismanagement. Slave trading to and from your arcology is @@.red;somewhat lessened@@ however, since the breeder lets it be known that trading in your arcology is a risk.
		<<set $arcologies[0].prosperity -= 5>>
		<<run repX(2500, "event")>>
		<</replace>>
	<</link>>

<<link "Settle the dispute in favor of the breeder">>
		<<replace "#result">>
		You settle the dispute in favor of the slave breeder, and against the prominent accuser, by declaring that the standard paternity test will suffice.
		<<if $seePreg == 1>>
			As if on queue, the $girl's water breaks and soaks $his pants. The call ends to the sight of $his crotch bulging as $his child is born into $his clothing.
		<</if>>
		While he is satisfied with his future slave, he speaks @@.red;openly@@ in public about how you were so quick to use cheap services to settle the claim instead of listening to his requests. The breeder, however, passes a @@.green;good word@@ around the industry that slavers trading with your arcology can expect to be protected from abusive claims.
		<<set $arcologies[0].prosperity += 5>>
		<<run repX(-500, "event")>>
		<</replace>>
	<</link>>

<<link "Compromise on the compensation and offer to buy out the deal">>
		<<run cashX(forceNeg(_ContractCost), "slaveTransfer")>>
		<<replace "#result">>
		You offer to buy out the deal, paying the breeder and taking the slave yourself, and passing the child off to the buyer. The citizen gets what he wants and speaks @@.green;kindly@@ in public about how you helped smooth over a rather rough dispute. The breeder sends a @@.green;positive note@@ around the industry to the effect that slavers trading with your arcology can expect to be aided in times of need; though the loss of a star mother always stings.

		<<set $arcologies[0].prosperity += 3>>
		<<run repX(300, "event")>>
		<<includeDOM App.UI.newSlaveIntro(_slave)>>
		<</replace>>
	<</link>> //This will cost <<print cashFormat(_ContractCost)>> and give you the slave//
<<case "slave training">>
	<<link "Privately inform both parties you'll settle this in favor of the most generous">>
		<<replace "#result">>
		You privately inform both parties you'll settle this in favor of the most generous. You instantly receive two notices of escrow payments contingent on the case going the payer's way. You select the @@.yellowgreen;bigger of the two@@ and decide the matter before returning to bed in a good mood. However, the next day it becomes apparent that although he isn't stupid enough to make a public accusation of corruption, the loser is proclaiming that he is @@.red;not pleased@@ with your administration of justice.
		<<run repX(-100, "event")>>
		<<run cashX(random(150,200)*10, "event")>>
		<</replace>>
	<</link>>

<<link "Settle the dispute in favor of the accuser">>
		<<replace "#result">>
		You settle the dispute in favor of the wealthy accuser. He lets you know privately that he recently had a business deal go bad, so he's in a tough cash situation right now; he's so grateful for your assistance in this embarrassing situation that he talks @@.green;effusively@@ for days to anyone who will listen about your good administration of the arcology. Unfortunately, the furious trainer has packed up his equipment and his gelding and left for another arcology, somewhat @@.red;reducing prosperity.@@
		<<set $arcologies[0].prosperity -= 5>>
		<<run repX(2500, "event")>>
		<</replace>>
	<</link>>

<<link "Settle the dispute in favor of the trainer">>
		<<replace "#result">>
		You settle the dispute in favor of the slave trainer. It transpires that the wealthy accuser was no longer wealthy at all, and was looking to get out of the deal; he's furious, and spends a long day @@.red;spewing invectives@@ against you to anyone who will listen before decamping back to the old world. The trainer, on the other hand, lets it be known that you support businessmen, who can trust you to look after their interests, @@.green;increasing prosperity.@@
		<<set $arcologies[0].prosperity += 5>>
		<<run repX(-500, "event")>>
		<</replace>>
	<</link>>

<<link "Offer to buy out the deal">>
		<<run cashX(forceNeg(_ContractCost), "slaveTransfer")>>
		<<replace "#result">>
		You offer to simply buy out the deal, paying the trainer and taking the slave yourself, and letting the buyer out of the payment. The trainer lets it be known that you support businessmen, who can trust you to ensure they don't come out second best, @@.green;increasing prosperity.@@ The buyer lets you know privately that he recently had a business deal go bad, so he's in a tough cash situation right now; he's so grateful for your assistance in this embarrassing situation that he talks @@.green;effusively@@ for days to anyone who will listen about your discreet administration of the arcology. The slave, meanwhile, arrives at your penthouse, @@.hotpink;rather hopeful@@ that $he's going to a good master.

		<<set $arcologies[0].prosperity += 5>>
		<<run repX(2500, "event")>>
		<<includeDOM App.UI.newSlaveIntro(_slave)>>
		<</replace>>
	<</link>> //This will cost <<print cashFormat(_ContractCost)>> and give you the slave//
<<case "majority deal">>
	<<link "Privately inform both parties you'll settle this in favor of the most generous">>
		<<replace "#result">>
		You privately inform both parties you'll settle this in favor of the most generous. You instantly receive two notices of escrow payments contingent on the case going the payer's way. You select the @@.yellowgreen;bigger of the two@@ and decide the matter before returning to bed in a good mood. However, the next day it becomes apparent that although he isn't stupid enough to make a public accusation of corruption, the loser is proclaiming that he is @@.red;not pleased@@ with your administration of justice.
		<<run repX(-100, "event")>>
		<<run cashX(random(150,200)*10, "event")>>
		<</replace>>
	<</link>>

<<link "Settle the dispute in favor of the accuser">>
		<<replace "#result">>
		You settle the dispute in favor of the prominent accuser. He dabbles in slave breeding himself, and was looking forward to using the slave in question for breeding stock; like many breeders he cares deeply about his stable, and speaks @@.green;positively@@ in public about how you helped an innocent breeder protect his prize bloodlines. Slave trading to and from your arcology is @@.red;somewhat lessened@@ however, since the school lets it be known that trading in your arcology is a risk.
		<<set $arcologies[0].prosperity -= 5>>
		<<run repX(2500, "event")>>
		<</replace>>
	<</link>>

<<link "Settle the dispute in favor of the trainer">>
		<<replace "#result">>
		You settle the dispute in favor of the school, and against the prominent accuser. He dabbles in slave breeding himself, and was looking forward to using the slave in question for breeding stock; like many breeders he cares deeply about his stable, and speaks @@.red;furiously@@ in public about how you denied an innocent breeder justice against those swindling slave schools. The school, however, passes a @@.green;good word@@ around the industry that schools trading with your arcology can expect to be protected from frivolous claims.
		<<set $arcologies[0].prosperity += 5>>
		<<run repX(-500, "event")>>
		<</replace>>
	<</link>>

<<link "Compromise on the compensation and offer to buy out the deal">>
		<<run cashX(forceNeg(_ContractCost), "slaveTransfer")>>
		<<replace "#result">>
		You offer to buy out the deal, paying the school and taking the slave yourself, and compromising on the demanded compensation. The citizen was looking forward to using the slave in question for breeding stock; like many breeders he cares deeply about his stable and is mollified by the moderate payment, and speaks @@.green;kindly@@ in public about how you helped an innocent breeder protect his prize bloodlines. The school sends a @@.green;positive note@@ around the industry to the effect that schools trading with your arcology can expect to have excessive claims sensibly reduced.

		<<set $arcologies[0].prosperity += 3>>
		<<run repX(1500, "event")>>
		<<includeDOM App.UI.newSlaveIntro(_slave)>>
		<</replace>>
	<</link>> //This will cost <<print cashFormat(_ContractCost)>> and give you the slave//
<<case "indenture deal">>
	<<link "Privately inform both parties you'll settle this in favor of the most generous">>
		<<replace "#result">>
		You privately inform both parties you'll settle this in favor of the most generous. You instantly receive a single notice of escrow payment contingent on the case going the payer's way. You select the @@.yellowgreen;bigger of the two@@ and decide the matter before returning to bed in a good mood. However, the next day it becomes apparent that although $he isn't stupid enough to make a public accusation, the whore has been @@.red;whispering@@ to $his peers that you helped the trader cheat $him into prostitution. Few citizens care, but there is a faint scent of corruption.
		<<run repX(-50, "event")>>
		<<run cashX(random(150,200)*10, "event")>>
		<</replace>>
	<</link>>

<<link "Settle the dispute in favor of the indentured whore">>
		<<replace "#result">>
		You settle the dispute in favor of the indentured whore, adding a requirement to the indentured servitude that $he not be required to fuck against $his will. The story of the brave prostitute and the conniving trader is @@.green;told and retold,@@ impressing the more credulous citizens. It also @@.red;raises doubts@@ among the wealthier, more business-minded residents about whether you can be depended on to promote their interests.
		<<set $arcologies[0].prosperity -= 5>>
		<<run repX(2500, "event")>>
		<</replace>>
	<</link>>

<<link "Settle the dispute in favor of the indenture holder">>
		<<replace "#result">>
		You settle the dispute in favor of the owner of the indenture. No change in the contract is necessary, since it already says what it should: that he controls $him for the required period. That's all. The story of your strictness in business disputes @@.green;impresses@@ some of the more commercially powerful citizens of the arcology, but is @@.red;hissed@@ by the stupider, more romantic residents, who see only a brave whore being beaten down by a conniving slave trader.
		<<set $arcologies[0].prosperity += 5>>
		<<run repX(-500, "event")>>
		<</replace>>
	<</link>>

<<link "Buy out the contract and $his indenture">>
		<<set _slave.devotion = random(10,15)>>
		<<set _slave.trust = _slave.devotion+4>>
		<<set _slave.oldDevotion = _slave.devotion>>
		<<set _slave.indenture = random(52,78)>>
		<<set _slave.indentureRestrictions = 2>>
		<<set _slave.origin = "You took over $his indenture after $he launched a legal complaint against an abusive master.">>
		<<run cashX(forceNeg(_ContractCost), "slaveTransfer")>>
		<<replace "#result">>
			You offer to simply buy out the indenture contract, thereby acquiring $him, to which both parties readily agree. This decision is viewed as @@.green;incredibly generous@@ by both your arcology's romantically-minded and financially-inclined citizens. For their part, your new servant is hopeful that you will be more considerate of $his health, while the former holder is just happy to have $him off his hands.

			<<set $arcologies[0].prosperity += 3>>
			<<run repX(1500, "event")>>
			<<includeDOM App.UI.newSlaveIntro(_slave)>>
		<</replace>>
	<</link>> //This will cost <<print cashFormat(_ContractCost)>> and give you the servant as such//

<<link "Buy out the contract and enslave $him">>
		<<set _slave.origin = "$He was enslaved after you manipulated $his deal for indentured servitude.">>
		<<set _slave.devotion = random(-10,-15)>>
		<<set _slave.trust = _slave.devotion+4>>
		<<set _slave.oldDevotion = _slave.devotion>>
		<<run cashX(forceNeg(_ContractCost), "slaveTransfer")>>
		<<replace "#result">>
			You quietly contact the trader and suggest an alternative method of settling the dispute. He is surprised, but agrees readily, chuckling at how the "recalcitrant bitch" is going to be dealt with. To $his horror, $he finds that your near-total power over deals made in your arcology has been employed to saddle $him with additional debts that, under $his indentured servitude, $he cannot hope to repay. It is then the work of ten minutes to demand payment, and when $he cannot pay, demand $his body for enslavement. The story of your cunning @@.green;impresses@@ the slave traders, but is @@.red;booed@@ by fairer-minded citizens.

			<<set $arcologies[0].prosperity += 5>>
			<<run repX(-100, "event")>>
			<<includeDOM App.UI.newSlaveIntro(_slave)>>
		<</replace>>
	<</link>> //This will cost <<print cashFormat(_ContractCost)>> and give you the servant as a slave//
<<default>>
	<<link "Privately inform both parties you'll settle this in favor of the most generous">>
		<<replace "#result">>
		You privately inform both parties you'll settle this in favor of the most generous. You instantly receive two notices of escrow payment contingent on the case going the payer's way. You select the @@.yellowgreen;bigger of the two@@ and decide the matter before returning to bed in a good mood. However, the next day it becomes apparent that although he isn't stupid enough to make a public accusation of corruption, the buyer is furious at paying virgin prices for a defiled slave, and is privately @@.red;slandering@@ your administration of justice.
		<<run repX(-100, "event")>>
		<<run cashX(random(150,200)*10, "event")>>
		<</replace>>
	<</link>>

<<link "Settle the dispute in favor of the prospective buyer">>
		<<replace "#result">>
		What's most important is the justice of the outcome. You settle the dispute in favor of the buyer, who would otherwise be forced to buy something he did not mean to pay for. He lets it be known far and wide that you are willing to stand up for what's right, no matter what and no matter who, @@.green;improving@@ your reputation. The angry seller, now afflicted with a devalued slave in addition to a bad headache, lets his group of friends know that social superiors have no advantage at justice here. They become more reticent about deal-making in your arcology, @@.red;damaging@@ its prosperity.
		<<set $arcologies[0].prosperity -= 5>>
		<<run repX(2500, "event")>>
		<</replace>>
	<</link>>

<<link "Settle the dispute in favor of the prominent slaveowner">>
		<<replace "#result">>
		A deal is a deal; buyer beware. You settle the dispute in favor of the slaveowner. He lets it be known amongst his peers that you do not let social inferiors insist on justice against their betters. Citizens of quality become more willing to consider deal-making in your arcology, @@.green;increasing prosperity.@@ On the other hand, the angry buyer shows himself to be not a person to treat lightly, either; he maintains a @@.red;malicious@@ whispering campaign to the effect that your administration of justice is fatally biased.
		<<set $arcologies[0].prosperity += 5>>
		<<run repX(-500, "event")>>
		<</replace>>
	<</link>>

<<link "Offer to buy out the contract">>
		<<run cashX(forceNeg(_ContractCost), "slaveTransfer")>>
		<<replace "#result">>
		You offer to simply buy out the contract, taking the slave for yourself. This lets the buyer out of buying $him, and the slaveowner gets his money; but it soon becomes apparent that what both of them were really looking for is an opportunity to put one over on the other. Neither is pleased to be denied a petty victory, but they both have the sense to keep their mouths shut. The poor slave, meanwhile, appears in the penthouse entryway, @@.hotpink;hopeful@@ that $he's been lucky enough to end up in a less abusive situation.

		<<includeDOM App.UI.newSlaveIntro(_slave)>>
		<</replace>>
	<</link>> //This will cost <<print cashFormat(_ContractCost)>> and give you the slave//
<</switch>>


code:
:: Madam Select [nobr jump-to-safe jump-hidden jump-from-safe]

<<set $nextButton = "Back", $nextLink = "Brothel", $encyclopedia = "Madam">>
<<if ($MadamID != 0)>>
	<<setLocalPronouns _S.Madam>>
	<<= SlaveFullName(_S.Madam)>> is serving as your Madam.

$He will manage the brothel.
<<else>>
	You have not selected a Madam.
<</if>>

''Appoint a Madam from your devoted slaves:''

[[None|Brothel][removeJob(_S.Madam, "be the Madam")]]

<<includeDOM App.UI.SlaveList.facilityManagerSelection(App.Entity.facilities.brothel, "Brothel")>>


code:
:: Main [nobr jump-to-safe jump-from-safe]

<<includeDOM App.MainView.errors()>>

<<set $nextButton = "END WEEK", $nextLink = "End Week", $encyclopedia = "How to Play">>

<<if $tabChoice.SlaveInteract != 'Description'>>
	<<set $tabChoice.SlaveInteract = 'Description'>>
<</if>>

<<run penthouseCensus()>>

<<set $costs = Math.trunc(calculateCosts.predict())>>

<<set $currentRule = $defaultRules[0]>>

<<run SlaveSort.slaves($slaves)>>

<<if $newModelUI == 1>>
    <<includeDOM V.building.render()>>
<</if>>

<<if $seeArcology == 1>>
    <<includeDOM App.Desc.playerArcology(App.UI.DOM.combineNodes("| ", App.UI.DOM.passageLink("Hide", "Main", () => {V.seeArcology = 0})))>>
<</if>>

<<if $seeDesk == 1>>
	<<include "Office Description">>
	[[Hide|Main][$seeDesk = 0]]
<</if>>

<<includeDOM App.MainView.full()>>

<<run App.UI.SlaveList.ScrollPosition.restore()>>