code:
:: Servants' Quarters

<<nobr>>
<<set $nextButton to "Back to Main", $nextLink to "Main", $returnTo to "Servants' Quarters">>

<<if $servantsQuartersName != "the Servants' Quarters">>
	<<set $servantsQuartersNameCaps to $servantsQuartersName.replace("the ", "The ")>>
<</if>>

<<set $servantsQuartersSlaves to 0>>
<<set $notservantsQuartersSlaves to 0>>
<<for _i to 0; _i < $slaves.length; _i++>>
	<<if $slaves[_i].assignment is "work as a servant">>
		<<set $servantsQuartersSlaves++>>
	<<else>>
		<<set $notservantsQuartersSlaves++>>
	<</if>>
<</for>>

$servantsQuartersNameCaps
<<switch $servantsQuartersDecoration>>
<<case "Roman Revivalist">>
	are spartan, yet functional. At one end of the long dormitory there is an alcove with a shrine to the Roman goddess of domesticity.
<<case "Egyptian Revivalist">>
	are utilitarian, yet warm and well-kept. At one end of the long dormitory there is an alcove with a shrine to the Egyptian goddess of servility.
<<case "Edo Revivalist">>
	are spartan and functional. Fresh mats are laid across the floor every day, and the simple beds of blankets and wooden blocks are neatly stowed against the walls before sunrise.
<<case "Arabian Revivalist">>
	are utilitarian, yet warm and well-kept. They are floored with beautifully patterned tile; there are channels for clean running water that make it easy to keep clean and fresh, so long as one is willing to bathe in the open.
<<case "Chinese Revivalist">>
	are spartan, yet functional. At one end of the long dormitory there is an alcove with a shrine hosting a bronze statue of a watchful dragon.
<<case "Chattel Religionist">>
	are spartan, yet functional. Servants here are expected to be clean and hardworking, and there is a penitents cell ready for them if they are not.
<<case "Degradationist">>
	are severe and utilitarian. Servants sleep uncomfortably here, knowing that even on their meager bedrolls, they are fair game for abuse.
<<case "Repopulation Focus">>
	are comfortable and well-kept. Though there is little privacy here, the servants are provided for. There's even a small rest area for them to rest their pregnant bodies between shifts. A closet contains specialized cleaning tools to accommodate their distended bodies.
<<case "Eugenics">>
	are comfortable and well-kept. Though there is little privacy here, the servants are provided for. They are required to always be carrying prophylactics for other slaves and any low class citizens who require them.
<<case "Asset Expansionist">>
	are comfortable and well-kept. There are pornographic pictures on the walls, depicting slaves with gigantic breasts earnestly enjoying huge cocks.
<<case "Transformation Fetishist">>
	are comfortable and well-kept. There are pornographic pictures on the walls, depicting slaves with huge implants earnestly enjoying sex.
<<case "Gender Radicalist">>
	are comfortable and well-kept. There are pornographic pictures on the walls, depicting all sorts of slaves earnestly enjoying taking cocks up their anuses.
<<case "Gender Fundamentalist">>
	are comfortable and well-kept. There are pornographic pictures on the walls, depicting pretty female slaves being fucked by muscular men.
<<case "Physical Idealist">>
	are comfortable and well-kept. There are softcore pictures on the walls, depicting gorgeously muscled, oiled-up men and women, flexing and posing for the camera.
<<case "Supremacist">>
	are spartan, since that's all domestics from the inferior races need or deserve. There's a whipping post in the corner of the room so that whenever a slave is beaten, the rest must watch.
<<case "Subjugationist">>
	are spartan, since that's all $arcologies[0].FSSubjugationistRace domestics need or deserve. There's a whipping post in the corner of the room so that whenever a slave is beaten, the rest must watch.
<<case "Paternalist">>
	are comfortable and well-kept. Though there is little privacy here, the servants are provided for. There's even a small rest area for them to take their regular breaks in.
<<case "Pastoralist">>
	are comfortable and well-kept. There are pornographic pictures on the walls, depicting lactating slaves earnestly enjoying sex. The servants are provided with milk to drink.
<<case "Maturity Preferentialist">>
	are comfortable, but functional. There are motivational posters on the walls featuring cheerful MILF servants, exhorting mature slaves to smile, serve, and get fucked like good girls.
<<case "Youth Preferentialist">>
	are comfortable, but well equipped to corral wayward slaves. There are instructional screens in the common areas reviewing basic slave tasks like scrubbing a floor and giving head.
<<case "Body Purist">>
	are comfortable and well-kept. There are pornographic pictures on the walls, depicting gorgeous slaves earnestly enjoying sex.
<<case "Slimness Enthusiast">>
	are comfortable and well-kept. There are pornographic pictures on the walls, depicting slender slaves earnestly enjoying sex.
<<default>>
	are comfortable. Servants sleep together in a dormitory, eat together in a little kitchen, bathe together in a communal shower, and then head out into the penthouse to serve.
<</switch>>

<<if $servantsQuartersSlaves > 2>>
	$servantsQuartersNameCaps are busy with hurrying slaves. One shift of girls is eating, cleaning the quarters, and bathing. The second is sleeping, and the third is out in the penthouse cleaning and serving.
<<elseif $servantsQuartersSlaves > 0>>
	A few slaves are working out of servants' quarters. They must split their scant time between looking after their own needs and the superior needs of everyone else.
<<elseif $Stewardess != 0>>
	$Stewardess.slaveName is alone, and seems rather bereft without anyone to order around.
<<else>>
	None of your slaves are working out of the servants' quarters. [[Decommission the quarters|Main][$servantsQuarters to 0, $servantsQuartersUpgradeMonitoring to 0, $servantsQuartersDecoration to "standard"]]
<</if>>

$servantsQuartersNameCaps has room to keep $servantsQuarters slaves while they serve.
[[Expand the servant's Quarters|Servants' Quarters][$cash -=  Math.trunc($servantsQuarters*1000*$upgradeMultiplierArcology), $servantsQuarters += 5]] //Costs ¤<<print Math.trunc($servantsQuarters*1000*$upgradeMultiplierArcology)>>//

<<if $servantsQuartersUpgradeMonitoring == 1>>
	The quarters have been upgraded with enhanced monitoring systems to make the servants work harder, improving their obedience and efficiency.
