code:
:: Main [nobr]

<<if $ver.contains("0.9") or $ver.contains("0.8") or $ver.contains("0.7") or $ver.contains("0.6")>>
	<<if ($ver != "0.9.7") && ($ver != "0.9.8") && ($ver != "0.9.9") && ($ver != "0.9.10")>>
		''@@color:red;INCOMPATIBLE SAVE WARNING:@@'' your saved game was created using version $ver and you are using version 0.9.8. Please select New Game Plus from the Options menu or start a new game.

	<</if>>
<<else>>
	''@@color:red;INCOMPATIBLE SAVE WARNING:@@'' your saved game was created using version $ver and you are using later version which New Game Plus cannot reconcile. Please start a new game.

<</if>>

<<if ndef $defaultRules>>
	<<include "Init Rules">>
<</if>>
<<if ndef $inbreeding>>
	<<set $inbreeding = 1>>
<</if>>
<<if ndef $incubatorWeightSetting>>
	<<set $incubatorWeightSetting = 0>>
<</if>>
<<if ndef $incubatorMusclesSetting>>
	<<set $incubatorMusclesSetting = 0>>
<</if>>
<<if ndef $incubatorReproductionSetting>>
 	<<set $incubatorReproductionSetting = 0>>
<</if>>
<<if ndef $clinicUpgradePurge>>
 	<<set $clinicUpgradePurge = 0>>
<</if>>
<<if ndef $pregSpeedControl>>
	<<set $pregSpeedControl = 0>>
<</if>>
<<if ndef $clinicSpeedGestation>>
	<<set $clinicSpeedGestation = 0>>
<</if>>
<<if ndef $playerAging>>
 	<<set $playerAging = 0>>
<</if>>
<<if ndef $PC.intelligence>>
	<<set $PC.intelligence = 3>>
<</if>>
<<if ndef $PC.face>>
	<<set $PC.face = 3>>
<</if>>
<<if ndef $PC.actualAge>>
	<<if $PC.age == 1>>
		<<set $PC.actualAge = 20>>
	<<elseif $PC.age == 2>>
		<<set $PC.actualAge = 35>>
	<<elseif $PC.age == 3>>
		<<set $PC.actualAge = 50>>
	<</if>>
<</if>>
<<if ndef $PC.visualAge>>
	<<set $PC.visualAge = $PC.actualAge>>
<</if>>
<<if ndef $PC.physicalAge>>
	<<set $PC.physicalAge = $PC.actualAge>>
<</if>>
<<if ndef $PC.birthWeek>>
	<<set $PC.birthWeek = 0>>
<</if>>
<<if ndef $PC.boobsImplant>>
	<<set $PC.boobsImplant = 0>>
<</if>>
<<if ndef $PC.butt>>
	<<set $PC.butt = 0>>
<</if>>
<<if ndef $PC.buttImplant>>
	<<set $PC.buttImplant = 0>>
<</if>>
<<if ndef $PC.ballsImplant>>
	<<set $PC.ballsImplant = 0>>
<</if>>
<<if ndef $PC.ageImplant>>
	<<set $PC.ageImplant = 0>>
<</if>>
<<if ndef $playerSurgery>>
	<<set $playerSurgery = 0>>
<</if>>
<<if ndef $playerSurgeryType>>
	<<set $playerSurgeryType = 0>>
<</if>>

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