<<else>>
	The quarters are standard. [[Upgrade the monitoring systems to force harder work|Servants' Quarters][$cash -= Math.trunc(10000*$upgradeMultiplierArcology), $servantsQuartersUpgradeMonitoring to 1]] //Costs ¤<<print Math.trunc(10000*$upgradeMultiplierArcology)>> and will increase upkeep costs//
<</if>>

<<if $servantMilkers == 1>>

Since servants spend most of their time in the penthouse, any who are lactating will use the ubiquitous milkers
<</if>>

<<if $Stewardess != 0>>
	<<set $Flag to 2>>
	<<display "Slave Summary">>
	<<if canAchieveErection($Stewardess) && $Stewardess.pubertyXY == 1>>

		<<if $stewardessImpregnates == 1>>
			Keeping the maids pregnant is part of her job. [[Order her to stop impregnating|Servants' Quarters][$stewardessImpregnates to 0]]
		<<else>>
			She could be directed to keep the maids pregnant herself. [[Order her to impregnate|Servants' Quarters][$stewardessImpregnates to 1]]
		<</if>>
	<</if>>
<<else>>
	You do not have a slave serving as a Stewardess. [[Appoint one|Stewardess Select]]
<</if>>

<<if $servantsQuartersSlaves > 0>>

''Bring a slave out of $servantsQuartersName:''
	<<set $Flag to 1>>
	<<display "Slave Summary">>
<</if>>

<<if $notservantsQuartersSlaves > 0>>

''Send a slave to work out of $servantsQuartersName:''
	<<set $Flag to 0>>
	<<display "Slave Summary">>
<</if>>
<<unset $Flag>>

Rename $servantsQuartersName: <<textbox "$servantsQuartersName" $servantsQuartersName "Servants' Quarters">> //Use a noun or similar short phrase//
<</nobr>>


code:
:: Servants' Quarters Report [nobr]

''Servants' Quarters Report''

<<set $servantsQuartersSlaves to 0>>
<<set $stewardessFetish to 0>>
<<set $stewardessBonus to 0>>
<<set $stewardessImpregnated to 0>>
<<set $SQMilk = 0>>
<<set $SQMilkSale = 0>>

<<if ($Stewardess != 0)>>
	<<if ($Stewardess.health >= 10) && ($Stewardess.health < 80)>>
	<<set $stewardessBonus += 50>>
	<<elseif ($Stewardess.health >= 80)>>
	<<set $stewardessBonus += 75>>
	<</if>>
	<<if $stewardessCareers.contains($Stewardess.career)>>
	<<set $stewardessBonus += 25>>
	<</if>>
	<<if ($Stewardess.actualAge > 35)>>
	<<set $stewardessBonus += 25>>
	<</if>>
	<<if ($Stewardess.intelligence > 0)>>
	<<set $stewardessBonus += 25*$Stewardess.intelligence>>
	<</if>>
<</if>>

<<set $servantMilkersMultiplier = 0.5>>
<<for $i to 0; $i < $slaves.length; $i++>>
	<<if ($slaves[$i].assignment is "work as a servant") && $seeImages == 1>>
		<<SlaveArt $slaves[$i] 0 0>>
	<</if>>
	<<set $servantsQuartersSlaves += 1>>
	<<silently>>
	<<display [[SA servant]] && $servantMilkers == 1>>
	<<if $slaves[$i].lactation > 0>>
		<<display "SA get milked">>
		<<set $SQMilk += $milk>>
		<<set $SQMilkSale += $milkSale>>
	<</if>>
	<<if $stewardessImpregnates == 1 && ($Stewardess != 0) && $Stewardess.balls > 0 && $Stewardess.pubertyXY == 1 && canGetPregnant($slaves[$i]) && canBreed($slaves[$i],$Stewardess)>>
		<<set $slaves[$i].preg to 1, $slaves[$i].pregSource to $Stewardess.ID, $stewardessImpregnated += 1, $slaves[$i].vaginalCount += 10, $vaginalTotal += 10>>
	<</if>>
	<<display "SA long term effects">>
	<<display "SA relationships">>
	<<display "SA rivalries">>
	<</silently>>
	<<if ($slaves[$i].devotion <= 20) && ($slaves[$i].trust > -20)>>
	<<set $slaves[$i].devotion -= 5>>
	<<set $slaves[$i].trust -= 5>>
	<<elseif ($slaves[$i].devotion < 2)>>
	<<set $slaves[$i].devotion += 2>>
	<<elseif ($slaves[$i].devotion > 3)>>
	<<set $slaves[$i].devotion -= 2>>
	<</if>>
	<<if $servantsQuartersDecoration != "standard">>
	<<set $slaves[$i].devotion += 1>>
	<</if>>
	<<if ($slaves[$i].trust < -50)>>
	<<set $slaves[$i].trust += 2>>
	<<elseif ($slaves[$i].trust < -6)>>
	<<set $slaves[$i].trust += 1>>
	<</if>>
	<<if ($slaves[$i].health < -80)>>
	<<set $slaves[$i].health += 20>>
	<<elseif ($slaves[$i].health < -40)>>
	<<set $slaves[$i].health += 10>>
	<<elseif ($slaves[$i].health < 0)>>
	<<set $slaves[$i].health += 7>>
	<<elseif ($slaves[$i].health < 90)>>
	<<set $slaves[$i].health += 3>>
	<</if>>
	<<if ($Stewardess != 0)>>
		<<set $cash += $stewardessBonus>>
		<<if ($Stewardess.energy > 95) || (($Stewardess.fetishKnown == 1) && ($Stewardess.fetish is "dom"))>>
			<<if ($slaves[$i].devotion < 45)>><<set $slaves[$i].devotion += 5>><</if>>
		<</if>>
	<</if>>

<<elseif $Stewardess != 0>>
<<if $slaves[$i].ID is $Stewardess.ID>>
	<<silently>>
	<<display "SA long term effects">>
	<<display "SA relationships">>
	<<display "SA rivalries">>
	<</silently>>
	<<if ($slaves[$i].health < -80)>>
	<<set $slaves[$i].health += 20>>
	<<elseif ($slaves[$i].health < -40)>>
	<<set $slaves[$i].health += 15>>
	<<elseif ($slaves[$i].health < 0)>>
	<<set $slaves[$i].health += 10>>
	<<elseif ($slaves[$i].health < 90)>>
	<<set $slaves[$i].health += 7>>
	<</if>>
	<<if $slaves[$i].devotion <= 60>>
	<<set $slaves[$i].devotion += 1>>
	<</if>>
	<<if $servantsQuartersDecoration != "standard">>
	<<set $slaves[$i].devotion += 1>>
	<</if>>
	<<if $slaves[$i].trust < 60>>
	<<set $slaves[$i].trust += 1>>
	<</if>>
	<<if $slaves[$i].fetishStrength <= 95>>
	<<if $slaves[$i].fetish != "dom">>
		<<fetishChangeChance $slaves[$i]>>
		<<if $fetishChangeChance > random(0,100)>>
			<<set $stewardessFetish to 1>>
			<<set $slaves[$i].fetishKnown to 1>>
			<<set $slaves[$i].fetish to "dom">>
		<</if>>
	<<elseif $slaves[$i].fetishKnown == 0>>
		<<set $stewardessFetish to 1>>
		<<set $slaves[$i].fetishKnown to 1>>
	<<else>>
		<<set $stewardessFetish to 2>>
		<<set $slaves[$i].fetishStrength += 4>>
	<</if>>
	<</if>>
	<<set $slaves[$i].penetrativeCount += $stewardessImpregnated>>
	<<set $penetrativeTotal += $stewardessImpregnated>>
<</if>>
<</if>>
<</for>>
<<set $servantMilkersMultiplier = 1>>

<<if ($servantsQuartersSlaves > 0)>>
	<<if $seeImages == 1>>
<</if>>
	<<if ($servantsQuartersSlaves == 1)>>
		''There is one slave working out of the servants' quarters.'' She works to @@color:yellowgreen;reduce@@ your household expenses; having a well-staffed house slightly @@color:green;increases@@ your reputation.
	<<else>>
		''There are $servantsQuartersSlaves slaves working out of the servants' quarters.'' They work to @@color:yellowgreen;reduce@@ your household expenses; having a well-staffed house slightly @@color:green;increases@@ your reputation.
	<</if>>
	<<if $SQMilk > 0>>
		Since your lactating servants spend most of their time working in the penthouse, they use the milkers there, giving $SQMilk liters of milk over the week, which is sold for @@color:yellowgreen;¤$SQMilkSale.@@
	<</if>>

	<<if ($Stewardess != 0)>>
	$Stewardess.slaveName is serving as your stewardess.<<if $Stewardess.relationship is -3>>  She does her best to be your perfect housewife.<</if>>
	<<if $stewardessImpregnated > 0>>
		It's her responsibility to keep her charges pregnant, and
		<<if $stewardessImpregnated == 1>>
			she cums in the fertile one's pussy all week.
		<<else>>
			she ensures the $stewardessImpregnated fertile servants are full of her cum at all times.
		<</if>>
	<</if>>
	<<if $stewardessFetish == 1>>
		She's allowed and even expected to use her charges for her own gratification, and sometimes they'll even instigate submissive sex with her just to ingratiate themselves. She becomes comfortable with the role of a @@color:lightcoral;sexual dominant.@@
	<<elseif $stewardessFetish == 2>>
		Having a legion of girls jumping to obey her daily commands @@color:lightsalmon;makes her more dominant.@@
	<</if>>
	<<if ($Stewardess.health < 10)>>
		Though $Stewardess.slaveName tries to watch the servants, her lack of good health inhibits her.
	<<elseif ($Stewardess.health < 80)>>
		Her good health allows her to work long hours and @@color:yellowgreen;drive@@ the servants hard.
	<<else>>
		Her perfect health allows her to work exhaustive hours and @@color:yellowgreen;drive@@ the servants very hard.
	<</if>>
	<<if $stewardessCareers.contains($Stewardess.career)>>
		She has applicable experience with daily sums and organizational trifles from her life before she was a slave.
	<</if>>
	<<if ($Stewardess.actualAge > 35)>>
		Her age and experience give her added effectiveness.
	<</if>>
	<<if ($Stewardess.intelligence > 0)>>
		She's smart enough that she misses very little.
	<</if>>
	<<for $i to 0; $i < $slaves.length; $i++>>
		<<if $slaves[$i].assignment is "work as a servant">>
		<<if $familyTesting == 1>>
			<<if $slaves[$i].mother == $Stewardess.ID>>
				She pays special attention to her daughter, $slaves[$i].slaveName, making sure she doesn't slack off just because they are related.
				<<set $slaves[$i].trust += 1>>
			<</if>>
			<<if $slaves[$i].father == $Stewardess.ID>>
				She pays special attention to her daughter, $slaves[$i].slaveName, making sure she doesn't slack off just because they are related.
				<<set $slaves[$i].trust += 1>>
			<</if>>
			<<if $slaves[$i].ID == $Stewardess.father>>
				She pays special attention to her father, $slaves[$i].slaveName, making sure she doesn't slack off just because they are related.
				<<set $slaves[$i].trust += 1>>
			<</if>>
			<<if $slaves[$i].ID == $Stewardess.mother>>
				She pays special attention to her mother, $slaves[$i].slaveName, making sure she doesn't slack off just because they are related.
				<<set $slaves[$i].trust += 1>>
			<</if>>
			<<if areSisters($slaves[$i], $Stewardess) == 1>>
				She pays special attention to her twin, $slaves[$i].slaveName, making sure she doesn't slack off just because they are related.
				<<set $slaves[$i].trust += 1>>
			<<elseif areSisters($slaves[$i], $Stewardess) == 2>>
				She pays special attention to her sister, $slaves[$i].slaveName, making sure she doesn't slack off just because they are related.
				<<set $slaves[$i].trust += 1>>
			<<elseif areSisters($slaves[$i], $Stewardess) == 3>>
				She pays special attention to her half-sister, $slaves[$i].slaveName, making sure she doesn't slack off just because they are related.
				<<set $slaves[$i].trust += 1>>
			<</if>>
		<<else>>
			<<if $Stewardess.relationTarget is $slaves[$i].ID>>
				She pays special attention to her $slaves[$i].relation, $slaves[$i].slaveName, making sure she doesn't slack off just because they are related.
				<<set $slaves[$i].trust += 1>>
			<</if>>
		<</if>>
		<<if $Stewardess.relationshipTarget is $slaves[$i].ID>>
			She dotes over her <<if $Stewardess.relationship == 1>>friend<<elseif $Stewardess.relationship is 2>>best friend<<elseif $Stewardess.relationship is 3>>friend with benefits<<elseif $Stewardess.relationship is 4>>lover<<elseif $Stewardess.relationship is 5>>slave wife<</if>>, $slaves[$i].slaveName, making sure she is knows how to do a good job and keeps her well stocked with everything she needs.
			<<set $slaves[$i].devotion += 1>>
		<</if>>
		<<if $Stewardess.rivalryTarget is $slaves[$i].ID>>
			She bears down on her <<if $Stewardess.rivalry == 1>>growing rival<<elseif $Stewardess.rivalry is 2>>rival<<elseif $Stewardess.rivalry is 3>>bitter rival<</if>>, $slaves[$i].slaveName, forcing her to work extra hard or suffer punishment.
			<<set $slaves[$i].devotion -= 1>>
			<<set $slaves[$i].trust -= 1>>
			<<if random(1,100) > 65>>
				<<set $Stewardess.rivalry += 1>>
			<<set $slaves[$i].rivalry += 1>>
			<</if>>
		<</if>>
		<<if $slaves[$i].prestigeDesc is "She is a famed Free Cities whore, and commands top prices.">>
			She does her best to motivate the famous whore, $slaves[$i].slaveName, though she is uncertain why she is here.
		<</if>>
		<<if $slaves[$i].prestigeDesc is "She is a famed Free Cities slut, and can please anyone.">>
			She ignores her duties in order the fawn over the famous entertainer, $slaves[$i].slaveName.
		<</if>>
		<<if $slaves[$i].prestigeDesc is "She is remembered for winning best in show as a cockmilker.">>
			$slaves[$i].slaveName leaves a trail of cum wherever she goes and frequently stops to masturbate, greatly annoying $Stewardess.slaveName.
			<<if random(1,100) > 90 and $Stewardess.rivalry == 0 and $slaves[$i].rivalry == 0>>
			<<set $Stewardess.rivalryTarget to $slaves[$i].ID>>
				<<set $Stewardess.rivalry += 1>>
			<<set $slaves[$i].rivalryTarget to $Stewardess.ID>>
			<<set $slaves[$i].rivalry += 1>>
			<</if>>
		<</if>>
		<<if $slaves[$i].prestigeDesc is "She is remembered for winning best in show as a dairy cow.">>
			$slaves[$i].slaveName's huge breasts frequently get in the way of her work and she leaks milk everywhere, greatly annoying $Stewardess.slaveName.
			<<if random(1,100) > 90 and $Stewardess.rivalry == 0 and $slaves[$i].rivalry == 0>>
			<<set $Stewardess.rivalryTarget to $slaves[$i].ID>>
				<<set $Stewardess.rivalry += 1>>
			<<set $slaves[$i].rivalryTarget to $Stewardess.ID>>
			<<set $slaves[$i].rivalry += 1>>
			<</if>>
		<</if>>
		<<if $slaves[$i].prestigeDesc is "She is remembered for winning best in show as a breeder." and $slaves[$i].preg > 20>>
			$slaves[$i].slaveName's big pregnant belly frequently gets in the way of her work. However, $Stewardess.slaveName is willing to overlook it, as well as allow her easy jobs, due to how valuable her womb is.
		<</if>>
		<</if>>
	<</for>>
	<<if ($Stewardess.fetishKnown == 1)>>
		<<if ($Stewardess.fetish is "dom")>>
		She walks among the cowering servants as a queen among peasants, playing the role of dominant to perfection and increasing her charges' @@color:hotpink;obedience.@@
		<</if>>
	<<elseif ($Stewardess.energy > 95)>>
		She walks among the cowering servants looking for an excuse to extract sex from shirkers as @@color:hotpink;punishment.@@
	<</if>>
	<<if $stewardessImpregnated == 1>>
		The Societal Elite know you've ordered $Stewardess.slaveName to impregnate your maids. @@color:red;They are not amused by your disenterest in eugenics.@@
		<<set $failedElite += 10>>
	<</if>>
	<</if>>
	<<set $repGain += $servantsQuartersSlaves*20>>

	<<if $servantsQuarters < $servantsQuartersSlaves>>
	<<set $servantsQuartersSpots to 0>>
	<<else>>
	<<set $servantsQuartersSpots to $servantsQuarters - $servantsQuartersSlaves>>
	<</if>>

	<<if $servantsQuartersDecoration != "standard">>
	$servantsQuartersNameCaps's $servantsQuartersDecoration atmosphere @@color:hotpink;has a minor impact on your servants.@@
	<</if>>

<<else>>
	''$servantsQuartersNameCaps is empty.''
	<<set $servantsQuartersSpots to $servantsQuarters>>
<</if>>

repo_name: ThreadAnon/fc


code:
:: Siblings Workaround

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

<<display "Nationality to Name">>
<<display "Nationality to Accent">>

<<set _secondSlave to $activeSlave>>

<<if $useFSNames == 0>>
	<<set _secondSlave.slaveName to _secondSlave.birthName>>
<<elseif $arcologies[0].FSChattelReligionist > 20>>
	<<set _secondSlave.slaveName to $chattelReligionistSlaveNames.random()>>
<<elseif $arcologies[0].FSRomanRevivalist > 20>>
	<<set _secondSlave.slaveName to $romanSlaveNames.random()>>
<<elseif $arcologies[0].FSEgyptianRevivalist > 20>>
	<<set _secondSlave.slaveName to $ancientEgyptianSlaveNames.random()>>
<<elseif $arcologies[0].FSEdoRevivalist > 20>>
	<<set _secondSlave.slaveName to $edoSlaveNames.random()>>
<<elseif $arcologies[0].FSDegradationist != "unset">>
	<<display "Degrading Name">>
<<else>>
	<<set _secondSlave.slaveName to _secondSlave.birthName>>
<</if>>

<<set _secondSlave.slaveName to $activeSlave.birthName>>
<<set _secondSlave.ID to $activeSlave.ID + 1000>>
<<set _secondSlave.devotion -= random(5,-5)>>
<<set _secondSlave.oldDevotion to _secondSlave.devotion>>
<<set _secondSlave.trust -= random(5,-5)>>
<<set _secondSlave.oldTrust to _secondSlave.trust>>
<<set _secondSlave.oldDevotion to $activeSlave.devotion>>
<<set _secondSlave.actualAge -= random (1, 5)>>
<<set _secondSlave.visualAge = _secondSlave.actualAge>>
<<set _secondSlave.physicalAge = _secondSlave.actualAge>>

<<set _secondSlave.attrXX += random(-20,20)>>
<<set _secondSlave.attrXX = Math.clamp(_secondSlave.attrXX, 0, 100)>>
<<set _secondSlave.attrXY += random(-20,20)>>
<<set _secondSlave.attrXY = Math.clamp(_secondSlave.attrXY, 0, 100)>>
<<set _secondSlave.energy += random(-20,20)>>
<<set _secondSlave.fetishStrength to random(0,90)>>
<<set _secondSlave.fetish to either("none", "none", "none", "none", "none", "none", "submissive", "cumslut", "humiliation", "buttslut", "pregnancy", "sadist", "dom", "masochist")>>
<<set $activeSlave.behavioralFlaw to either("none", "none", "none", "arrogant", "bitchy", "odd", "hates men", "hates women", "hates women", "anorexic", "masochist", "gluttonous", "devout", "liberated")>>
<<if ($activeSlave.behavioralFlaw is "devout")>>
	<<set $activeSlave.sexualFlaw to either("none", "repressed",  "shamefast", "apathetic")>>
<<else>>
	<<set $activeSlave.sexualFlaw to either("none", "none", "none", "none", "hates oral", "hates anal", "hates penetration", "repressed", "idealistic", "shamefast", "apathetic", "crude", "judgemental")>>
<</if>>

<<if $familyTesting == 0>>
<<set _secondSlave.relation to "sister">>
<<set _secondSlave.relationTarget to $activeSlave.ID - 1000>>
<</if>>

<<if _secondSlave.actualAge < $minimumSlaveAge>>
	<<set _secondSlave.actualAge to $minimumSlaveAge>>
	<<set _secondSlave.visualAge = _secondSlave.actualAge>>
	<<set _secondSlave.physicalAge = _secondSlave.actualAge>>
<</if>>

<<if _secondSlave.boobs > 200>>
	<<set _secondSlave.boobs += random (-100, 100)>>
<</if>>

<<if _secondSlave.butt > 1>>
	<<set _secondSlave.butt += random (-1, 1)>>
<</if>>

	<<set $slaves.push(_secondSlave)>>


code:
:: Slave Assignments Report [nobr]

<<set $nextLink to "Economics", $nextButton to "Continue">>

<<for _i to 0; _i < $slaves.length; _i++>>

<<if ndef $slaves[_i].whoreSkill>>
	@@color:yellow;Reset bad whore skill for $slaves[_i].slaveName.@@ Report this as a bug if it reoccurs.

	<<set $slaves[_i].whoreSkill to 0>>
<</if>>
<<if ndef $slaves[_i].entertainSkill>>
	@@color:yellow;Reset bad entertain skill for $slaves[_i].slaveName.@@ Report this as a bug if it reoccurs.

	<<set $slaves[_i].entertainSkill to 0>>
<</if>>
<<if ndef $slaves[_i].vaginalSkill>>
	@@color:yellow;Reset bad vaginal skill for $slaves[_i].slaveName.@@ Report this as a bug if it reoccurs.

	<<set $slaves[_i].vaginalSkill to 0>>
<</if>>
<<if ndef $slaves[_i].analSkill>>
	@@color:yellow;Reset bad anal skill for $slaves[_i].slaveName.@@ Report this as a bug if it reoccurs.

	<<set $slaves[_i].analSkill to 0>>
<</if>>
<<if ndef $slaves[_i].oralSkill>>
	@@color:yellow;Reset bad skill for $slaves[_i].slaveName.@@ Report this as a bug if it reoccurs.

	<<set $slaves[_i].oralSkill to 0>>
<</if>>

<<if ($seeDicks > 0) && ($slaves[_i].dick > 0) && ($slaves[_i].balls > 0) && ($slaves[_i].hormones <= 0) && ($slaves[_i].dickAccessory != ("chastity")) && ($slaves[_i].releaseRules != "restrictive")>>
	<<set $averageDick += $slaves[_i].dick, $slavesWithWorkingDicks++>>
<</if>>

<<switch $slaves[_i].assignment>>
<<case "be your Head Girl">>
	<<set $HeadGirl to $slaves[_i]>>
	<<if $HeadGirl.fetish is "mindbroken">>
		''__@@color:pink;$HeadGirl.slaveName@@__'' is mindbroken @@color:yellow;and cannot serve as your head girl any more.@@

		<<set $HeadGirl to 0>>
	<<elseif canTalk($HeadGirl) == false>>
		''__@@color:pink;$HeadGirl.slaveName@@__'' can't give slaves verbal orders @@color:yellow;and cannot serve as your head girl any more.@@

		<<set $HeadGirl to 0>>
	<<elseif canWalk($HeadGirl) != true>>
		''__@@color:pink;$HeadGirl.slaveName@@__'' is no longer independently mobile @@color:yellow;and cannot serve as your head girl any more.@@

		<<set $HeadGirl to 0>>
	<<elseif canSee($HeadGirl) != true>>
		''__@@color:pink;$HeadGirl.slaveName@@__'' can no longer see @@color:yellow;and cannot serve as your head girl any more.@@

		<<set $HeadGirl to 0>>
	<<elseif $HeadGirl.preg > 31 && $HeadGirl.pregType is 50>>
		''__@@color:pink;$HeadGirl.slaveName@@__'' spends so much time giving birth and laboring that @@color:yellow;she cannot effectively serve as your head girl any longer@@.
		<<set $HeadGirl to 0>>
	<<elseif $HeadGirl.devotion <= 20>>
		''__@@color:pink;$HeadGirl.slaveName@@__'' is no longer even accepting of you, @@color:yellow;and cannot serve as your head girl any more.@@

		<<set $HeadGirl to 0>>
	<</if>>
	<<if $HeadGirl != 0>>
		<<set $HGEnergy++>>
		<<if $HeadGirl.balls > 0>>
			<<set $HGBalls to 1>>
		<</if>>
		<<if $arcologies[0].FSChineseRevivalistLaw == 1>>
			<<set $HGEnergy++>>
		<</if>>
		<<if $personalAttention is "HG">>
			<<if $HeadGirl.trust > 95>>
				<<set $HGEnergy += 2>>
			<<else>>
				<<set $HGEnergy++>>
			<</if>>
		<</if>>
		<<if canAchieveErection($HeadGirl)>>
			<<set $HGCum = 2+Math.trunc(($HeadGirl.balls/5)+($HeadGirl.energy/95)+($HeadGirl.health/95)+($HeadGirl.devotion/95))>>
		<</if>>
	<<else>>
		<<set $slaves[_i].assignment to "rest", $slaves[_i].assignmentVisible to 1>>
	<</if>>
<<case "live with your Head Girl">>
	<<if random(-30,20) <= $slaves[_i].devotion>>
		<<set $HGSlaveSuccess++, $HGEnergy++>>
	<<else>>
		<<set $HGSlaveSuccess-->>
	<</if>>
<<case "recruit girls">>
	<<set $Recruiter to $slaves[_i]>>
	<<if $Recruiter.fetish is "mindbroken">>
		''__@@color:pink;$Recruiter.slaveName@@__'' is mindbroken @@color:yellow;and cannot serve as your recruiter any more.@@

		<<set $Recruiter to 0>>
	<<elseif canTalk($Recruiter) == false>>
		''__@@color:pink;$Recruiter.slaveName@@__'' can't verbally entice marks @@color:yellow;and cannot serve as your recruiter any more.@@

		<<set $Recruiter to 0>>
	<<elseif $Recruiter.preg > 31 && $Recruiter.pregType is 50>>
		''__@@color:pink;$Recruiter.slaveName@@__'' spends so much time giving birth and laboring that @@color:yellow;she cannot effectively serve as your recruiter any longer@@.
		<<set $Recruiter to 0>>
		<<set $slaves[_i].assignment to "rest", $slaves[_i].assignmentVisible to 1>>
	<<elseif canWalk($Recruiter) != true>>
		''__@@color:pink;$Recruiter.slaveName@@__'' is no longer independently mobile @@color:yellow;and cannot serve as your recruiter any more.@@

		<<set $Recruiter to 0>>
	<<elseif canSee($Recruiter) != true>>
		''__@@color:pink;$Recruiter.slaveName@@__'' can no longer see @@color:yellow;and cannot serve as your recruiter any more.@@

		<<set $Recruiter to 0>>
	<</if>>
	<<if $Recruiter == 0>>
		<<set $slaves[_i].assignment to "rest", $slaves[_i].assignmentVisible to 1>>
	<</if>>
<<case "be the Madam">>
	<<set $Madam to $slaves[_i]>>
	<<if canTalk($Madam) == false>>
		''__@@color:pink;$Madam.slaveName@@__'' can't give whores verbal orders @@color:yellow;and cannot serve as your Madam any more.@@

		<<set $Madam to 0>>
	<<elseif $Madam.preg > 31 && $Madam.pregType is 50>>
		''__@@color:pink;$Madam.slaveName@@__'' spends so much time giving birth and laboring that @@color:yellow;she cannot effectively serve as your Madam any longer@@.
		<<set $Madam to 0>>
	<<elseif $Madam.fetish is "mindbroken">>
		''__@@color:pink;$Madam.slaveName@@__'' is mindbroken @@color:yellow;and cannot serve as your Madam any more.@@

		<<set $Madam to 0>>
	<<elseif canWalk($Madam) != true>>
		''__@@color:pink;$Madam.slaveName@@__'' is no longer independently mobile @@color:yellow;and cannot serve as your Madam any more.@@

		<<set $Madam to 0>>
	<<elseif canSee($Madam) != true>>
		''__@@color:pink;$Madam.slaveName@@__'' can no longer see @@color:yellow;and cannot serve as your Madam any more.@@

		<<set $Madam to 0>>
	<</if>>
	<<if $Madam == 0>>
		<<set $slaves[_i].assignment to "rest", $slaves[_i].assignmentVisible to 1>>
	<</if>>
<<case "be the DJ">>
	<<set $DJ to $slaves[_i]>>
	<<if canTalk($DJ) == false>>
		''__@@color:pink;$DJ.slaveName@@__'' can't speak @@color:yellow;and cannot serve as your DJ any more.@@

		<<set $DJ to 0>>
	<<elseif $DJ.preg > 31 && $DJ.pregType is 50>>
		''__@@color:pink;$DJ.slaveName@@__'' spends so much time giving birth and laboring that @@color:yellow;she cannot effectively serve as your DJ any longer@@.
		<<set $DJ to 0>>
	<<elseif $DJ.fetish is "mindbroken">>
		''__@@color:pink;$DJ.slaveName@@__'' is mindbroken @@color:yellow;and cannot serve as your DJ any more.@@

		<<set $DJ to 0>>
	<<elseif canWalk($DJ) != true>>
		''__@@color:pink;$DJ.slaveName@@__'' is no longer independently mobile @@color:yellow;and cannot serve as your DJ any more.@@

		<<set $DJ to 0>>
	<</if>>
	<<if $DJ == 0>>
		<<set $slaves[_i].assignment to "rest", $slaves[_i].assignmentVisible to 1>>
	<</if>>
<<case "be the Milkmaid">>
	<<set $Milkmaid to $slaves[_i]>>
	<<if $Milkmaid.fetish is "mindbroken">>
		''__@@color:pink;$Milkmaid.slaveName@@__'' is mindbroken @@color:yellow;and cannot serve as your Milkmaid any more.@@

		<<set $Milkmaid to 0>>
	<<elseif $Milkmaid.preg > 31 && $Milkmaid.pregType is 50>>
		''__@@color:pink;$Milkmaid.slaveName@@__'' spends so much time giving birth and laboring that @@color:yellow;she cannot effectively serve as your Milkmaid any longer@@.
		<<set $Milkmaid to 0>>
	<<elseif canWalk($Milkmaid) != true>>
		''__@@color:pink;$Milkmaid.slaveName@@__'' is no longer independently mobile @@color:yellow;and cannot serve as your Milkmaid any more.@@

		<<set $Milkmaid to 0>>
	<<elseif canSee($Milkmaid) != true>>
		''__@@color:pink;$Milkmaid.slaveName@@__'' can no longer see @@color:yellow;and cannot serve as your Milkmaid any more.@@

		<<set $Milkmaid to 0>>
	<</if>>
	<<if $Milkmaid == 0>>
		<<set $slaves[_i].assignment to "rest", $slaves[_i].assignmentVisible to 1>>
	<</if>>
<<case "be the Stewardess">>
	<<set $Stewardess to $slaves[_i]>>
	<<if canTalk($Stewardess) == false>>
		''__@@color:pink;$Stewardess.slaveName@@__'' can't give servants verbal orders @@color:yellow;and cannot serve as your Stewardess any more.@@

		<<set $Stewardess to 0>>
	<<elseif $Stewardess.preg > 31 && $Stewardess.pregType is 50>>
		''__@@color:pink;$Stewardess.slaveName@@__'' spends so much time giving birth and laboring that @@color:yellow;she cannot effectively serve as your Stewardess any longer@@.
		<<set $Stewardess to 0>>
	<<elseif $Stewardess.fetish is "mindbroken">>
		''__@@color:pink;$Stewardess.slaveName@@__'' is mindbroken @@color:yellow;and cannot serve as your Stewardess any more.@@

		<<set $Stewardess to 0>>
	<<elseif canWalk($Stewardess) != true>>
		''__@@color:pink;$Stewardess.slaveName@@__'' is no longer independently mobile @@color:yellow;and cannot serve as your Stewardess any more.@@

		<<set $Stewardess to 0>>
	<<elseif canSee($Stewardess) != true>>
		''__@@color:pink;$Stewardess.slaveName@@__'' can no longer see @@color:yellow;and cannot serve as your Stewardess any more.@@

		<<set $Stewardess to 0>>
	<</if>>
	<<if $Stewardess == 0>>
		<<set $slaves[_i].assignment to "rest", $slaves[_i].assignmentVisible to 1>>
	<</if>>
<<case "be the Schoolteacher">>
	<<set $Schoolteacher to $slaves[_i]>>
	<<if canTalk($Schoolteacher) == false>>
		''__@@color:pink;$Schoolteacher.slaveName@@__'' can't give verbal instruction @@color:yellow;and cannot serve as your Schoolteacher any more.@@

		<<set $Schoolteacher to 0>>
	<<elseif $Schoolteacher.preg > 31 && $Schoolteacher.pregType is 50>>
		''__@@color:pink;$Schoolteacher.slaveName@@__'' spends so much time giving birth and laboring that @@color:yellow;she cannot effectively serve as your Schoolteacher any longer@@.
		<<set $Schoolteacher to 0>>
	<<elseif $Schoolteacher.fetish is "mindbroken">>
		''__@@color:pink;$Schoolteacher.slaveName@@__'' is mindbroken @@color:yellow;and cannot serve as your Schoolteacher any more.@@

		<<set $Schoolteacher to 0>>
	<<elseif canSee($Schoolteacher) != true>>
		''__@@color:pink;$Schoolteacher.slaveName@@__'' can no longer see @@color:yellow;and cannot serve as your Schoolteacher any more.@@

		<<set $Schoolteacher to 0>>
	<</if>>
	<<if $Schoolteacher == 0>>
		<<set $slaves[_i].assignment to "rest", $slaves[_i].assignmentVisible to 1>>
	<</if>>
<<case "be the Wardeness">>
	<<set $Wardeness to $slaves[_i]>>
	<<if canWalk($Wardeness) != true>>
		''__@@color:pink;$Wardeness.slaveName@@__'' is no longer independently mobile @@color:yellow;and cannot serve as your Wardeness any more.@@

		<<set $Wardeness to 0>>
	<<elseif $Wardeness.preg > 31 && $Wardeness.pregType is 50>>
		''__@@color:pink;$Wardeness.slaveName@@__'' spends so much time giving birth and laboring that @@color:yellow;she cannot effectively serve as your Wardeness any longer@@.
		<<set $Wardeness to 0>>
	<<elseif canSee($Wardeness) != true>>
		''__@@color:pink;$Wardeness.slaveName@@__'' can no longer see @@color:yellow;and cannot serve as your Wardeness any more.@@

		<<set $Wardeness to 0>>
	<</if>>
	<<if $Wardeness == 0>>
		<<set $slaves[_i].assignment to "rest", $slaves[_i].assignmentVisible to 1>>
	<</if>>
<<case "be the Attendant">>
	<<set $Attendant to $slaves[_i]>>
	<<if $Attendant.fetish is "mindbroken">>
		''__@@color:pink;$Attendant.slaveName@@__'' is mindbroken @@color:yellow;and cannot serve as your Attendant any more.@@

		<<set $Attendant to 0>>
	<<elseif $Attendant.preg > 31 && $Attendant.pregType is 50>>
		''__@@color:pink;$Attendant.slaveName@@__'' spends so much time giving birth and laboring that @@color:yellow;she cannot effectively serve as your Attendant any longer@@.
		<<set $Attendant to 0>>
	<<elseif canWalk($Attendant) != true>>
		''__@@color:pink;$Attendant.slaveName@@__'' is no longer independently mobile @@color:yellow;and cannot serve as your Attendant any more.@@

		<<set $Attendant to 0>>
	<</if>>
	<<if $Attendant == 0>>
		<<set $slaves[_i].assignment to "rest", $slaves[_i].assignmentVisible to 1>>
	<</if>>
<<case "be the Nurse">>
	<<set $Nurse to $slaves[_i]>>
	<<if $Nurse.fetish is "mindbroken">>
		''__@@color:pink;$Nurse.slaveName@@__'' is mindbroken @@color:yellow;and cannot serve as your Nurse any more.@@

		<<set $Nurse to 0>>
	<<elseif $Nurse.preg > 31 && $Nurse.pregType is 50>>
		''__@@color:pink;$Nurse.slaveName@@__'' spends so much time giving birth and laboring that @@color:yellow;she cannot effectively serve as your Nurse any longer@@.
		<<set $Nurse to 0>>
	<<elseif canWalk($Nurse) != true>>
		''__@@color:pink;$Nurse.slaveName@@__'' is no longer independently mobile @@color:yellow;and cannot serve as your Nurse any more.@@

		<<set $Nurse to 0>>
	<<elseif canSee($Nurse) != true>>
		''__@@color:pink;$Nurse.slaveName@@__'' can no longer see @@color:yellow;and cannot serve as your Nurse any more.@@

		<<set $Nurse to 0>>
	<</if>>
	<<if $Nurse == 0>>
		<<set $slaves[_i].assignment to "rest", $slaves[_i].assignmentVisible to 1>>
	<</if>>
<<case "guard you">>
	<<set $Bodyguard to $slaves[_i]>>
	<<if canWalk($Bodyguard) != true>>
		''__@@color:pink;$Bodyguard.slaveName@@__'' is no longer independently mobile @@color:yellow;and cannot serve as your bodyguard any more.@@

		<<set $Bodyguard to 0>>
	<<elseif $Bodyguard.preg > 31 && $Bodyguard.pregType is 50>>
		''__@@color:pink;$Bodyguard.slaveName@@__'' spends so much time giving birth and laboring that @@color:yellow;she cannot effectively serve as your bodyguard any longer@@.
		<<set $Bodyguard to 0>>
	<<elseif canSee($Bodyguard) != true>>
		''__@@color:pink;$Bodyguard.slaveName@@__'' can no longer see @@color:yellow;and cannot serve as your Bodyguard any more.@@

		<<set $Bodyguard to 0>>
	<</if>>
	<<if $Bodyguard == 0>>
		<<set $slaves[_i].assignment to "rest", $slaves[_i].assignmentVisible to 1>>
	<</if>>
<<case "be your Concubine">>
	<<set $Concubine to $slaves[_i], $fuckSlaves++>>
<<case "serve in the master suite" "please you">>
	<<set $fuckSlaves++>>
<</switch>>

<<if $Lurcher>>
	<<if $slaves[_i].ID is $Lurcher.ID>>
		<<set $Lurcher to $slaves[_i]>>
		<<if canWalk($Lurcher) != true>>
			''__@@color:pink;$Lurcher.slaveName@@__'' is no longer able to run @@color:yellow;and cannot course as a lurcher.@@

			<<set $Lurcher to 0>>
		<<elseif $Lurcher.preg > 31 && $Lurcher.pregType >= 10>>
			''__@@color:pink;$Lurcher.slaveName@@__'' is too pregnant to run @@color:yellow;and cannot course as a lurcher.@@
			<<set $Lurcher to 0>>
		<</if>>
	<</if>>
<</if>>

<<if $fighterIDs.contains($slaves[_i])>>
	<<if canWalk($slaves[_i]) != true>>
		''__@@color:pink;$slaves[_i].slaveName@@__'' is no longer independently mobile @@color:yellow;and cannot fight any more.@@ She has been removed from $pitName roster
.
		<<for _k to 0; _k < $fighterIDs.length; _k++>>
		<<if $slaves[_i].ID == $fighterIDs[_k]>>
			<<set $dump to $fighterIDs.pluck([_k],[_k])>>
			<<set _k-->>
		<</if>>
		<</for>>
	<</if>>
<</if>>

<<if $slaves[_i].origin>>
<<set $toSearch to $slaves[_i].origin>>
<<if $toSearch.indexOf("Slave Shelter") != -1>>
	<<set $shelterGirlsIDs.push($slaves[_i].ID)>>
<</if>>
<</if>>

<<if $slaves[_i].bellyPain != 0>>
	<<set $slaves[_i].bellyPain = 0>>
<</if>>
<<if $slaves[_i].preg > 0>>
	<<set $slaves[_i].preg++>>
<</if>>
<<if ($slaves[_i].scars == 3)>>
	<<set $slaves[_i].scarheal += 1>>
<</if>>

<</for>>
<<if $averageDick > 0>><<set $averageDick to $averageDick/$slavesWithWorkingDicks>><</if>>
<<set $freeSexualEnergy = $PC.sexualEnergy-$fuckSlaves>>
<<if $freeSexualEnergy > 0>>
<<if $freeSexualEnergy > $slavesVisible/2>>
	<<set $freeSexualEnergy = 3>>
<<elseif $freeSexualEnergy > $slavesVisible/4>>
	<<set $freeSexualEnergy = 2>>
<<else>>
	<<set $freeSexualEnergy = 1>>
<</if>>
<</if>>

<<if ($brothel > 0)>>
	<<display "Brothel Report">>
<</if>>
<<if ($club > 0)>>
	<<display "Club Report">>
<</if>>
<<if ($arcade > 0)>>
	<<display "Arcade Report">>
<</if>>
<<if ($dairy > 0)>>
	<<display "Dairy Report">>
<</if>>
<<if ($servantsQuarters > 0)>>
	<<display "Servants' Quarters Report">>
<</if>>
<<if ($schoolroom > 0)>>
	<<display "Schoolroom Report">>
<</if>>
<<if ($spa > 0)>>
	<<display "Spa Report">>
<</if>>
<<if ($clinic > 0)>>
	<<display "Clinic Report">>
<</if>>
<<if ($cellblock > 0)>>
	<<display "Cellblock Report">>
<</if>>
<<if ($incubator > 0)>>
	<<display "Incubator Report">>
<</if>>
<<if ($masterSuite > 0)>>
	<<display "Master Suite Report">>
<</if>>

<<if $slavesVisible > 0>>
__''Penthouse Report''__

<<for $i to 0; $i < $slaves.length; $i++>>
<<if $slaves[$i].assignmentVisible == 1>>
	<<if $slaves[$i].assignment is "be your Head Girl">>
		<<display "Full Report">>
		<<set _iTemp to $i>>
		<<for $i to 0; $i < $slaves.length; $i++>>
			<<if $slaves[$i].assignment is "live with your Head Girl">>
			<<set $HGRelease to 1>>

<<display "SA live with HG">>
			<<break>>
			<</if>>
		<</for>>
		<<set $i to _iTemp>>
	<<else>>
		<<display "Full Report">>
	<</if>>
	<<if ($rulesAssistantAuto == 1)>>
		<<if ($slaves[$i].useRulesAssistant == 1)>>
			<<set _rulesapplied to false>>
			<<for _r to 0; _r < $defaultRules.length; _r++>>
				<<if ($slaves[$i].assignmentVisible == 1) || ruleAppliedToSlaveFacility($defaultRules[_r], $slaves[$i])>>
					<<set _rulesapplied to true>>
					<<break>>
				<</if>>
			<</for>>
			<<if (_rulesapplied == true)>>
				<<set $activeSlave to $slaves[$i]>>
				<<display "Check Auto Rules Activate">>
				<<display "Default Rules">>
				<<set $slaves[$i] to $activeSlave>>
			<</if>>
		<</if>>
	<</if>>

<<else>>
	<<if ($rulesAssistantAuto == 1)>>
		<<if ($slaves[$i].useRulesAssistant == 1)>>
			<<set _rulesapplied to false>>
			<<for _r to 0; _r < $defaultRules.length; _r++>>
				<<if ($slaves[$i].assignmentVisible == 1) || ruleAppliedToSlaveFacility($defaultRules[_r], $slaves[$i])>>
					<<set _rulesapplied to true>>
					<<break>>
				<</if>>
			<</for>>
			<<if (_rulesapplied == true)>>
				<<set $activeSlave to $slaves[$i]>>
				<<display "Check Auto Rules Activate">>
				<<display "Default Rules">>
				<<set $slaves[$i] to $activeSlave>>
			<</if>>
		<</if>>
	<</if>>
<</if>>
<</for>>
<</if>>