<<switch $sortSlavesBy>>
<<case "name">>
	<<if ($sortSlavesOrder is "ascending")>>
	<<set $slaves to $slaves.sort(function(a, b){if(a.slaveName  b.slaveName) return 1; return 0;})>>
	<<else>>
	<<set $slaves to $slaves.sort(function(a, b){if(a.slaveName > b.slaveName) return -1; if(a.slaveName >
	<</if>>
<<case "assignment">>
	<<if ($sortSlavesOrder is "ascending")>>
	<<set $slaves to $slaves.sort(function(a, b){if(a.assignment  b.assignment) return 1; return 0;})>>
	<<else>>
	<<set $slaves to $slaves.sort(function(a, b){if(a.assignment > b.assignment) return -1; if(a.assignment >
	<</if>>
<<case "seniority">>
	<<if ($sortSlavesOrder is "ascending")>>
	<<set $slaves to $slaves.sort(function(a, b){return b.weekAcquired-a.weekAcquired})>>
	<<else>>
	<<set $slaves to $slaves.sort(function(a, b){return a.weekAcquired-b.weekAcquired})>>
	<</if>>
<<case "age">>
	<<if ($sortSlavesOrder is "ascending")>>
	<<set $slaves to $slaves.sort(function(a, b){return a.actualAge-b.actualAge})>>
	<<else>>
	<<set $slaves to $slaves.sort(function(a, b){return b.actualAge-a.actualAge})>>
	<</if>>
<<default>>
	<<if ($sortSlavesOrder is "ascending")>>
	<<set $slaves to $slaves.sort(function(a, b){return a.devotion-b.devotion})>>
	<<else>>
	<<set $slaves to $slaves.sort(function(a, b){return b.devotion-a.devotion})>>
	<</if>>
<</switch>>

<<set $dormitoryPopulation to 0>>
<<set $roomsPopulation to 0>>
<<set $slavesVisible to 0>>
<<set _PA to -1>>
<<set _HG to -1>>
<<set _RC to -1>>
<<set _BG to -1>>

<<for $i to 0; $i < $slaves.length; $i++>>
	<<if $slaves[$i].assignmentVisible == 1>>
		<<set $slavesVisible++>>
		<<if $slaves[$i].livingRules is "luxurious">>
			<<if $slaves[$i].relationship >= 4>>
			  <<set $roomsPopulation += 0.5>>
			<<else>>
			  <<set $roomsPopulation++>>
			<</if>>
		<<else>>
			<<set $dormitoryPopulation++>>
		<</if>>
	<</if>>
	<<if $personalAttention == $slaves[$i].ID>>
		<<set _PA to $i>>
	<</if>>
	<<if $HeadGirl.ID == $slaves[$i].ID>>
		<<set _HG to $i>>
		<<continue>>
	<<elseif $Recruiter.ID == $slaves[$i].ID>>
		<<set _RC to $i>>
		<<continue>>
	<<elseif $Bodyguard.ID == $slaves[$i].ID>>
		<<set _BG to $i>>
		<<continue>>
	<</if>>
<</for>>

<<set $nextButton to "END WEEK">>
<<set $nextLink to "End Week">>
<<set $showEncyclopedia to 1>><<set $encyclopedia to "How to Play">>
<<include "Costs">>

<<if ($arcologies[0].name is "")>>
	<<set $arcologies[0].name to "Arcology X-4">>
<</if>>
<<if ($PC.customTitle is "")>>
	<<set $PC.customTitle to undefined>>
	<<set $PC.customTitleLisp to undefined>>
<</if>>
<<if ($brothelName is "")>>
	<<set $brothelName to "the Brothel">>
<</if>>
<<if ($brothelNameCaps is "")>>
	<<set $brothelNameCaps to "The Brothel">>
<</if>>
<<if ($dairyName is "")>>
	<<set $dairyName = "the Dairy">>
<</if>>
<<if ($dairyNameCaps is "")>>
	<<set $dairyNameCaps = "The Dairy">>
<</if>>
<<if ($clubName is "")>>
	<<set $clubName = "the Club">>
<</if>>
<<if ($clubNameCaps is "")>>
	<<set $clubNameCaps = "The Club">>
<</if>>
<<if ($servantsQuartersName is "")>>
	<<set $servantsQuartersName = "the Servants' Quarters">>
<</if>>
<<if ($servantsQuartersNameCaps is "")>>
	<<set $servantsQuartersNameCaps = "The Servants' Quarters">>
<</if>>
<<if ($schoolroomName is "")>>
	<<set $schoolroomName = "the Schoolroom">>
<</if>>
<<if ($schoolroomNameCaps is "")>>
	<<set $schoolroomNameCaps = "The Schoolroom">>
<</if>>
<<if ($spaName is "")>>
	<<set $spaName = "the Spa">>
<</if>>
<<if ($spaNameCaps is "")>>
	<<set $spaNameCaps = "The Spa">>
<</if>>
<<if ($clinicName is "")>>
	<<set $clinicName = "the Clinic">>
<</if>>
<<if ($clinicNameCaps is "")>>
	<<set $clinicNameCaps = "The Clinic">>
<</if>>
<<if ($arcadeName is "")>>
	<<set $arcadeName = "the Arcade">>
<</if>>
<<if ($arcadeNameCaps is "")>>
	<<set $arcadeNameCaps = "The Arcade">>
<</if>>
<<if ($cellblockName is "")>>
	<<set $cellblockName = "the Cellblock">>
<</if>>
<<if ($cellblockNameCaps  is "")>>
	<<set $cellblockNameCaps = "The Cellblock">>
<</if>>
<<if ($masterSuiteName is "")>>
	<<set $masterSuiteName = "the Master Suite">>
<</if>>
<<if ($masterSuiteNameCaps is "")>>
	<<set $masterSuiteNameCaps = "The Master Suite">>
<</if>>
<<if ($HGSuiteName is "")>>
	<<set $HGSuiteName = "the Head Girl Suite">>
<</if>>
<<if ($HGSuiteNameCaps is "")>>
	<<set $HGSuiteNameCaps = "The Head Girl Suite">>
<</if>>
<<if ($pitName is "")>>
	<<set $pitName = "the Pit">>
<</if>>
<<if ($pitNameCaps is "")>>
	<<set $pitNameCaps = "The Pit">>
<</if>>
<<if ($incubatorName is "")>>
	<<set $incubatorName = "the Incubator">>
<</if>>
<<if ($incubatorNameCaps is "")>>
	<<set $incubatorNameCaps = "The Incubator">>
<</if>>

<<if $seeArcology == 1>>    //<<include "Arcology Description">> | [[Hide|Main][$seeArcology to 0]]//
<</if>>

<<if $seeDesk == 1>>
<<include "Office Description">>
//[[Hide|Main][$seeDesk to 0]]//
<</if>>
<<if $seeFCNN == 1>>FCNN: <<print $fcnn.random()>>//[[Hide|Main][$seeFCNN to 0]]//<</if>>
<<if ($seeDesk == 1) && ($seeFCNN == 0)>>
<</if>>

__''MAIN MENU''__    //[[Summary Options]]
<<if $rulesAssistantMain != 0>>
| [[Rules Assistant Options|Rules Assistant]]
<<if $rulesAssistantAuto != 1>>
	| <<link "Apply Rules Assistant at week end">><<set $rulesAssistantAuto to 1>><<goto "Main">><</link>>
<<else>>
	| <<link "Stop applying Rules Assistant at week end">><<set $rulesAssistantAuto to 0>><<goto "Main">><</link>>
<</if>>
| <<link "Activate Rules Assistant">><<for $i to 0; $i < $slaves.length; $i++>><<if $slaves[$i].useRulesAssistant == 1>><<if $slaves[$i].assignmentVisible == 1>><<set $activeSlave to $slaves[$i]>><<include "Default Rules">><<set $slaves[$i] to $activeSlave>><</if>><</if>><</for>><<goto "Main">><</link>>
<</if>>
<<if $sortSlavesMain != 0>>

    Sort by:
	<<if $sortSlavesBy != "devotion">>[[Devotion|Main][$sortSlavesBy to "devotion"]]<<else>>Devotion<</if>> |
	<<if $sortSlavesBy != "name">>[[Name|Main][$sortSlavesBy to "name"]]<<else>>Name<</if>> |
	<<if $sortSlavesBy != "assignment">>[[Assignment|Main][$sortSlavesBy to "assignment"]]<<else>>Assignment<</if>> |
	<<if $sortSlavesBy != "seniority">>[[Seniority purchased|Main][$sortSlavesBy to "seniority"]]<<else>>Seniority<</if>> |
	<<if $sortSlavesBy != "age">>[[Age|Main][$sortSlavesBy to "age"]]<<else>>Age<</if>> |
	Sort: <<if $sortSlavesOrder != "descending">>[[Descending|Main][$sortSlavesOrder to "descending"]]<<else>>Descending<</if>> |
	<<if $sortSlavesOrder != "ascending">>[[Ascending|Main][$sortSlavesOrder to "ascending"]]<<else>>Ascending<</if>>
<</if>>//
<<if $positionMainLinks >= 0>>
	<<MainLinks>>
<</if>>

<<include "Slave Summary">>

<<if $lineSeparations == 0>>
<<else>>
<</if>>
<<if $positionMainLinks <= 0>>
	<<MainLinks>>
<</if>>

<<set $j to "Back",$k to "AS Dump",$l to "Main">>
<<for $i to 0; $i < $slaves.length; $i++>>
<<if ($slaves[$i].assignment is "please you")>>

<<include "Toychest">> //In the coming week you plan to concentrate on
	<<if $slaves[$i].fuckdoll == 0>>
		<<if $slaves[$i].toyHole != "all her holes">>
			her $slaves[$i].toyHole, but for now://

    <<print "[[Use her mouth|FLips][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">> | <<print "[[Play with her tits|FBoobs][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
			<<if canDoVaginal($slaves[$i])>>
				| <<print "[[Fuck her|FVagina][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
				<<if canDoAnal($slaves[$i])>>
				| <<print "[[Use her holes|FButt][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
				<</if>>
			<</if>>
			<<if canDoAnal($slaves[$i])>>
			| <<print "[[Fuck her ass|FAnus][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
			<</if>>
			/*check*/
			<<if canAchieveErection($slaves[$i])>>
			| <<print "[[Ride her|FDick][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
			<</if>>
			| <<print "[[Abuse her|FAbuse][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
		<<else>>
			all of her holes equally, but for now://

    <<print "[[Use her mouth|FLips][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">> | <<print "[[Play with her tits|FBoobs][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
			<<if canDoVaginal($slaves[$i])>>
				| <<print "[[Fuck her|FVagina][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
				<<if canDoAnal($slaves[$i])>>
				| <<print "[[Use her holes|FButt][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
				<</if>>
			<</if>>
			<<if canDoAnal($slaves[$i])>>
			| <<print "[[Fuck her ass|FAnus][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
			<</if>>
			/*check*/
			<<if canAchieveErection($slaves[$i])>>
			| <<print "[[Ride her|FDick][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
			<</if>>
			| <<print "[[Abuse her|FAbuse][$activeSlave to $slaves[" + $i + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
		<</if>>
	<<else>>
		<<if $slaves[$i].toyHole != "all her holes">>
			its $slaves[$i].toyHole.
		<<else>>
			all of its holes.
		<</if>>
	<</if>>
<</if>>
<</for>>

<<set $j to "Back",$k to "AS Dump",$l to "Main">>
<<if (_BG > -1) && ($slaves[_BG].assignment is "guard you")>>
	<<set $i to _BG>>
	<<set $GO to "idiot ball">>

<<include "Use Guard">>

    <<print "[[Use her mouth|FLips][$activeSlave to $slaves[" + _BG + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
	| <<print "[[Play with her tits|FBoobs][$activeSlave to $slaves[" + _BG + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
	<<if canDoVaginal($slaves[_BG])>>
		| <<print "[[Fuck her|FVagina][$activeSlave to $slaves[" + _BG + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
		<<if canDoAnal($slaves[_BG])>>
		| <<print "[[Use her holes|FButt][$activeSlave to $slaves[" + _BG + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
		<</if>>
	<</if>>
		/*check*/
		<<if canAchieveErection($slaves[_BG])>>
		| <<print "[[Ride her|FDick][$activeSlave to $slaves[" + _BG + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
	<</if>>
	<<if canDoAnal($slaves[_BG])>>
	| <<print "[[Fuck her ass|FAnus][$activeSlave to $slaves[" + _BG + "],$nextButton to $j,$nextLink to $k,$returnTo to $l]]">>
	<</if>>
	| <<print "[[Abuse her|Gameover][$gameover to $GO]]">>
<</if>>

<<set $activeSlave to Array.random($slaves)>>
<<if ($activeSlave.assignment != "please you") && ($activeSlave.assignment != "guard you")>>

<<include "Walk Past">>
<</if>>


code:
:: Manage Arcology [nobr]

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

<<if $cheatMode == 1>>

//[[Cheat Edit Arcology|MOD_Edit Arcology Cheat][$cheater to 1]]//

<</if>>
<<set $showEncyclopedia to 0>>

<<include "Arcology Description">>

__Arcology Ownership__
You own ''$arcologies[0].ownership%'' of $arcologies[0].name, <<if $arcologies[0].minority > 0>>against ''$arcologies[0].minority%'' owned by the second most significant holder<<else>>and there are no other significant holders<</if>>.
<<if $arcologies[0].minority > $arcologies[0].ownership-10>>
	@@color:red;This is a dangerously narrow margin of control.@@
<</if>>
<<set $price to 500*Math.trunc($arcologies[0].prosperity*(1+($arcologies[0].demandFactor/100)))>>
A 1% interest in $arcologies[0].name is worth ¤$price and will require a transaction cost of ¤10000 to acquire.

<<if $arcologies[0].ownership+$arcologies[0].minority < 100>>
	[[Buy|Manage Arcology][$cash -= $price+10000, $arcologies[0].ownership += 1, $arcologies[0].demandFactor += 5]]
<<else>>Buy<</if>> |
[[Sell|Manage Arcology][$cash += $price, $arcologies[0].ownership -= 1, $arcologies[0].demandFactor -= 5]]
<<if $arcologies[0].ownership+$arcologies[0].minority < 100>>
<<if $rep >= 10000>>

	<<set $repPrice = Math.clamp($price/2, 0, 10000)>>
	You have so much political capital that you can spend reputation to  acquire ownership by spending reputation. [[Use reputation|Manage Arcology][$rep -= $repPrice, $arcologies[0].ownership += 1, $arcologies[0].demandFactor += 5]]
<</if>>
<</if>>

<<if $FSAnnounced > 0>>
	<<if $FSCredits > 0>>

		@@color:yellow;$arcologies[0].name's society is ready to begin accepting a new societal direction.@@
	<</if>>
<</if>>

__Construction__

<<if $AProsperityCap <= 60>>
	//The first major upgrade needed is the installation of a drone security system so higher-class citizens will feel safe and protected should they choose to immigrate. This upgrade will cost ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>.// [[Install drone security system|Manage Arcology][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $AProsperityCap += 20]]
<<elseif $AProsperityCap <= 80>>
	//The next major upgrade needed is the installation of a better water reclamation system so your residents will have access to cheaper water and hydroponically grown food. This upgrade will cost ¤<<print Math.trunc(10000*$upgradeMultiplierArcology)>>.// [[Upgrade water reclamation system|Manage Arcology][$cash -= Math.trunc(10000*$upgradeMultiplierArcology), $AProsperityCap += 20]]
<<elseif $AProsperityCap <= 100>>
	//The next major upgrade needed is the installation of a broader apron at the bottom of the arcology to increase its surface area and gather more solar energy. Right now, tenants that use a lot of power have to import it from outside. This upgrade will cost ¤<<print Math.trunc(20000*$upgradeMultiplierArcology)>>.// [[Install solar apron|Manage Arcology][$cash -= Math.trunc(20000*$upgradeMultiplierArcology), $AProsperityCap += 20]]
<<elseif $AProsperityCap <= 120>>
	//The next major upgrade needed is an improvement of the arcology's electrical transmission lines to make efficient use of the additional power from the solar apron. This upgrade will cost ¤<<print Math.trunc(50000*$upgradeMultiplierArcology)>>.// [[Upgrade transmission lines|Manage Arcology][$cash -= Math.trunc(50000*$upgradeMultiplierArcology), $AProsperityCap += 30]]
<<elseif $AProsperityCap <= 150>>
	//The next major upgrade needed is an overhaul of the commercial floors. As the arcology has become prosperous a better class of citizen has started to look for a higher class of establishment. These renovations will cost ¤<<print Math.trunc(100000*$upgradeMultiplierArcology)>>.// [[Renovate commercial floors|Manage Arcology][$cash -= Math.trunc(100000*$upgradeMultiplierArcology), $AProsperityCap += 40]]
<<elseif $AProsperityCap <= 190>>
	//The next major upgrade needed is an overhaul of the residential floors. As the arcology has become prosperous a better class of citizen has started to look for a higher class of living quarters. These renovations will cost ¤<<print Math.trunc(200000*$upgradeMultiplierArcology)>>.// [[Renovate residential floors|Manage Arcology][$cash -= Math.trunc(200000*$upgradeMultiplierArcology), $AProsperityCap += 50]]
<<elseif $AProsperityCap <= 240>>
	//The next major upgrade needed is the addition of a spire at the top of the arcology to increase the space available for the wealthiest citizens to own whole floors. This huge project will cost ¤<<print Math.trunc(250000*$upgradeMultiplierArcology)>>.// [[Add spire|Manage Arcology][$cash -= Math.trunc(250000*$upgradeMultiplierArcology), $AProsperityCap += 60]]
<<else>>
	//The arcology's public areas are fully upgraded.//
<</if>>
<<if ($PC.career == "engineer") || ($PC.career == "arcology owner")>>
<<if $AProsperityCap < 360>>
	//Arcology upgrades are less expensive due to your @@color:springgreen;<<if $PC.career == "arcology owner">>experience in the Free Cities<<else>>arcology engineering career<</if>>.@@//
<</if>>
<</if>>

<<if $weatherCladding == 0>>
	//Extreme weather is becoming common worldwide. The arcology's exterior can be hardened to reduce damage in case of heavy weather, but this will reduce its beauty somewhat and will cost ¤<<print Math.trunc(50000*$upgradeMultiplierArcology)>>. Your citizens are <<if $weatherAwareness == 0>>likely to disapprove of this measure as alarmism.<<else>>@@color:yellow;concerned that this measure has not been taken already.@@<</if>> // [[Apply weather cladding|Manage Arcology][$cash -= Math.trunc(50000*$upgradeMultiplierArcology), $weatherCladding to 1]]
<<elseif $weatherCladding == 1 && $AProsperityCap is 300>>
	The arcology's exterior is jacketed with unsightly but sturdy weather cladding. Your arcology is so prosperous that remodeling the cladding into something beautiful is within the realm of possibility. This massive project will cost ¤<<print Math.trunc(3500000*$upgradeMultiplierArcology)>> and without a doubt render your arcology one of the wonders of the world.
[[Remodel weather cladding|Manage Arcology][$cash -= Math.trunc(3500000*$upgradeMultiplierArcology), $weatherCladding to 2, $AProsperityCap to 360]]
<<elseif $weatherCladding == 1>>
	//The arcology's exterior is jacketed with unsightly but sturdy weather cladding.//
<<elseif $weatherCladding == 2>>
	//The arcology's exterior is jacketed with gorgeously sculpted and fully functional weather cladding.//
<</if>>

__Facilities__

<<if $brothel == 0>>
	[[Combine empty apartments into a brothel|Manage Arcology][$cash -= Math.trunc(10000*$upgradeMultiplierArcology), $brothel to 5]]
	//Costs ¤<<print Math.trunc(10000*$upgradeMultiplierArcology)>> and will incur upkeep costs//
<<elseif $brothel > 0>>
	A brothel has been installed directly below your penthouse. It can support <<print $brothel>> whores.
<</if>>

<<if $club == 0>>
	[[Build a club to serve as a focal point for public sluts|Manage Arcology][$cash -= Math.trunc(10000*$upgradeMultiplierArcology), $club to 5]]
	//Costs ¤<<print Math.trunc(10000*$upgradeMultiplierArcology)>> and will incur upkeep costs//
<<elseif $club > 0>>
	There are rooms off the club to support slaves as they please citizens. They can support <<print $club>> sluts.
<</if>>

<<if $arcade == 0>>
	[[Construct a sex arcade to confine slaves in|Manage Arcology][$cash -= Math.trunc(10000*$upgradeMultiplierArcology), $arcade to 5]]
	//Costs ¤<<print Math.trunc(10000*$upgradeMultiplierArcology)>> and will incur upkeep costs//
<<elseif $arcade > 0>>
	A sex arcade has been installed in the arcology. It can support <<print $arcade>> inmates.
<</if>>

<<if $dairy == 0>>
	[[Add a dairy to the water reclamation facility|Manage Arcology][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $dairy to 5]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>> and will incur upkeep costs//
<<elseif $dairy > 0>>
	A dairy has been installed in the water reclamation area of your penthouse. It can support <<print $dairy>> milkers.
<</if>>

<<if $servantsQuarters == 0>>
	[[Build a dormitory to house large numbers of house servants|Manage Arcology][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $servantsQuarters to 5]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>//
<<else>>
	Your penthouse includes a dormitory to house large numbers of house servants.
<</if>>

<<if $schoolroom == 0>>
	[[Build a schoolroom where slaves can be educated|Manage Arcology][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $schoolroom to 5]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>//
<<else>>
	Your penthouse includes a schoolroom where slaves can be educated.
<</if>>

<<if $spa == 0>>
	[[Install open baths to provide relaxation space for resting slaves|Manage Arcology][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $spa to 5]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>//
<<else>>
	The penthouse includes a fully appointed spa where slaves can rest and recuperate.
<</if>>

<<if $clinic == 0>>
	[[Expand the surgical recovery area to accommodate patients and a nurse|Manage Arcology][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $clinic to 5]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>//
<<else>>
	The surgical recovery area has been expanded to take in more unhealthy slaves and be staffed by a nurse.
<</if>>

<<if $cellblock == 0>>
	[[Construct cells to properly confine disobedient slaves|Manage Arcology][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $cellblock to 5]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>//
<<else>>
	The lower level of the penthouse includes a hallway of cells to confine slaves in.
<</if>>

<<if $AProsperityCap > 120 && $familyTesting == 1>>
<<if $incubator == 0>>
	[[Install an incubation chamber to rapidly age children|Manage Arcology][$cash -= Math.trunc(100000*$upgradeMultiplierArcology), $incubator to 1]]
	//Costs ¤<<print Math.trunc(100000*$upgradeMultiplierArcology)>>//
<<else>>
	The penthouse has a specialized facility dedicated to rapidly aging children.
<</if>>
<<elseif $AProsperityCap >= 100 && $AProsperityCap <= 120>>
	//Installation of a child aging facility will require the arcology's electrical infrastructure to be overhauled.//
<</if>>

__Special Arcology Upgrades__

<<if ($personalArms == 0) && ($mercenaries == 0) && ($assistant == 0)>>
//$arcologies[0].name has no special upgrades//
<</if>>

<<if ($personalArms == 1)>>
You own a prototype powered exoskeleton that mounts armor and a smart mortar system, and has rifles mounted into its forearms.
<<elseif ($personalArms > 1)>>
You own a prototype powered exoskeleton that mounts armor and a smart mortar system, and has rifles mounted into its forearms. Furthermore, your security drones can rearm with small-caliber guns if necessary.
<</if>>

<<if ($mercenaries > 0)>>
<<if ($mercenaries == 1)>>
A squad of mercenaries is permanently quartered in $arcologies[0].name. They are grim men and women, heavily armed and armored. Their upkeep is costing ¤<<print ($mercenaries*1000)>> weekly.
<<elseif ($mercenaries < 5)>>
A full platoon of mercenaries is permanently quartered in $arcologies[0].name. They are grim men and women, heavily armed and armored. Their upkeep is costing ¤<<print ($mercenaries*1000)>> weekly.
<<elseif ($mercenaries >= 5)>>
You have permanently settled a full platoon of mercenaries in $arcologies[0].name as your $mercenariesTitle. They are grim men and women who appreciate their luxurious life here and train hard to keep their skills with their prototype armor sharp. Their upkeep is costing ¤<<print ($mercenaries*1000)>> weekly.
<</if>>
<</if>>

<<if ($assistant > 0)>>
<<if $assistantName is "your personal assistant">>Your personal assistant<<else>>$assistantName<</if>> is using an alternative personality setting, speaking in a sultry, sexual voice, and talking as though the penthouse's sex toys are her body.
<</if>>
<<if ($assistant > 1)>>
She also has charge of all smart piercings in the arcology, and is using her adaptations to sexual duties to improve their effectiveness.
<</if>>

Your slaves have participated in approximately <<print $oralTotal+$vaginalTotal+$analTotal>> sexual encounters: $oralTotal primarily oral, $vaginalTotal vanilla, $mammaryTotal mammary, $analTotal anal, and $penetrativeTotal with the slave penetrating another. They have produced about $milkTotal liters of marketable milk, <<if $seeDicks != 0>>about $cumTotal deciliters of marketable cum, <</if>>and have given birth $birthsTotal times.

<<if $pitKillsTotal > 0>>$pitKillsTotal slaves have died in your fighting pit.<</if>>
<<if $fuckdollsSold > 0>>$fuckdollsSold mindbroken arcade slaves have been converted into Fuckdolls and sold.<</if>>

Your arcology is named <<textbox "$arcologies[0].name" $arcologies[0].name "Manage Arcology">>

repo_name: preglocke/fc


code:
:: Manage Penthouse [nobr]

<<if $cheatMode == 1>>

//[[Cheat Edit Arcology|MOD_Edit Arcology Cheat][$cheater to 1]]//

<</if>>
<<set $showEncyclopedia to 0>>

<<include "Office Description">>
<<if $PC.career is "mercenary">>
	You look back at the rifle. It could never hold a zero, and would fail to feed if it wasn't given just the right amount of lubricant. But sometimes, you'd give anything for one more mission with that shitty old rifle.
<</if>>

__Penthouse Capacity__

The main penthouse dormitory, which houses slaves who aren't living in a facility and aren't granted a luxurious standard of living, has a capacity of ''$dormitory'' slaves.
[[Expand the dormitory|Manage Penthouse][$cash -= Math.trunc($dormitory*1000*$upgradeMultiplierArcology), $dormitory += 10]]
//Costs ¤<<print Math.trunc($dormitory*1000*$upgradeMultiplierArcology)>>//

//Exceeding this limit is bad for slaves' health, devotion and trust//

The penthouse also features little individual rooms, which house slaves who do enjoy a luxurious standard of living. They have a capacity of ''$rooms'' slaves.
[[Expand the rooms|Manage Penthouse][$cash -= Math.trunc($rooms*1000*$upgradeMultiplierArcology), $rooms += 5]]
//Costs ¤<<print Math.trunc($rooms*1000*$upgradeMultiplierArcology)>>//

//The number of rooms determines the number of slaves that can be granted luxury//

__Penthouse Improvements__

<<if $masterSuite == 0>>
	[[Improve your master bedroom to house a harem of personal toys|Manage Penthouse][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $masterSuite to 1]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>//
<<else>>
	Your penthouse is capped by a master suite with room for an entire harem of personal toys.
<</if>>

<<if $HGSuite != 1>>
	[[Build a small suite for a Head Girl to live in|Manage Penthouse][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $HGSuite to 1]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>//
<<else>>
	There is a small but handsome suite next to yours reserved for the Head Girl.
<</if>>

<<if $servantMilkers != 1>>
	Your penthouse is equipped with basic milkers for lactating slaves. [[Install more and tie them into the liquid systems|Manage Penthouse][$cash -= Math.trunc(25000*$upgradeMultiplierArcology), $servantMilkers to 1]]
	//Costs ¤<<print Math.trunc(25000*$upgradeMultiplierArcology)>>//
<<else>>
	Every room in the penthouse is equipped with milkers tied into the liquid systems, letting slaves with full udders drain them anywhere.
<</if>>

<<if $boobAccessibility != 1>>
<<if $pregAccessibility == 1 || $ballsAccessibility || $buttAccessibility>>
    Your penthouse has already been widened for overly wide slaves but there are no special accomodations for slaves with enormous breasts. [[Remodel for accessibility|Manage Penthouse][$cash -= Math.trunc(20000*$upgradeMultiplierArcology), $boobAccessibility to 1]]
	//Costs ¤<<print Math.trunc(20000*$upgradeMultiplierArcology)>>//
<<else>>
    Your penthouse has no special accessibility provisions for slaves with enormous breasts. [[Remodel for accessibility|Manage Penthouse][$cash -= Math.trunc(50000*$upgradeMultiplierArcology), $boobAccessibility to 1]]
	//Costs ¤<<print Math.trunc(50000*$upgradeMultiplierArcology)>>//
<</if>>
<<else>>
	The entire penthouse has been remodeled to make life with enormous breasts easier. The doorways have been widened, and tables, sinks and other items now have two levels: one at shoulder height for slaves to use, and another at waist height for them to rest their tits on while they do.
<</if>>

<<if $seeHyperPreg == 1>>

<<if $pregAccessibility != 1>>
<<if $boobAccessibility == 1 || $ballsAccessibility || $buttAccessibility>>
    Your penthouse has already been widened to make life for overly wide slaves easier but there are no special accomodations for slaves with enormous pregnancies. [[Remodel for accessibility|Manage Penthouse][$cash -= Math.trunc(20000*$upgradeMultiplierArcology), $pregAccessibility to 1]]
	//Costs ¤<<print Math.trunc(20000*$upgradeMultiplierArcology)>>//
<<else>>
    Your penthouse has no special accessibility provisions for slaves with enormous pregnancies. [[Remodel for accessibility|Manage Penthouse][$cash -= Math.trunc(50000*$upgradeMultiplierArcology), $pregAccessibility to 1]]
	//Costs ¤<<print Math.trunc(50000*$upgradeMultiplierArcology)>>//
<</if>>
<<else>>
	The entire penthouse has been remodeled to make life with enormous pregnancies easier. The doorways have been widened, and tables, sinks and other items are now designed to work around a massively distended belly.
<</if>>
<</if>>

<<if $arcologies[0].FSAssetExpansionistResearch == 1>>

<<if $dickAccessibility != 1>>
    Your penthouse has no special accessibility provisions for slaves with enormous dicks. [[Remodel for accessibility|Manage Penthouse][$cash -= Math.trunc(20000*$upgradeMultiplierArcology), $dickAccessibility to 1]]
	//Costs ¤<<print Math.trunc(20000*$upgradeMultiplierArcology)>>//
<<else>>
	The entire penthouse has been remodeled to make life with enormous dicks easier. Carts, slings and harnesses are available to keep things from dragging and there is now plenty of room for huge genitals to occupy when a slave must use appliances, tables and seats.
<</if>>

<<if $ballsAccessibility != 1>>
<<if $boobAccessibility == 1 || $buttAccessibility || $pregAccessibility>>
    Your penthouse has already been widened to make life for overly wide slaves easier but there are no special accomodations for slaves with enormous testicles. [[Remodel for accessibility|Manage Penthouse][$cash -= Math.trunc(20000*$upgradeMultiplierArcology), $ballsAccessibility to 1]]
	//Costs ¤<<print Math.trunc(20000*$upgradeMultiplierArcology)>>//
<<else>>
    Your penthouse has no special accessibility provisions for slaves with enormous testicles. [[Remodel for accessibility|Manage Penthouse][$cash -= Math.trunc(50000*$upgradeMultiplierArcology), $ballsAccessibility to 1]]
	//Costs ¤<<print Math.trunc(50000*$upgradeMultiplierArcology)>>//
<</if>>
<<else>>
	The entire penthouse has been remodeled to make life with enormous testicles easier. The doorways have been widened, tables, sinks and other items are now designed to fit over giant balls, drains have been widened to allow excessive cum to flow easier, and seats have been specially altered to allow plenty of ball room for seated slaves.
<</if>>

<<if $buttAccessibility != 1>>
<<if $boobAccessibility == 1 || $dickAccessibility || $ballsAccessibility>>
    Your penthouse has already been widened to make life for overly wide slaves easier but there are no special accomodations for slaves with gigantic posteriours. [[Remodel for accessibility|Manage Penthouse][$cash -= Math.trunc(20000*$upgradeMultiplierArcology), $buttAccessibility to 1]]
	//Costs ¤<<print Math.trunc(20000*$upgradeMultiplierArcology)>>//
<<else>>
    Your penthouse has no special accessibility provisions for slaves with enormous posteriors. [[Remodel for accessibility|Manage Penthouse][$cash -= Math.trunc(50000*$upgradeMultiplierArcology), $buttAccessibility to 1]]
	//Costs ¤<<print Math.trunc(50000*$upgradeMultiplierArcology)>>//
<</if>>
<<else>>
	The entire penthouse has been remodeled to make life with enormous rears easier. The doorways have been widened, and anything that can be sat on is now extra, extra wide and reinforced to allow even the heaviest, biggest asses to comfortably rest upon it.
<</if>>

<</if>>

<<if $feeder == 0>>
	[[Upgrade the kitchen's nutritional sensing systems|Manage Penthouse][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $feeder to 1]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>//
<<else>>
	The kitchen mounts sensors to refine diets in real time.
<</if>>

<<if $cockFeeder == 0>>
	[[Enhance the feeding system with faux phalli|Manage Penthouse][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $cockFeeder to 1]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>//
<<else>>
	The kitchen dispenses food from phalli slaves must suck off in order to eat. //[[Remove them|Manage Penthouse][$cockFeeder to 0]]//
<</if>>

<<if $suppository == 0>>
	[[Replace the drug dispensers with reciprocating dildo suppositories|Manage Penthouse][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $suppository to 1]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>//
<<else>>
	The kitchen applies drugs that can be absorbed rectally by assfucking slaves with dildos that cum the pharmaceuticals.  //[[Remove them|Manage Penthouse][$suppository to 0]]//
<</if>>

<<if $dairy != 0>>
<<if $dairyPiping == 0>>
	[[Install pipes connecting the Dairy to the rest of your penthouse for use in enema play|Manage Penthouse][$cash -= Math.trunc(15000*$upgradeMultiplierArcology), $dairyPiping to 1]]
	//Costs ¤<<print Math.trunc(15000*$upgradeMultiplierArcology)>>//
<<else>>
	Various taps around the penthouse supply product from $dairyName for use in enema play and force-feeding.
<</if>>
<<elseif $dairyPiping == 1>>
	Various taps around the penthouse supply product from $dairyName for use in enema play and force-feeding. With no dairy to draw from, they are currently unused.
<</if>>

<<if $studio == 0>>
	[[Install a media hub to convert slave video feeds into pornography|Manage Penthouse][$cash -= Math.trunc(10000*$upgradeMultiplierArcology), $studio to 1]]
	//Costs ¤<<print Math.trunc(10000*$upgradeMultiplierArcology)>>//
<<else>>
	The arcology's video systems are connected to a media hub that can convert slave video feeds into pornography.
<</if>>

<<if $dojo == 0>>
	[[Set up a personal armory to support a bodyguard|Manage Penthouse][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $dojo to 1]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>//
<<elseif $dojo == 1>>
	There is a small armory next to your office that can support a bodyguard. [[Upgrade the armory with a private room for the bodyguard|Manage Penthouse][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $dojo to 2]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>//
<<else>>
	There is a small armory next to your office that can support a bodyguard, with a little room for her to rest in when off duty.
<</if>>

<<if $pit == 0>>
	[[Build a pit to host slave fights|Manage Penthouse][$cash -= Math.trunc(5000*$upgradeMultiplierArcology), $pit to 1]]
	//Costs ¤<<print Math.trunc(5000*$upgradeMultiplierArcology)>>//
<<else>>
	You have a room with a padded pit sunken into the floor for slave fights.
<</if>>

<<if ($dispensary == 0)>>
<<if ($rep > 2000)>>
	[[Install a pharmaceutical fabricator|Manage Penthouse][$cash -= Math.trunc(20000*$upgradeMultiplierArcology), $dispensary to 1, $drugsCost to $drugsCost/4]]
	//Costs ¤<<print Math.trunc(20000*$upgradeMultiplierArcology)>>//
<<else>>
	//You lack the reputation to obtain cutting-edge pharmaceutical technology//
<</if>>
<<else>>
	There is a [[pharmaceutical fabricator|Dispensary]] in the basement.
<</if>>

<<if ($surgeryUpgrade == 0)>>
<<if ($rep > 10000)>>
	[[Upgrade the remote surgery|Manage Penthouse][$cash -= Math.trunc(50000*$upgradeMultiplierArcology), $surgeryUpgrade to 1]]
	//Costs ¤<<print Math.trunc(50000*$upgradeMultiplierArcology)>>//
<<else>>
	//You lack the reputation to secure rare surgery upgrades//
<</if>>
<<else>>
	Your remote surgery has been heavily upgraded and customized.
<</if>>

<<switch $prostheticsUpgrade>>
<<case 1>>
There is a facility to construct mechanical prosthetic limbs for amputated slaves.
<<if ($rep > 14000)>>
	[[Research advanced prototype prosthetics|Manage Penthouse][$cash -= Math.trunc(100000*$upgradeMultiplierArcology), $prostheticsUpgrade to 2]]
	//Costs ¤<<print Math.trunc(100000*$upgradeMultiplierArcology)>>//
<<else>>
	//You lack the reputation to research and produce prototype prosthetics.//
<</if>>
<<case 2>>
There is a prosthetics facility upgraded to use advanced materials and designs.
<<if ($rep > 16000)>>
	[[Research high-tech cybernetic limbs|Manage Penthouse][$cash -= Math.trunc(100000*$upgradeMultiplierArcology), $prostheticsUpgrade to 3]]
	//Costs ¤<<print Math.trunc(100000*$upgradeMultiplierArcology)>>//
<<else>>
	//You lack the reputation to research and produce prototype cybernetic limbs.//
<</if>>
<<case 3>>
There is a high-tech facility to build prosthetics and state-of-the-art cybernetic replacement limbs.
<<default>>
<<if ($rep > 12000)>>
	[[Construct a mechanical prosthetics facility|Manage Penthouse][$cash -= Math.trunc(100000*$upgradeMultiplierArcology), $prostheticsUpgrade to 1]]
	//Costs ¤<<print Math.trunc(100000*$upgradeMultiplierArcology)>>//
<<else>>
	//You lack the reputation to construct a prosthetics facility.//
<</if>>
<</switch>>


code:
:: Master Suite [nobr]

<<set $nextButton = "Back to Main", $nextLink = "Main", $returnTo = "Master Suite">>

<<if $masterSuiteName != "the Master Suite">>
	<<set $masterSuiteNameCaps to $masterSuiteName.replace("the ", "The ")>>
<</if>>

<<set $masterSuiteAverageEnergy = 0, $masterSuiteSlaves = 0, _masterSuiteAverageCum = 0, _masterSuiteAverageDick = 0, _masterSuiteAverageDom = 0, _masterSuiteAverageMilk = 0, _masterSuiteAveragePreg = 0, _masterSuiteAverageSadism = 0, _masterSuitePregnantSlaves = 0, _masterSuitePregnantSlavesMultiple = 0, _notMasterSuiteSlaves = 0, _SL = $slaves.length>>

<<for _i to 0; _i < _SL; _i++>>
<<set _Slave to $slaves[_i]>>
<<if _Slave.assignment is "serve in the master suite">>
	<<set $masterSuiteSlaves += 1>>
	<<if $masterSuiteUpgradeLuxury is 2>>
	<<if canAchieveErection(_Slave)>>
		<<set _masterSuiteAverageCum += _Slave.balls, _masterSuiteAverageDick += _Slave.dick>>
	<</if>>
	<<set _masterSuiteAverageMilk += _Slave.lactation*(_Slave.boobs-_Slave.boobsImplant)>>
	<<set $masterSuiteAverageEnergy += _Slave.energy>>
	<<set _masterSuiteAveragePreg += _Slave.preg>>
	<<if _Slave.fetish is "dom">>
		<<set _masterSuiteAverageDom += _Slave.fetishStrength>>
	<<elseif _Slave.fetish is "submissive">>
		<<set _masterSuiteAverageDom -= _Slave.fetishStrength>>
	<<elseif _Slave.fetish is "sadist">>
		<<set _masterSuiteAverageSadism += _Slave.fetishStrength>>
	<<elseif _Slave.fetish is "masochist">>
		<<set _masterSuiteAverageSadism -= _Slave.fetishStrength>>
	<</if>>
	<</if>>
	<<if $masterSuiteUpgradeLuxury > 0>>
	<<set _Slave.livingRules to "luxurious">>
	<</if>>
	<<set $slaves[_i] = _Slave>>
	<<if _Slave.ID == $Concubine.ID>>
		<<set $Concubine = _Slave>>
	<</if>>
<<else>>
	<<set _notMasterSuiteSlaves += 1>>
<</if>>
<<if (_Slave.assignment is "serve in the master suite" or _Slave.ID is $Concubine.ID) && (_Slave.preg >= 4)>>
	<<set _masterSuitePregnantSlaves += 1>>
	<<if _Slave.pregType > 1>>
		<<set _masterSuitePregnantSlavesMultiple += 1>>
	<</if>>
<</if>>
<</for>>

<<if ($masterSuiteSlaves > 0)>>
	<<set $masterSuiteAverageEnergy to $masterSuiteAverageEnergy/$masterSuiteSlaves>>
	<<set _masterSuiteAverageMilk to _masterSuiteAverageMilk/$masterSuiteSlaves>>
	<<set _masterSuiteAverageCum to _masterSuiteAverageCum/$masterSuiteSlaves>>
	<<set _masterSuiteAverageDick to _masterSuiteAverageDick/$masterSuiteSlaves>>
	<<set _masterSuiteAveragePreg to _masterSuiteAveragePreg/$masterSuiteSlaves>>
	<<set _masterSuiteAverageDom to _masterSuiteAverageDom/$masterSuiteSlaves>>
	<<set _masterSuiteAverageSadism to _masterSuiteAverageSadism/$masterSuiteSlaves>>
<</if>>

<<if $masterSuiteUpgradeLuxury == 1>>

$masterSuiteNameCaps is furnished
<<switch $masterSuiteDecoration>>
<<case "Roman Revivalist">>
	as a Roman emperor's apartment. There is a small shrine to the old gods the <<if $PC.title == 1>>master<<else>>mistress<</if>> favors in a side room, and the flooring is erotic mosaic. Pride of place is given to a set of low couches placed together, capable of accommodating many nude bodies.
<<case "Egyptian Revivalist">>
	after the royal room of an ancient Egyptian palace. There is a small shrine to the old gods the <<if $PC.title == 1>>master<<else>>mistress<</if>> favors in a side room, and linen hangings decorate the walls and ceiling. An imposing bed of sandalwood occupies the center of the room.
<<case "Edo Revivalist">>
	in the Spartan style of an Edo period castle's innermost rooms. Rice paper screens partition off many small cubicles around its large central space. There, around a low bed, there are many mats for servants to kneel around their <<if $PC.title == 1>>master<<else>>mistress<</if>>.
<<case "Arabian Revivalist">>
	as a beguiling haze of Arabian decadence. There is a great gilded bed in the center of the space, piled with silk pillows for naked bodies to recline on. Gauzy curtains flutter in the warm, heady breeze.
<<case "Chinese Revivalist">>
	as though it were the innermost sanctum of the Forbidden City. A massive bed fills the central space. The walls are gorgeous gilded hand-carved screens, and heavy jade statues of favored gods crouch in the corners.
<<case "Chattel Religionist">>
	as a severe place of cold stone and hard wood. A single shaft of sunlight illuminates an enormous stone platform that serves as a bed where penitents give their bodies to their <<if $PC.title == 1>>master<<else>>mistress<</if>>.
<<case "Degradationist">>
	with a gothic grandeur. Blood-red upholstery and hardwood menace crouch in the center of the space in the form of a massive poster bed with curtains of chain mail.
<<case "Repopulation Focus">>
	comfortably, with lots of cushions and seats for a pregnant slaves to lounge on. Various specialized toys, as well as, lotions and creams are readily available. There's a huge, reinforced, low to the ground bed in the middle of the suite.
<<case "Eugenics">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make fucking slave girls lots of fun. There's a huge bed in the middle of the suite, with hidden compartments containing condoms and spermicides.
<<case "Asset Expansionist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make sex with stacked slaves as fun as possible. There's a huge bed in the middle of the suite, heavily reinforced.
<<case "Transformation Fetishist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make sex with bimbo slaves as fun as possible. There's a huge bed in the middle of the suite, heavily reinforced.
<<case "Gender Radicalist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make fucking slave girls in the butt lots of fun.  There's a huge bed in the middle of the suite, with straps to restrain slave girls who don't want to be fucked in the butt, but they're concealed for now.
<<case "Gender Fundamentalist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make fucking slave girls nice and enjoyable. There's a huge bed in the middle of the suite, with straps to restrain slave girls who don't want to be fucked, but they're concealed for now.
<<case "Physical Idealist">>
	as a shrine to the owner's body. Athletic trophies and photographs of past victories line the walls. There's a huge bed in the middle of the space, and there are mirrors almost everywhere, including on the ceiling over the bed.
<<case "Supremacist">>
	like the royal bedroom in a palace in the old countries of $arcologies[0].FSSupremacistRace people. A massive four-poster bed dominates the space.
<<case "Subjugationist">>
	like the royal bedroom in a palace in the old countries which favored $arcologies[0].FSSubjugationistRace slaves. A massive four-poster bed dominates the space.
<<case "Paternalist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make sex with slaves mutually enjoyable.
<<case "Pastoralist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants. The space is dominated by a massive, reinforced bed, built in sections so that part of it can be cleaned while cream-squirting cows cavort on the rest.
<<case "Maturity Preferentialist">>
	comfortably, with elegant sex toys and perfumed lubricants designed to appeal to mature sex slaves. The space is dominated by a broad, soft bed, well supplied with pillows. It's the perfect place to relax with a harem of MILFs.
<<case "Youth Preferentialist">>
	comfortably, with pastel-colored sex toys and flavored lubricants designed to appeal to eager young sex slaves. The space is dominated by a broad, reinforced bed, without cushions or sheets, which would just get in the way of energetic sex.
<<case "Body Purist" "Slimness Enthusiast">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make sex with slaves mutually enjoyable. The space is dominated by a huge bed with soft sheets.
<<default>>
	in a refined, yet practical style. It's dominated by a huge bed in which many slaves could serve their <<if $PC.title == 1>>master<<else>>mistress<</if>> and then cuddle afterward.
<</switch>>

It's is full of luxuries of all kinds. The slaves here live free of want or worry, and have everything except their freedom. Their only duties are to please you and look after the suite and one another.
<<if $masterSuiteSlaves > 2>>
	It's busy with slaves, so many that they are able to rotate through keeping themselves perfect and ready for your pleasure. The slaves not on call at the moment are beautifying themselves, cleaning, or serving others.
	<<if (_masterSuitePregnantSlaves > 2) && (_masterSuitePregnantSlavesMultiple < 2)>>
	Many of the slaves are pregnant, and they walk around proudly displaying their bellies and the new slaves growing inside them.

	<<elseif (_masterSuitePregnantSlaves > 2) && (_masterSuitePregnantSlavesMultiple > 2) && $masterSuiteHyperPregnancy == 1>>
	Many of the slaves are heavily pregnant with multiple children, and they waddle around proudly displaying their distended bulging bellies and the next generation of slaves growing within them.

	<<elseif (_masterSuitePregnantSlaves > 2) && (_masterSuitePregnantSlavesMultiple > 2)>>
	Many of the slaves are pregnant with multiple children, and they walk around proudly displaying their distended bellies and the next generation of slaves growing within them.

	<</if>>
<<elseif $masterSuiteSlaves > 0>>
	It's sparsely populated, so that the few slaves here have to work hard and quickly to ensure that an assortment of sex slaves is perfect and ready for your pleasure at any given moment.
<<else>>
	None of your slaves are serving here.
<</if>>

    [[Remodel the suite around a luxurious pit for group sex|Master Suite][$cash -= 10000, $masterSuiteUpgradeLuxury to 2]] //Costs 10000; will encourage fucktoys to fuck each other//

<<elseif $masterSuiteUpgradeLuxury is 2>>

$masterSuiteNameCaps is furnished
<<switch $masterSuiteDecoration>>
<<case "Roman Revivalist">>
	as a Roman emperor's apartment. There is a small shrine to the old gods the <<if $PC.title == 1>>master<<else>>mistress<</if>> favors in a side room, and the flooring is erotic mosaic.
<<case "Egyptian Revivalist">>
	after the royal room of an ancient Egyptian palace. There is a small shrine to the old gods the <<if $PC.title == 1>>master<<else>>mistress<</if>> favors in a side room, and linen hangings decorate the walls and ceiling.
<<case "Edo Revivalist">>
	in the Spartan style of an Edo period castle's innermost rooms. Rice paper screens partition off many small cubicles around its large central space.
<<case "Arabian Revivalist">>
	as a beguiling haze of Arabian decadence. Gauzy curtains flutter in the warm, heady breeze.
<<case "Chinese Revivalist">>
	as though it were the innermost sanctum of the Forbidden City. The walls are gorgeous gilded hand-carved screens, and heavy jade statues of favored gods crouch in the corners.
<<case "Chattel Religionist">>
	as a severe place of cold stone and hard wood. A single shaft of sunlight illuminates the central space.
<<case "Degradationist">>
	with a gothic grandeur. Blood-red upholstery and hardwood menace decorate the walls.
<<case "Repopulation Focus">>
	comfortably, with lots of cushions and seats for a pregnant slaves to lounge on. There are various specialized toys, as well as, lotions and creams readily available.
<<case "Eugenics">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make fucking slave girls lots of fun. Condoms and spermicides are readily available throughout the suite.
<<case "Asset Expansionist">>
	comfortably, with the convenience of massive-breasted slaves in mind. There are lots of handrails, cushions, and low tables, covered with creams, lubricants, and sex toys.
<<case "Transformation Fetishist">>
	comfortably, with the convenience of bimbos in mind. There are lots of makeup dressers with mirrors, stripper poles, and low tables, covered with creams, lubricants, and sex toys.
<<case "Gender Radicalist">>
	comfortably, with the convenience of dickgirls in mind. There are lots of makeup dressers with mirrors, stripper poles, and low tables, covered with creams, lubricants, and vibrating butt plugs.
<<case "Gender Fundamentalist">>
	comfortably, with the convenience and pleasure of slavegirls in mind. There are lots of makeup dressers with mirrors, soft divans, and low tables, covered with creams, lubricants, and vibrators.
<<case "Physical Idealist">>
	as a shrine to the owner's body. Athletic trophies and photographs of past victories line the walls. The entire area is filled with the heady odors of sweat, metabolites, and sex.
<<case "Supremacist">>
	like the royal bedroom in a palace in the old countries of $arcologies[0].FSSupremacistRace people.
<<case "Subjugationist">>
	like the royal bedroom in a palace in the old countries which favored $arcologies[0].FSSubjugationistRace slaves.
<<case "Paternalist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make sex with slaves mutually enjoyable.
<<case "Pastoralist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants, with a distinct focus on mammary intercourse.
<<case "Maturity Preferentialist">>
	comfortably, with elegant sex toys and perfumed lubricants designed to appeal to mature sex slaves.
<<case "Youth Preferentialist">>
	comfortably, with pastel-colored sex toys and flavored lubricants designed to appeal to eager young sex slaves.
<<case "Body Purist" "Slimness Enthusiast">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make sex with slaves mutually enjoyable.
<<default>>
	in a refined, yet practical style.
<</switch>>

The true focus of the suite is, however, the fuckpit. This stepped depression in the middle of the floor
<<if $masterSuiteSlaves > 3>>
	is filled by cushions and every slave in the suite who isn't sleeping, eating, or bathing.
	<<if $masterSuiteAverageEnergy > 90>>
	They're having energetic group sex; most of them are fucking and being fucked at the same time.
	<<elseif $masterSuiteAverageEnergy > 60>>
	They're having group sex; most of them are in active sexual contact with more than one partner.
	<<else>>
	They're having languid group sex; more than one girl is dozing while another plays with her body.
	<</if>>
	<<if $masterSuiteAverageEnergy > 90>>
	The pit features automated cleaning systems, which are quite necessary.
	<<if _masterSuiteAverageDick > 4>>
		With so many huge cocks in the fuckpit, every hole available is frequently fucked vigorously.
	<</if>>
	<<if _masterSuiteAverageCum > 4>>
		The slaves' bodies grow more coated with cum, and more of the white stuff drips from their holes, until they take a break for a shower.
	<</if>>
	<<if _masterSuiteAverageMilk > 4000>>
		Most of them cannot tear themselves away (or cannot escape) for a normal machine milking, so their tender, overfull breasts squirt milk whenever anyone touches them. The lowest level of the fuckpit is a pool of milk.
	<</if>>
	<</if>>
	<<if (_masterSuitePregnantSlaves > 2) && (_masterSuitePregnantSlavesMultiple < 2)>>
	Many of the slaves are pregnant, and more than one has her face buried in the cunt directly below a gravid belly while she lovingly massages her own.

	<<elseif (_masterSuitePregnantSlaves > 2) && (_masterSuitePregnantSlavesMultiple > 2) && $masterSuiteHyperPregnancy == 1>>
	Many of the slaves are heavily pregnant with multiple children, and more than one has her face buried in the cunt directly below a massively overburdened belly while she lovingly massages her own distended squirming stomach.

	<<elseif (_masterSuitePregnantSlaves > 2) && (_masterSuitePregnantSlavesMultiple > 2)>>
	Many of the slaves are pregnant with multiple children, and more than one has her face buried in the cunt directly below a grossly swollen belly while she lovingly massages her own distended stomach.

	<</if>>
<<elseif $masterSuiteSlaves > 0>>
	has a few lonely-looking fucktoys in it, badly outnumbered by the cushions.
<<else>>
	is desolate and unpopulated.
<</if>>

    [[Refit the suite to the height of traditional opulence|Master Suite][$cash -= 10000, $masterSuiteUpgradeLuxury to 1]] //Costs 10000; will focus the suite on you//

<<else>>

$masterSuiteNameCaps is furnished
<<switch $masterSuiteDecoration>>
<<case "Roman Revivalist">>
	as a Roman patrician's apartment. There is a small shrine to the old gods the <<if $PC.title == 1>>master<<else>>mistress<</if>> favors in a side room, and the flooring is erotic mosaic.
<<case "Egyptian Revivalist">>
	after the best room of an ancient Egyptian mansion. There is a small shrine to the old gods the <<if $PC.title == 1>>master<<else>>mistress<</if>> favors in a side room, and linen hangings decorate the walls and ceiling.
<<case "Edo Revivalist">>
	in the Spartan style of an Edo period mansion's innermost rooms. Rice paper screens divide it into subsections, each of which contains little more than a low bed.
<<case "Arabian Revivalist">>
	as a beguiling haze of Arabian decadence. Soft cushions are scattered across the floor and piled against the walls to provide something for dusky, naked bodies to recline on. Gauzy curtains partition the room into a number of cozy dens.
<<case "Chinese Revivalist">>
	like the mansion of a senior mandarin of ancient China. The walls are gorgeous hand-carved wooden screens, and heavy jade statues of favored gods crouch in the corners.
<<case "Chattel Religionist">>
	as a severe place of cold stone and hard wood. A single shaft of sunlight illuminates the bed where penitents give their bodies to their <<if $PC.title == 1>>master<<else>>mistress<</if>>.
<<case "Repopulation Focus">>
	comfortably, with lots of cushions and seats for a pregnant slaves to lounge on. Various specialized toys, as well as, lotions and creams are readily available.
<<case "Eugenics">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make fucking slave girls lots of fun. Condoms and spermicides are readily available throughout the suite.
<<case "Degradationist">>
	with a gothic grandeur. Blood-red upholstery and hardwood menace. There are numerous places where resistant slaves can be restrained.
<<case "Asset Expansionist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make sex with stacked slaves as fun as possible.
<<case "Transformation Fetishist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make sex with bimbo slaves as fun as possible.
<<case "Gender Radicalist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make fucking slave girls in the butt lots of fun. The straps to restrain slave girls who don't want to be fucked in the butt are concealed for now.
<<case "Gender Fundamentalist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make fucking slave girls nice and enjoyable. The straps to restrain slave girls who don't want to be fucked are concealed for now.
<<case "Physical Idealist">>
	as a shrine to the owner's body. Athletic trophies and photographs of past victories line the walls. There are mirrors almost everywhere, including on the ceiling over the bed.
<<case "Supremacist">>
	like the master bedroom in a mansion in the old countries of $arcologies[0].FSSupremacistRace people.
<<case "Subjugationist">>
	like the master bedroom in a mansion in the old countries which favored $arcologies[0].FSSubjugationistRace slaves.
<<case "Paternalist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make sex with slaves mutually enjoyable.
<<case "Pastoralist">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants. Everything that isn't waterproof is covered in plastic, to catch errant milk.
<<case "Maturity Preferentialist">>
	comfortably, with elegant sex toys and perfumed lubricants designed to appeal to mature sex slaves.
<<case "Youth Preferentialist">>
	comfortably, with pastel-colored sex toys and flavored lubricants designed to appeal to eager young sex slaves.
<<case "Body Purist" "Slimness Enthusiast">>
	comfortably, with lots of easy-to-clean leather and plentiful tools, toys, and lubricants to make sex with slaves mutually enjoyable.
<<default>>
	comfortably, as a fairly normal luxury suite. It is unusually large, to accommodate as large a stable of sex slaves as strikes your fancy.
<</switch>>

<<if $masterSuiteSlaves > 2>>
	It's busy with slaves, so many that they are able to rotate through keeping themselves perfect and ready for your pleasure. The slaves not on call at the moment are beautifying themselves, cleaning, or serving others.
	<<if (_masterSuitePregnantSlaves > 2) && (_masterSuitePregnantSlavesMultiple < 2)>>
	Many of the slaves are pregnant, and they walk around proudly displaying their bellies and the new slaves growing inside them.

	<<elseif (_masterSuitePregnantSlaves > 2) && (_masterSuitePregnantSlavesMultiple > 2) && $masterSuiteHyperPregnancy == 1>>
	Many of the slaves are heavily pregnant with multiple children, and they waddle around proudly displaying their distended bulging bellies and the next generation of slaves growing within them.

	<<elseif (_masterSuitePregnantSlaves > 2) && (_masterSuitePregnantSlavesMultiple > 2)>>
	Many of the slaves are pregnant with multiple children, and they walk around proudly displaying their distended bellies and the next generation of slaves growing within them.

	<</if>>
<<elseif $masterSuiteSlaves > 0>>
	It's sparsely populated, so that the few slaves here have to work hard and quickly to ensure that an assortment of sex slaves is perfect and ready for your pleasure at any given moment.
<<else>>
	None of your slaves are serving here.
<</if>>

    [[Refit the suite to the height of traditional opulence|Master Suite][$cash -= 25000, $masterSuiteUpgradeLuxury to 1]] //Costs ¤25000 and will focus the suite on you//

    [[Remodel the suite around a luxurious pit for group sex|Master Suite][$cash -= 25000, $masterSuiteUpgradeLuxury to 2]] //Costs ¤25000; will encourage fucktoys to fuck each other//

<</if>>

$masterSuiteNameCaps has room for $masterSuite slaves to live comfortably<<if $masterSuiteUpgradeLuxury == 2>> in the moments when they're not in the fuckpit<<elseif $masterSuiteUpgradeLuxury == 1>> on its huge bed<</if>>.
[[Expand the Master Suite|Master Suite][$cash -=  Math.trunc($masterSuite*1000*$upgradeMultiplierArcology), $masterSuite += 5]] //Costs ¤<<print Math.trunc($masterSuite*1000*$upgradeMultiplierArcology)>>//

<<if $masterSuiteUpgradePregnancy == 1>>
	The master suite has been further upgraded to support fertile slaves and encourage slave pregnancy, providing additional rest areas, better access to amenities, and a dedicated birthing chamber.
	<<if $masterSuitePregnancySlaveLuxuries == 1>>
		Pregnant slaves are being ''given some luxuries'' to reduce stress. [[End the special treatment of pregnant slaves|Master Suite][$masterSuitePregnancySlaveLuxuries to 0]]

	<<else>>
		Pregnant slaves ''have no extra luxuries'' to reduce stress. [[Give pregnant slaves lighter duties|Master Suite][$masterSuitePregnancySlaveLuxuries to 1]]  //Costs ¤500/week//

	<</if>>
	<<if $masterSuitePregnancyFertilityDrugs == 1 || $masterSuiteHyperPregnancy == 1>>
		Fertile slaves ''are being given'' <<if $masterSuiteHyperPregnancy == 1>>super fertility drugs<<else>>fertility drugs<</if>>, encouraging impregnation and multiple pregnancy.<<if $masterSuiteHyperPregnancy == 1>> [[End the drug regime|Master Suite][$masterSuiteHyperPregnancy to 0, $masterSuitePregnancyFertilitySupplements to 0]]<<else>> [[End the drug regime|Master Suite][$masterSuitePregnancyFertilityDrugs to 0, $masterSuitePregnancyFertilitySupplements to 0]]<</if>>

	<<else>>
		Fertile slaves ''are not being given'' fertility drugs. [[Give fertility drugs to all fertile slaves|Master Suite][$masterSuitePregnancyFertilityDrugs to 1]]  <<if $seeHyperPreg == 1 && $superFertilityDrugs == 1>> | [[Give hyper fertility drugs to all fertile slaves|Master Suite][$masterSuiteHyperPregnancy to 1]]<</if>>

	<</if>>
	<<if $masterSuitePregnancyFertilityDrugs == 0 && $masterSuiteHyperPregnancy == 0>>
		//Fertile slaves ''must be on fertility drugs'' to be given fertility supplements//

	<<elseif $masterSuitePregnancyFertilitySupplements == 0 && ($masterSuitePregnancyFertilityDrugs == 1 || $masterSuiteHyperPregnancy == 1)>>
		Fertile slaves ''are not being given'' fertility drug supplements. [[Give supplements to slaves on fertility drugs|Master Suite][$masterSuitePregnancyFertilitySupplements to 1]] //Costs ¤1000/week//

	<</if>>
	<<if $masterSuitePregnancyFertilitySupplements == 1 && ($masterSuitePregnancyFertilityDrugs == 1 || $masterSuiteHyperPregnancy == 1)>>
		Fertile slaves ''are being given'' supplements to their fertility drugs, further enhancing the chances of multiple pregnancy. [[End the supplement regime|Master Suite][$masterSuitePregnancyFertilitySupplements to 0]]

	<</if>>
<<else>>
	The master suite does not currently have special customizations to support slave pregnancy. [[Refit the suite to support and encourage slave pregnancy|Master Suite][$cash -= 15000, $masterSuiteUpgradePregnancy to 1]] //Costs ¤15000//
<</if>>

<<if $Concubine != 0>>
	<<set $Flag to 2>>
	<<include "Slave Summary">>
<<else>>
	You do not have a slave serving as your Concubine. [[Appoint one|Concubine Select]]
<</if>>

<<if $masterSuiteSlaves > 0>>

''Bring a slave out of the master suite:''
	<<set $Flag to 1>>
	<<include "Slave Summary">>
<</if>>

<<if _notMasterSuiteSlaves > 0>>

''Send a slave to serve in the master suite:''
	<<set $Flag to 0>>
	<<include "Slave Summary">>
<</if>>
<<unset $Flag>>

Rename $masterSuiteName: <<textbox "$masterSuiteName" $masterSuiteName "Master Suite">> //Use a noun or similar short phrase//


code:
:: Master Suite Report [nobr]

<<set $legendaryAbolitionistID = 0, $masterSuiteAverageEnergy = 0, $masterSuiteSlaves = 0, _masterSuiteAverageCum = 0, _masterSuiteAverageDick = 0, _masterSuiteAverageDom = 0, _masterSuiteAverageMilk = 0, _masterSuiteAveragePreg = 0, _masterSuiteAverageSadism = 0, _masterSuitePregnantSlaves = 0, _masterSuitePregnantSlavesMultiple = 0, _SL = $slaves.length, _CCB = -1>>

<<for _i = 0; _i < _SL; _i++>>
<<if ($slaves[_i].assignment is "serve in the master suite") || ($slaves[_i].assignment is "be your Concubine")>>

/* 000-250-006 */
/*	<<if $seeImages == 1>><<SlaveArt $slaves[_i] 0 0>><</if>> */
<<if $seeImages == 1>>

    <<SlaveArt $slaves[_i] 0 0>>

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

	<<set $masterSuiteSlaves += 1, $masterSuiteAverageEnergy += $slaves[_i].energy>>
	<<if $masterSuiteUpgradeLuxury == 2>>
	<<if canAchieveErection($slaves[_i])>>
		<<set _masterSuiteAverageCum += $slaves[_i].balls, _masterSuiteAverageDick += $slaves[_i].dick>>
	<</if>>
	<<set _masterSuiteAverageMilk += $slaves[_i].lactation*($slaves[_i].boobs-$slaves[_i].boobsImplant)>>
	<<set _masterSuiteAveragePreg += $slaves[_i].preg>>
	<<if $slaves[_i].fetish is "dom">>
		<<set _masterSuiteAverageDom += $slaves[_i].fetishStrength>>
	<<elseif $slaves[_i].fetish is "submissive">>
		<<set _masterSuiteAverageDom -= $slaves[_i].fetishStrength>>
	<<elseif $slaves[_i].fetish is "sadist">>
		<<set _masterSuiteAverageSadism += $slaves[_i].fetishStrength>>
	<<elseif $slaves[_i].fetish is "masochist">>
		<<set _masterSuiteAverageSadism -= $slaves[_i].fetishStrength>>
	<</if>>
	<</if>>
	<<if ($legendaryAbolitionistID == 0) && ($slaves[_i].devotion > 95) && ($slaves[_i].prestige == 0)>>
	<<if ($slaves[_i].origin is "You sentenced her to enslavement as a punishment for attempted theft of a slave.") || ($slaves[_i].origin is "She is an enslaved Daughter of Liberty.")>>
		<<set $legendaryAbolitionistID to $slaves[_i].ID>>
	<</if>>
	<</if>>
<</if>>
<</for>>

<<if ($masterSuiteSlaves > 0)>>

<<set $masterSuiteAverageEnergy to $masterSuiteAverageEnergy/$masterSuiteSlaves>>
<<set _masterSuiteAverageMilk to _masterSuiteAverageMilk/$masterSuiteSlaves>>
<<set _masterSuiteAverageCum to _masterSuiteAverageCum/$masterSuiteSlaves>>
<<set _masterSuiteAverageDick to _masterSuiteAverageDick/$masterSuiteSlaves>>
<<set _masterSuiteAveragePreg to _masterSuiteAveragePreg/$masterSuiteSlaves>>
<<set _masterSuiteAverageDom to _masterSuiteAverageDom/$masterSuiteSlaves>>
<<set _masterSuiteAverageSadism to _masterSuiteAverageSadism/$masterSuiteSlaves>>

<<if $seeImages == 1>>
<</if>>
''There <<if ($masterSuiteSlaves == 1)>>is one slave<<else>>are $masterSuiteSlaves slaves<</if>>
seeing to your pleasure in the master suite.'' Such sexual opulence @@color:green;improves@@ your reputation.
<<if ($arcologies[0].FSEgyptianRevivalist > 0) && ($masterSuiteSlaves >= 5)>>
	Society @@color:green;approves@@ of your keeping a large number of women, which advances the Egyptian revivalist ideal of multiple concubinage.
	<<set $repGain += 0.2*$masterSuiteSlaves*$FSSingleSlaveRep*($arcologies[0].FSEgyptianRevivalist/$FSLockinLevel)>>
	<<set $arcologies[0].FSEgyptianRevivalist += 0.01*$masterSuiteSlaves*$FSSingleSlaveRep>>
<</if>>
<<if (_masterSuitePregnantSlaves >= 1)>>
	The suite is supporting the pregnancies of the slaves
	<<if ($masterSuitePregnancyFertilityDrugs == 1 || $masterSuiteHyperPregnancy == 1)>>
		within, and is providing them with fertility drugs
		<<if ($masterSuitePregnancyFertilitySupplements == 1)>>
		and supplements to encourage impregnation.
		<<else>>
		to encourage impregnation.
		<</if>>
	<<else>>
	within.
	<</if>>
<</if>>
<<if $masterSuiteSlaves > 1>>
The level of sexual energy in the suite is
<<if $masterSuiteUpgradeLuxury == 1>>
	<<if $masterSuiteAverageEnergy > 90>>
	intense. When you enter your luxurious retreat, you can set off pent-up orgasms with a touch.
	<<elseif $masterSuiteAverageEnergy > 60>>
	high; there is strong competition for your favors whenever you enter your retreat.
	<<else>>
	relatively normal; the girls serve your pleasure before their own.
	<</if>>
<<elseif $masterSuiteUpgradeLuxury is 2>>
	<<if $masterSuiteAverageEnergy > 90>>
	intense. Your girls spend almost all their time in the fuckpit, having sex in a big pile.
	<<elseif $masterSuiteAverageEnergy > 60>>
	high; your girls spend much of their time in the fuckpit, having sex with each other.
	<<else>>
	relatively normal; the girls lounging in the fuckpit get each other off when they feel like it.
	<</if>>
	<<if _masterSuiteAverageCum > 4>>
	Unless it's right after an automated cleaning, everything in the fuckpit is spattered with cum.
	<</if>>
	<<if _masterSuiteAverageMilk > 4000>>
	There's so much lactation going on that the lowest level of the fuckpit is a pool of milk.
	<</if>>
<<else>>
	relatively normal.
<</if>>
<</if>>

<<for _i = 0; _i < _SL; _i++>>
<<if ($slaves[_i].assignment is "serve in the master suite") || ($slaves[_i].assignment is "be your Concubine")>>
<<set $i = _i>>
<<silently>><<include "SA please you">><</silently>>

<<if ($slaves[_i].assignment is "serve in the master suite")>>
	<<if $verboseDescriptions == 1>>

''__@@color:pink;$slaves[_i].slaveName@@__'' sees to your pleasure in the master suite.<</if>>
	<<if ($masterSuiteUpgradeLuxury == 1)>>
	<<if ($slaves[_i].devotion <= 95)>>
		<<set $slaves[_i].devotion += 2>>
	<</if>>
	<<if $masterSuiteDecoration != "standard">>
		<<set $slaves[_i].devotion += 1>>
	<</if>>
	<<if ($slaves[_i].trust < 60)>>
		<<set $slaves[_i].trust += 1>>
	<</if>>
	<<elseif ($masterSuiteUpgradeLuxury is 2)>>
	<<if ($slaves[_i].energy > 90)>>
		<<if ($slaves[_i].devotion <= 95)>>
		<<set $slaves[_i].devotion += 2>>
		<</if>>
		<<if ($slaves[_i].trust <= 95)>>
		<<set $slaves[_i].trust += 2>>
		<</if>>
	<<else>>
		<<if ($slaves[_i].devotion <= 60)>>
		<<set $slaves[_i].devotion += 1>>
		<</if>>
		<<if ($slaves[_i].trust < 60)>>
		<<set $slaves[_i].trust += 1>>
		<</if>>
	<</if>>
	<<else>>
	<<if ($slaves[_i].devotion <= 20) && ($slaves[_i].trust > -20)>>
		<<set $slaves[_i].devotion -= 2, $slaves[_i].trust -= 5>>
	<<elseif ($slaves[_i].devotion <= 60)>>
		<<set $slaves[_i].devotion += 2>>
	<<elseif ($slaves[_i].devotion > 60)>>
		<<set $slaves[_i].devotion -= 2>>
	<</if>>
	<<if ($slaves[_i].trust < 60)>>
		<<set $slaves[_i].trust += 1>>
	<</if>>
	<</if>>
<<else>>
	<<set $Concubine = $slaves[_i], _CCB = _i>>
	<<if $verboseDescriptions == 1>>

<</if>>''Your concubine $Concubine.slaveName is serving you in $masterSuiteName.'' More than any other slave, her sexual brilliance and physical appeal are @@color:green;critical@@ to your reputation.
	<<if ($Concubine.career is "an arcology owner")>>
	She was once your rival, and your relationship is widely thought to be @@color:green;the perfect modern romance.@@
	<<set $repGain += 250>>
	<<elseif ($Concubine.prestige > 0)>>
	<<if $verboseDescriptions == 1>>Keeping such a prestigious slave as your concubine @@color:green;adds to your fame.@@<</if>>
	<<set $repGain += 25*$Concubine.prestige>>
	<</if>>
	<<if $Concubine.prestigeDesc is "She is a famed Free Cities whore, and commands top prices.">>
		When she has a free moment, she refines her flexibility so that she is prepared for any sexual position you can think of, and many more that she researched just for your pleasure.
	<</if>>
	<<if $Concubine.prestigeDesc is "She is a famed Free Cities slut, and can please anyone.">>
		When she has a free moment, she pretties herself up so that she may be as beautiful as possible to make you look even better.
	<</if>>
	<<if $Concubine.prestigeDesc is "She is remembered for winning best in show as a cockmilker.">>
		She does her best to prevent herself from making a mess when you don't want one. When she has free time, she researches new techniques to makes use of her huge loads to entertain you.
	<</if>>
	<<if $Concubine.prestigeDesc is "She is remembered for winning best in show as a dairy cow.">>
		She does her best to prevent herself from making a mess when you don't want one. When she has free time, she researches new techniques to makes use of her excessive milk to entertain you.
	<</if>>
	<<if $Concubine.prestigeDesc is "She is remembered for winning best in show as a breeder." && $Concubine.preg > 10>>
		When she has a free moment, she refines her flexibility so that she can perform any sexual position possible for her in her motherly state. She takes the time to look up new positions to work around her growing pregnancy.
	<</if>>
	<<if $Concubine.prestigeDesc is "She is remembered for winning best in show as a breeder.">>
		When she has a free moment, she refines her flexibility so that she is prepared for any sexual position you can think of, no matter how heavy she becomes with children.
	<</if>>
	<<if ($Concubine.oralCount + $Concubine.analCount + $Concubine.vaginalCount + $Concubine.mammaryCount + $Concubine.penetrativeCount > 1000)>>
	<<if $verboseDescriptions == 1>>Many citizens <<if $Concubine.publicCount > 10>>remember having had her themselves, and <</if>>@@color:green;respectfully@@ envy you her exclusive company.<</if>>
	<<set $repGain += 25>>
	<</if>>
	<<if $slaves[_i].devotion <= 20>>
	<<if $masterSuiteUpgradeLuxury > 0>>
		<<set $slaves[_i].devotion += 4, $slaves[_i].trust += 4>>
	<<else>>
		<<set $slaves[_i].devotion += 2, $slaves[_i].trust += 2>>
	<</if>>
	<</if>>
	<<if $masterSuiteDecoration != "standard">>
	<<set $slaves[_i].devotion += 1>>
	<</if>>
<</if>>

<<if $masterSuiteUpgradeLuxury is 2>>

<<if ($slaves[_i].trust > -20) && ($slaves[_i].devotion > -10) && ($slaves[_i].fetishStrength <= 95)>>
<<if $masterSuiteAverageEnergy > random(50,90)>>
	<<if $verboseDescriptions == 1>>
		<<set _Verb = "She">>
	<<else>>
		<<set _Verb = $slaves[_i].slaveName>>
	<</if>>
	<<fetishChangeChance $slaves[_i]>>
	<<if (_masterSuiteAverageMilk > 2000) && ($fetishChangeChance > random(0,50))>>
	<<if $slaves[_i].fetish is "boobs">>
		<<if $verboseDescriptions == 1>>Her<<else>>$slaves[_i].slaveName's<</if>> @@color:lightcoral;boob fetish is strengthened@@ by the constant availability of milky nipples for her to play with.
		<<set $slaves[_i].fetishStrength += 4>>
	<<else>>
		<<if $verboseDescriptions == 1>>She<<else>>$slaves[_i].slaveName<</if>> @@color:lightcoral;acquires a boob fetish@@ after spending a lot of time in the fuckpit drinking from her fellow fucktoys' tits.
		<<set $slaves[_i].fetish to "boobs", $slaves[_i].fetishStrength = 65>>
	<</if>>
	<<elseif (_masterSuiteAverageDick > 3) && ($slaves[_i].anus > 0) && ($fetishChangeChance > random(0,50))>>
	_Verb
	<<if $slaves[_i].fetish is "buttslut">>
		@@color:lightcoral;sinks farther into anal pleasure,@@ since she spends her time in the fuckpit with at least one of the many available cocks up her butt.
		<<set $slaves[_i].fetishStrength += 4>>
	<<else>>
		@@color:lightcoral;acquires an anal fetish@@ after helplessly orgasming at the mercy of your many fucktoys eager to shove their big stiff penises up her ass.
		<<set $slaves[_i].fetish to "buttslut", $slaves[_i].fetishStrength = 65>>
	<</if>>
	<<elseif (_masterSuiteAverageCum > 3) && ($fetishChangeChance > random(0,50))>>
	_Verb
	<<if $slaves[_i].fetish is "cumslut">>
		@@color:lightcoral;sinks farther into cum addiction,@@ since she spends her time in the fuckpit eagerly sucking down ejaculate, straight from the many sources.
		<<set $slaves[_i].fetishStrength += 4>>
	<<else>>
		@@color:lightcoral;acquires an oral fixation@@ after orally servicing your many fucktoys eager to blow their loads down her throat.
		<<set $slaves[_i].fetish to "cumslut", $slaves[_i].fetishStrength = 65>>
	<</if>>
	<<elseif (_masterSuiteAveragePreg > 10) && ($fetishChangeChance > random(0,50))>>
	_Verb
	<<if $slaves[_i].fetish is "pregnancy">>
		@@color:lightcoral;sinks farther into pregnancy obession,@@ since she never wants for a pregnant girl to make love to.
		<<set $slaves[_i].fetishStrength += 4>>
	<<else>>
		@@color:lightcoral;acquires an pregnancy fetish,@@ since many of her sexual partners in the fuckpit are heavily pregnant.
		<<set $slaves[_i].fetish to "pregnancy", $slaves[_i].fetishStrength = 65>>
	<</if>>
	<<elseif (_masterSuiteAverageDom < 50) && ($fetishChangeChance > random(0,50))>>
	_Verb
	<<if $slaves[_i].fetish is "dom">>
		@@color:lightcoral;becomes more dominant,@@ since there are so many subs in the fuckpit who beg her to fuck them hard.
		<<set $slaves[_i].fetishStrength += 4>>
	<<else>>
		@@color:lightcoral;becomes sexually dominant@@ after having fun satisfying the many submissive fucktoys in the fuckpit who beg her to top them.
		<<set $slaves[_i].fetish to "dom", $slaves[_i].fetishStrength = 65>>
	<</if>>
	<<elseif (_masterSuiteAverageDom > 50) && ($fetishChangeChance > random(0,50))>>
	_Verb
	<<if $slaves[_i].fetish is "submissive">>
		@@color:lightcoral;becomes even more submissive,@@ since there are so many doms in the fuckpit that she's often used by more than one at once.
		<<set $slaves[_i].fetishStrength += 4>>
	<<else>>
		@@color:lightcoral;becomes sexually submissive@@ after the many dominant slaves in the fuckpit hold her down and use her for their pleasure.
		<<set $slaves[_i].fetish to "sub", $slaves[_i].fetishStrength = 65>>
	<</if>>
	<<elseif (_masterSuiteAverageSadism < 50) && ($fetishChangeChance > random(0,50))>>
	_Verb
	<<if $slaves[_i].fetish is "sadist">>
		@@color:lightcoral;becomes more sadistic,@@ since there are so many girls in the fuckpit who will do anything for her if she'll only spank them.
		<<set $slaves[_i].fetishStrength += 4>>
	<<else>>
		@@color:lightcoral;becomes a bit of a sadist@@ after she notices that so many of her fellow fucktoys cum harder if she gives them a good slap.
		<<set $slaves[_i].fetish to "sadist", $slaves[_i].fetishStrength = 65>>
	<</if>>
	<<elseif (_masterSuiteAverageSadism > 50) && ($fetishChangeChance > random(0,50))>>
	<<if $slaves[_i].fetish is "masochist">>
		<<if $verboseDescriptions == 1>>Her<<else>>$slaves[_i].slaveName's<</if>> @@color:lightcoral;pain addiction deepens,@@ since the fuckpit is full of ladies happy to fuck her while she screams.
		<<set $slaves[_i].fetishStrength += 4>>
	<<else>>
		<<if $verboseDescriptions == 1>>She<<else>>$slaves[_i].slaveName<</if>> @@color:lightcoral;learns masochism@@ after experiencing many orgasms under the exquisite sexual torture of the sadists in the fuckpit.
		<<set $slaves[_i].fetish to "masochist", $slaves[_i].fetishStrength = 65>>
	<</if>>
	<</if>>
	<<if $slaves[_i].energy > 40 && $slaves[_i].energy < 95>>
		Being a constant part of the fuckpit orgy @@color:lime;greatly heightens her libido.@@
		<<set $slaves[_i].energy += 2>>
	<</if>>
<</if>>
<</if>>

<</if>>

<<if $verboseDescriptions == 1>>
	<<if $slaves[_i].choosesOwnClothes == 1>>
	<<include "SA chooses own clothes">>
	<<if ($slaves[_i].devotion <= 20)>>
		<<set $slaves[_i].devotion -= 5>>
	<<else>>
		<<set $slaves[_i].devotion += 1>>
	<</if>>
	<</if>>
	<<include "SA diet">>
	<<include "SA long term effects">>
	<<include "SA drugs">>
	<<include "SA relationships">>
	<<include "SA rivalries">>
<<else>>
	<<silently>>
	<<if $slaves[_i].choosesOwnClothes == 1>>
	<<include "SA chooses own clothes">>
	<<if ($slaves[_i].devotion <= 20)>>
		<<set $slaves[_i].devotion -= 5>>
	<<else>>
		<<set $slaves[_i].devotion += 1>>
	<</if>>
	<</if>>
	<<include "SA diet">>
	<<include "SA long term effects">>
	<<include "SA drugs">>
	<<include "SA relationships">>
	<<include "SA rivalries">>
	<</silently>>
<</if>>
<<if $slaves[_i].health < 80>>
	<<if $masterSuiteUpgradeLuxury == 1>>
	<<set $slaves[_i].health += 20>>
	<<else>>
	<<set $slaves[_i].health += 10>>
	<</if>>
<</if>>

<<if $masterSuiteUpgradePregnancy == 1>>
	/* If they're not on fertility drugs and the toggle is active, stick them on (if they can take them). Otherwise take them off. */
	<<if ($masterSuitePregnancyFertilityDrugs == 1) && ($slaves[_i].drugs != "fertility drugs") && canGetPregnant($slaves[_i]) and ($slaves[_i].assignment is "serve in the master suite" or $slaves[_i].assignment is "be your Concubine")>>
		<<set $slaves[_i].drugs = "fertility drugs">>
	<<elseif ($masterSuiteHyperPregnancy == 1) && ($slaves[_i].drugs != "super fertility drugs") && canGetPregnant($slaves[_i]) and ($slaves[_i].assignment is "serve in the master suite" or $slaves[_i].assignment is "be your Concubine")>>
		<<set $slaves[_i].drugs to "super fertility drugs">>
	<<elseif ((($masterSuitePregnancyFertilityDrugs == 0) && ($slaves[_i].drugs is "fertility drugs")) || (($masterSuiteHyperPregnancy == 0) && ($slaves[_i].drugs is "super fertility drugs"))) && ($slaves[_i].assignment is "serve in the master suite" or $slaves[_i].assignment is "be your Concubine")>>
		<<set $slaves[_i].drugs to "no drugs">>
	<</if>>
	/* We don't know they're pregnant for a month or so by game logic */
	<<if ($slaves[_i].preg >= 4)>>
	/* Once we know they're knocked up, get the counter going. */
	<<set _masterSuitePregnantSlaves += 1>>
	/* Don't know about twins/triplets etc until 10 weeks. Once we do, get the counter going */
	<<if ($slaves[_i].pregType > 1) && ($slaves[_i].preg >= 10)>>
		<<set _masterSuitePregnantSlavesMultiple += 1>>
	<</if>>
	/* If they're preggo and in the upgraded suite, give them extra devotion. More if they're being given lighter duties. */
	<<if ($slaves[_i].devotion <= 100)>>
	<<if ($masterSuitePregnancySlaveLuxuries == 0)>>
		<<set $slaves[_i].devotion += 2>>
	<<else>>
		<<set $slaves[_i].devotion += 5>>
	<</if>>
	<</if>>
	/* If they're preggo and in the upgraded suite, give them extra trust. More if they're being given lighter duties. */
	<<if ($slaves[_i].trust <= 100)>>
	<<if ($masterSuitePregnancySlaveLuxuries == 0)>>
		<<set $slaves[_i].trust += 2>>
	<<else>>
		<<set $slaves[_i].trust += 5>>
	<</if>>
	<</if>>
	/* If they're preggo and in the upgraded suite, give them extra health. More if they're being given lighter duties. */
	<<if ($slaves[_i].health < 100)>>
	<<if ($masterSuitePregnancySlaveLuxuries == 0)>>
		<<set $slaves[_i].health += 15>>
	<<else>>
		<<set $slaves[_i].health += 25>>
	<</if>>
	<</if>>
	<</if>>
<</if>>

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

<<if _CCB != -1>>
	<<set $Concubine = $slaves[_CCB]>>
<</if>>

<<if $arcologies[0].FSRestart != "unset">>
<<if $propOutcome != 1>>
<<if $masterSuitePregnantSlaves > 0>>
	The Societal Elite know what you are doing with your bedslaves. @@color:red;They do not approve@@.
	<<set $failedElite += 5*$masterSuitePregnantSlaves>>
<</if>>
<</if>>
<</if>>

<<if $masterSuiteDecoration != "standard">>

	$masterSuiteNameCaps's $masterSuiteDecoration atmosphere @@color:hotpink;has a minor impact on your fucktoys.@@
<</if>>

<<if $verboseDescriptions == 1>>
<</if>>

<<else>>
	''The master suite is empty.''
<</if>>