code:
:: Costs Budget [nobr]

<<set $nextButton = "Back to Main", $nextLink = "Main", _archologyCosts = 0>>

<<if def $lastWeeksCashIncome>>
	<<set $lastWeeksCashIncome.Total = 0>>
	<<set $lastWeeksCashExpenses.Total = 0>>
	<<set $lastWeeksCashProfits.Total = 0>>
<</if>>

//Here you can view many of the financial details of your arcology, <<= properTitle()>>. The detailed list of slaves and their costs (food, hormones) that you may remember can now be found in the "Slave maintenance" link. Other links will allow you to directly control areas of your arcology to adjust spending to suit your tastes.//

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

<<if $difficultySwitch == 1>>
	//The Local Economy score effects some prices in your ecology. The lower the score, the higher the prices. The base score is ''100''.//

		@@.yellowgreen;Global Economy@@
	| <<print $economy>>

	<<if ($cheatMode) && ($cheatModeM)>>
		<<set _Teconomy = $economy>>
		<<textbox "_Teconomy" _Teconomy>>
		<<link "Apply">>
		<<set $economy = Math.trunc(Number(_Teconomy)) || $economy, $cheater = 1>>
		<<replace "#economy">>
		@@.yellowgreen;Global Economy@@
		| <<print $economy>>
		<</replace>>
		<</link>>
	<</if>>

		@@.yellowgreen;Local Economy@@
	| <<print $localEcon>>

	<<if ($cheatMode) && ($cheatModeM)>>
		<<set _TlocalEcon = $localEcon>>
		<<textbox "_TlocalEcon" _TlocalEcon>>
		<<link "Apply">>
		<<set $localEcon = Math.trunc(Number(_TlocalEcon)) || $localEcon, $cheater = 1>>
		<<replace "#localEcon">>
		@@.yellowgreen;Local Economy@@
		| <<print $localEcon>>
		<</replace>>
		<</link>>
	<</if>>

 The current score is
	<<if $localEcon > 100>>
		<<set _econPercent = Math.trunc(1000-100000/$localEcon)/10>>
		reducing prices by @@.green;''<<print _econPercent>>%.''@@
	<<elseif $localEcon == 100>>
		equal to the base score. There are no price modifications.
	<<else>>
		<<set _econPercent = Math.trunc(100000/$localEcon-1000)/10>>
		increasing prices by @@.red;''<<print _econPercent>>%.''@@
	<</if>>

<<if $lineSeparations == 0>>

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

//Your weekly costs are as follows://

/* Table of Totals */
<<if ndef $lastWeeksCashIncome>>
	Financial data currently unavailable.
<<else>>

<>

Penthouse

		Income
		Expense
		Totals

	<<print budgetLine("whore", "Whores")>>

	<<print budgetLine("rest", "Resting")>>

	<<print budgetLine("houseServant", "House servants")>>

	<<print budgetLine("confined", "Confined")>>

	<<print budgetLine("publicServant", "Public servants")>>

	<<print budgetLine("classes", "Classes")>>

	<<print budgetLine("milked", "Milked")>>

	<<print budgetLine("gloryhole", "Gloryhole")>>

Structures

	<<print budgetLine("brothel", "[[$brothelNameCaps|Brothel][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($brothelSlaves slaves)")>>

	<<print budgetLine("whoreBrothel", "Brothel whores")>>

	<<print budgetLine("brothelAds", "[[Brothel ads|Brothel Advertisement][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] also increase the income of whoring slaves in \"jobs.\"")>>

	<<if $brothel > 0>>

	<</if>>

	<<print budgetLine("club", "[[$clubNameCaps|Club][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($clubSlaves slaves)")>>

	<<print budgetLine("clubAds", "[[Club ads|Club Advertisement][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]]")>>

	<<if $club > 0>>

	<</if>>

	<<print budgetLine("arcade", "[[$arcadeNameCaps|Arcade][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($arcadeSlaves slaves)")>>

	<<print budgetLine("gloryholeArcade", "Arcade slaves")>>

	<<if $arcade > 0>>

	<</if>>

	<<print budgetLine("dairy", "[[$dairyNameCaps|Dairy][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($dairySlaves slaves)")>>

	<<print budgetLine("milkedDairy", "Dairy cows")>>

	<<if $dairy > 0>>

	<</if>>

	<<print budgetLine("servantsQuarters", "[[Servants' Quarters][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($servantsQuartersSlaves slaves)")>>

	<<print budgetLine("masterSuite", "[[Master Suite][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($masterSuiteSlaves slaves)")>>

	<<print budgetLine("school", "[[$schoolroomNameCaps|Schoolroom][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($schoolroomSlaves slaves)")>>

	<<print budgetLine("spa", "[[$spaNameCaps|Spa][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($spaSlaves slaves)")>>

	<<print budgetLine("clinic", "[[$clinicNameCaps|Clinic][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($clinicSlaves slaves)")>>

	<<print budgetLine("cellblock", "[[$cellblockNameCaps|Cellblock][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($cellblockSlaves slaves)")>>

	<<print budgetLine("lab", "[[Research Lab][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] maintenance")>>

	<<print budgetLine("incubator", "[[$incubatorNameCaps|Incubator][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($incubatorSlaves slaves)")>>

	<<print budgetLine("nursery", "[[$nurseryNameCaps|Nursery][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($nurserySlaves slaves)")>>

	<<print budgetLine("farmyard", "[[$farmyardNameCaps|Farmyard][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($farmyardSlaves slaves)")>>

	<<print budgetLine("pit", "[[$pitNameCaps|Pit][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($fighterIDs.length slaves)")>>

	<<print budgetLine("environment", "Environment")>>

	<<print budgetLine("weather",
				"<<if $lastWeeksCashExpenses.weather < 0 && $weatherCladding == 0>>
					Weather is causing @@.red;expensive damage.@@ Consider a protective [[upgrade|Manage Arcology][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]].
				<<else>>
					Weather
				<</if>>")>>

Slaves

	<<print budgetLine("slaveUpkeep", "[[Slave maintenance|Costs Report Slaves][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] ($slaves.length slaves)")>>

	<<print budgetLine("extraMilk", "Extra milk")>>

	<<print budgetLine("slaveTransfer", "Selling/buying major slaves")>>

	<<print budgetLine("menialTransfer", "Menials: [[Assistant's|Personal assistant options][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] flipping")>>

	<<print budgetLine("fuckdollsTransfer", "Fuckdolls: [[Assistant's|Personal assistant options][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] flipping")>>

	<<print budgetLine("menialBioreactorsTransfer", "Bioreactors: [[Assistant's|Personal assistant options][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] flipping")>>

	<<print budgetLine("babyTransfer", "Selling/buying babies")>>

	<<print budgetLine("menialTrades", "Menials: labor")>>

	<<print budgetLine("fuckdolls", "Fuckdolls")>>

	<<print budgetLine("menialBioreactors", "Menials: bioreactors")>>

	<<print budgetLine("porn", "Porn")>>

	<<print budgetLine("recruiter", "Recruiter")>>

	<<print budgetLine("menialRetirement", "Menials retiring")>>

	<<print budgetLine("slaveMod", "Slave modification")>>

	<<print budgetLine("slaveSurgery", "Slave surgery")>>

	<<print budgetLine("birth", "Slave surgery")>>

Finance

	<<print budgetLine("personalBusiness", "Personal business")>>

	<<print budgetLine("personalLivingExpenses",
		"<<if $girls == 3>>
			Since you are accustomed to luxury, your personal living expenses are:
		<<elseif $girls == 2>>
			Since you are used to living well, your personal living expenses are:
		<<else>>
			Since you are used to a fairly normal life, your personal living expenses are:
		<</if>>")>>

	<<print budgetLine("PCtraining", "
				<<if ($personalAttention == \"trading\")>>
					[[Trading trainer|Personal Attention Select][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] fees
				<<elseif ($personalAttention == \"warfare\")>>
					[[Warfare trainer|Personal Attention Select][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] fees
				<<elseif ($personalAttention == \"slaving\")>>
					[[Slaving trainer|Personal Attention Select][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] fees
				<<elseif ($personalAttention == \"engineering\")>>
					[[Engineering trainer|Personal Attention Select][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] fees
				<<elseif ($personalAttention == \"medicine\")>>
					[[Medicine trainer|Personal Attention Select][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] fees
				<</if>>
			")>>

	<<print budgetLine("PCmedical", "Your medical expenses")>>

	<<print budgetLine("PCskills", "Your skills")>>

	<<print budgetLine("rents",
			"Your rents
			<<if $lastWeeksCashExpenses.rents < 0>>
				and bribes
			<</if>>
		")>>

	<<print budgetLine("stocks", "Stock dividends on ($personalShares/<<print ($publicShares + $personalShares)>> shares).")>>

	<<print budgetLine("stocksTraded", "Stock trading")>>

	<<print budgetLine("fines", "Fines")>>

	<<print budgetLine("event", "Events")>>

	<<print budgetLine("war", "Arcology conflict")>>

	<<print budgetLine("capEx", "Capital expenses")>>

	<<print budgetLine("cheating", "CHEATING")>>

Policies

	<<print budgetLine("policies", "[[Policies|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] and [[Edicts|edicts][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]]")>>

	<<print budgetLine("futureSocieties", "[[Society shaping|Future Society][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]]")>>

	<<print budgetLine("schoolBacking",
				"<<if $TSS.subsidize != 0>>[[The Slavegirl School|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] branch campus influence
				<<elseif $GRI.subsidize != 0>>[[Growth Research Institute|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] subsidiary lab influence
				<<elseif $SCP.subsidize != 0>>[[St. Claver Preparatory|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] branch campus influence
				<<elseif $LDE.subsidize != 0>>[[L'Encole des Enculees|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] branch campus influence
				<<elseif $TGA.subsidize != 0>>[[The Gymnasium-Academy|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] branch campus influence
				<<elseif $TCR.subsidize != 0>>[[The Cattle Ranch|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] branch campus influence
				<<elseif $HA.subsidize != 0>>[[Hippolyta Academy|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] branch campus influence
				<<elseif $TFS.subsidize != 0>>[[The Futanari Sisters|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] community influence
				<<elseif $TSS.schoolPresent == 1>>[[The Slavegirl School|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] branch campus upkeep
				<<elseif $GRI.schoolPresent == 1>>[[Growth Research Institute|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] subsidiary lab upkeep
				<<elseif $SCP.schoolPresent == 1>>[[St. Claver Preparatory|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] branch campus upkeep
				<<elseif $LDE.schoolPresent == 1>>[[L'Encole des Enculees|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] branch campus upkeep
				<<elseif $TGA.schoolPresent == 1>>[[The Gymnasium-Academy|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] branch campus upkeep
				<<elseif $TCR.schoolPresent == 1>>[[The Cattle Ranch|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] branch campus upkeep
				<<elseif $HA.schoolPresent == 1>>[[Hippolyta Academy|Policies][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]] branch campus upkeep
				<<else>> Unknown school expense
				<</if>>
			")>>

	<<print budgetLine("citizenOrphanage", "Education of $citizenOrphanageTotal of your slaves\' children in citizen schools")>>

	<<print budgetLine("privateOrphanage", "Private tutelage of $privateOrphanageTotal of your slaves\' children")>>

	<<print budgetLine("mercenaries",
			"Security: <<if $barracks>>[[$mercenariesTitle|Barracks][$nextButton = \"Back to Budget\", $nextLink = \"Costs Budget\"]]
			<<else>>Mercenaries
//@@.red;Cost increased by the lack of an armory to house them.@@//<</if>>
			<<if ($PC.warfare >= 100) || ($PC.career == \"arcology owner\")>>
//Cost reduced by your @@.springgreen;mercenary contacts.@@//<</if>>
		")>>

	<<print budgetLine("securityExpansion", "Security expansion")>>

	<<print budgetLine("specialForces", "Special forces")>>

	<<print budgetLine("undermining", "Undermine political support for the nearby old world peacekeeping mission.")>>

		Tracked totals

			<<set $lastWeeksCashIncome.Total = hashSum($lastWeeksCashIncome)>>
			<<if $lastWeeksCashIncome.Total > 0>>
				@@.yellowgreen;+<<print cashFormat(Math.trunc($lastWeeksCashIncome.Total))>>@@
			<<else>>
				@@.red;-<<print cashFormat(Math.abs(Math.trunc($lastWeeksCashIncome.Total)))>>@@
			<</if>>

			<<set $lastWeeksCashExpenses.Total = hashSum($lastWeeksCashExpenses)>>
			<<if $lastWeeksCashExpenses.Total > 0>>
				@@.yellowgreen;+<<print cashFormat(Math.trunc($lastWeeksCashExpenses.Total))>>@@
			<<else>>
				@@.red;-<<print cashFormat(Math.abs(Math.trunc($lastWeeksCashExpenses.Total)))>>@@
			<</if>>

			<<set $lastWeeksCashProfits.Total = ($lastWeeksCashIncome.Total + $lastWeeksCashExpenses.Total)>>
			/* each "profit" item is calculated on this sheet, and there's two ways to generate a profit total: the difference of the income and expense totals, and adding all the profit items. If they aren't the same, I probably forgot to properly add an item's profit calculation to this sheet.*/
			<<if $lastWeeksCashProfits.Total != hashSum($lastWeeksCashProfits) - $lastWeeksCashProfits.Total>>/* Profits includes the total number of profits, so we have to subtract it back out */
				<<print (cashFormat(Math.trunc(hashSum($lastWeeksCashProfits)-$lastWeeksCashProfits.Total)))>>

				@@.red;Fix profit calc
@@
			<</if>>
			<<if $lastWeeksCashProfits.Total > 0>>
				@@.yellowgreen;+<<print cashFormat(Math.trunc($lastWeeksCashProfits.Total))>>@@
			<<else>>
				@@.red;-<<print cashFormat(Math.abs(Math.trunc($lastWeeksCashProfits.Total)))>>@@
			<</if>>

		Expenses budget for week <<print ($week+1)>>

		<<if $costs < 0>>
				@@.yellowgreen;+<<print cashFormat($costs)>>@@
			<<else>>
				@@.red;<<print cashFormat($costs)>>@@
			<</if>>

		Last week actuals

		<<if ($cash-$cashLastWeek) > 0>>
				@@.yellowgreen;+<<print cashFormat($cash-$cashLastWeek)>>@@
			<<else>>
				@@.red;<<print cashFormat($cash-$cashLastWeek)>>@@
			<</if>>

	<<if ($cash-$cashLastWeek) == $lastWeeksCashProfits.Total>>

			@@.green;The books are balanced, <<= properTitle()>>!@@

	<<else>>

			Transaction tracking off by:

			/*<<print ($lastWeeksCashExpenses.Total + $costs)>>*/
			<<if (($cash-$cashLastWeek) - $lastWeeksCashProfits.Total) > 0>>
					@@.yellowgreen;+<<print cashFormat(($cash-$cashLastWeek) - $lastWeeksCashProfits.Total)>>@@
				<<elseif (($cash-$cashLastWeek) - $lastWeeksCashProfits.Total) == 0>>
					<<print cashFormat((($cash-$cashLastWeek) - $lastWeeksCashProfits.Total))>>
				<<else>>
					@@.red;-<<print cashFormat(Math.abs(($cash-$cashLastWeek) - $lastWeeksCashProfits.Total))>>@@
				<</if>>

	<</if>>

<</if>>

<<if ndef $lastWeeksCashErrors>>
	<<set $lastWeeksCashErrors = "Errors: ">>
<</if>>

<<if $lastWeeksCashErrors !== "Errors: ">>
	<<link "Reset">>
		<<set $lastWeeksCashErrors = "Errors: ">>
	<</link>>
	@@.red;<<print $lastWeeksCashErrors>>@@
<</if>>


code:
:: Costs Report [nobr]

<<set $nextButton = "Back to Main", $nextLink = "Main",_arcologyCosts = 0>>
<<set _arcologyCosts = 0>>
<<if $PCSlutContacts == 0>><<set $PCSlutContacts = 1>><</if>>
/*
//Your weekly costs are as follows.//

Since you are
<<if $girls >= 3>>
	accustomed to luxury,
<<elseif $girls == 2>>
	used to living well,
<<else>>
	used to a fairly normal life,
<</if>>
your personal living expenses are @@.yellowgreen;<<print cashFormat(Math.trunc($girls*(250+(50000/$localEcon))))>>.@@
<<set _arcologyCosts += Math.trunc($girls*(250+(50000/$localEcon)))>>

<<if $arcologies[0].FSRepopulationFocusLaw == 1 && $PC.pregKnown == 1>>

Rent promotion for being a pregnant citizen under ''Universal Pregnancy Subsidy:'' @@.yellowgreen;<<print cashFormat(500)>>@@
	<<set _arcologyCosts += 500>>
<</if>>

<<if $PC.preg == -1>>

Your contraceptives expenses: @@.yellowgreen;<<print cashFormat(25)>>@@
	<<set _arcologyCosts += 25>>
<<elseif $PC.fertDrugs == 1>>

Your fertility regimen: @@.yellowgreen;<<print cashFormat(50)>>@@
	<<set _arcologyCosts += 50>>
<<elseif $PC.preg >= 16>>

Increased living expenses due to being pregnant: @@.yellowgreen;<<print cashFormat(100)>>@@
	<<set _arcologyCosts += 100>>
<</if>>
<<if $PC.staminaPills == 1>>

Your stamina pills: @@.yellowgreen;<<print cashFormat(50)>>@@
	<<set _arcologyCosts += 50>>
<</if>>

<<if $PC.actualAge >= $IsInPrimePC && $PC.actualAge < $IsPastPrimePC>>
	<<if ($personalAttention == "trading") || ($personalAttention == "warfare") || ($personalAttention == "slaving") || ($personalAttention == "engineering") || ($personalAttention == "medicine") || ($personalAttention == "hacking")>>

		<<set _cost = 10000*$AgeEffectOnTrainerPricingPC,_arcologyCosts += _cost>>
		<<switch $personalAttention>>
			<<case trading>>
				__Trading__
			<<case warfare>>
				__Warfare__
			<<case slaving>>
				__Slaving__
			<<case engineering>>
				__Engineering__
			<<case medicine>>
				__Medicine__
			<<case hacking>>
				__Hacking__
		<</switch>>
		Trainer Fees: @@.yellowgreen;<<print cashFormat(_cost)>>@@
	<</if>>
<</if>>

<<if $breederOrphanageTotal > 0>><<set _breederTuition = 50>><<else>><<set _breederTuition = 0>><</if>>
<<if $citizenOrphanageTotal+$privateOrphanageTotal+$breederOrphanageTotal > 0>>

 __Orphanage__ fee: @@.yellowgreen;<<print cashFormat($citizenOrphanageTotal*100+$privateOrphanageTotal*500+_breederTuition)>>@@
	<<set _arcologyCosts += $citizenOrphanageTotal*100+$privateOrphanageTotal*500+_breederTuition>>
	<<if $citizenOrphanageTotal > 0>>

    Citizen: @@.yellowgreen;<<print cashFormat(100)>>@@ per child. Currently <<print num($citizenOrphanageTotal)>> are being taught, bringing the total to @@.yellowgreen;<<print cashFormat($citizenOrphanageTotal*100)>>.@@
	<</if>>
	<<if $privateOrphanageTotal > 0>>

    Private: @@.yellowgreen;<<print cashFormat(500)>>@@ per child. Currently <<print num($privateOrphanageTotal)>> are being taught, bringing the total to @@.yellowgreen;<<print cashFormat($privateOrphanageTotal*500)>>.@@
	<</if>>
	<<if $breederOrphanageTotal > 0>>

    Since <<print num($breederOrphanageTotal)>> of your slaves' children are being raised into productive members of society in a society funded school, you pay a flat @@.yellowgreen;<<print cashFormat(50)>>@@ usage fee.
	<</if>>
<</if>>

<<if $peacekeepers != 0 && $peacekeepers.undermining != 0>>

 <<print cashFormat($peacekeepers.undermining)>> to undermine political support for the nearby old world peacekeeping mission.
	<<set _arcologyCosts += $peacekeepers.undermining>>
<</if>>

<<if $SF.Toggle && $SF.Active >= 1 && def $SF.Subsidy>> <<= Count()>>

__Financially supporting $SF.Lower until self sufficiency:__ <<print cashFormat(Math.ceil(_SFSubsidy))>>
	<<set _arcologyCosts += Math.ceil(_SFSubsidy)>>
<</if>>
<<if $mercenaries > 0>>
	<<set _mercCosts = $mercenaries*2000>>
	<<if $barracks>><<set _mercCosts *= 0.5>><</if>>
	<<if ($PC.warfare >= 100) || ($PC.career == "arcology owner")>><<set _mercCosts *= 0.5>><</if>>

__Mercenary Expenses__: @@.yellowgreen;<<print cashFormat(_mercCosts)>>@@
	<<if $barracks>><<else>>//@@.red;Increased by the lack of a barracks.@@//<</if>>
	<<if ($PC.warfare >= 100) || ($PC.career == "arcology owner")>>//Reduced by your @@.springgreen;mercenary contacts.@@//<</if>>
	<<set _arcologyCosts += _mercCosts>>
<</if>>

<<if $citizenRetirementMenials == 1>>

__Menial Slave Retirement Premiums__:
	<<if $CitizenRetirement == 1>>
		<<set _citizenRetirementMenialsCost = $menials * 2>>
	<<else>>
		<<set _citizenRetirementMenialsCost = ($menials + $slaves.length) * 2>>
	<</if>>
	<<set _arcologyCosts += _citizenRetirementMenialsCost>>
	@@.yellowgreen;<<print cashFormat(_citizenRetirementMenialsCost)>>@@
<</if>>

<<if $rations > 0>>
	<<set _rationsPrice = ($rations*1000)>> /* this number may need tweaking *//*

__Rations__:
	@@.yellowgreen;<<print cashFormat(_rationsPrice)>>@@
<</if>>

<<if $brothel > 0 || $club > 0 || $arcade > 0 || $dairy > 0 || $farmyard > 0>>

__Arcology Building Maintenance__:
	<<if $brothel > 0>>
	<<set _advertising = 0>>
	<<if $brothel > 0>>
		<<set _advertising = $brothelAdsSpending>>
	<</if>>

	Brothel: @@.yellowgreen;<<print cashFormat(($brothel*$facilityCost)+(0.1*$brothelUpgradeDrugs*$brothel*$facilityCost)+_advertising)>>@@
	<<set _arcologyCosts += ($brothel*$facilityCost)+(0.1*$brothelUpgradeDrugs*$brothel*$facilityCost)+_advertising>>
<</if>>
	<<if $club > 0>>
		<<set _advertising= 0>>
		<<if $club > 0>>
			<<set _advertising = $clubAdsSpending>>
			<<set _arcologyCosts += $clubAdsSpending>>
		<</if>>

		Club: @@.yellowgreen;<<print cashFormat(($club*$facilityCost)+(0.2*$clubUpgradePDAs*$club*$facilityCost)+_advertising)>>@@
		<<set _arcologyCosts += ($club*$facilityCost)+(0.2*$clubUpgradePDAs*$club*$facilityCost)+_advertising>>
	<</if>>
	<<if $arcade > 0>>

		Arcade: @@.yellowgreen;<<print cashFormat((0.5*$arcade*$facilityCost)+(0.2*$arcadeUpgradeInjectors*$arcade*$facilityCost)+(0.2*$arcadeUpgradeCollectors*$arcade*$facilityCost))>>@@
		<<set _arcologyCosts += (0.5*$arcade*$facilityCost)+(0.2*$arcadeUpgradeInjectors*$arcade*$facilityCost)+(0.2*$arcadeUpgradeCollectors*$arcade*$facilityCost)>>
	<</if>>
	<<if $dairy > 0>>

		Dairy: @@.yellowgreen;<<print cashFormat(($dairy*$facilityCost)+(0.2*$dairyFeedersUpgrade*$dairy*$facilityCost)+(0.1*$dairyPregUpgrade*$dairy*$facilityCost))>>@@
		<<set _arcologyCosts += ($dairy*$facilityCost)+(0.2*$dairyFeedersUpgrade*$dairy*$facilityCost)+(0.1*$dairyPregUpgrade*$dairy*$facilityCost)>>
		<<if $bioreactorsXY+$bioreactorsXX+$bioreactorsHerm+$bioreactorsBarren > 0>>

			Additional maintenance for milking machines upgraded with biological components: @@.yellowgreen;<<print cashFormat(($bioreactorsXY+$bioreactorsXX+$bioreactorsHerm+$bioreactorsBarren)*100)>>@@
			<<set _arcologyCosts += ($bioreactorsXY+$bioreactorsXX+$bioreactorsHerm+$bioreactorsBarren)*100>>
		<</if>>
	<</if>>
	<<if $farmyard > 0>> /*TODO: this will also need to be expanded */
		/*

		Farmyard: @@.yellowgreen;<<print cashFormat($farmyard*$facilityCost)>>@@
		<<set _arcologyCosts += $farmyard*$facilityCost>>
	<</if>>
<</if>>

<<if ($servantsQuarters > 0 && $servantsQuartersUpgradeMonitoring > 0) ||
$nursery > 0 || $masterSuiteUpgradePregnancy > 0 || $incubator > 0 ||
($cyberMod != 0 && $researchLab.built == "true")>>

__Penthouse Facility Maintenance__:
	<<if ($servantsQuarters > 0) && ($servantsQuartersUpgradeMonitoring > 0)>>

		Servants' Quarters: @@.yellowgreen;<<print cashFormat((0.2*$servantsQuartersUpgradeMonitoring*$servantsQuarters*$facilityCost))>>@@
		<<set _arcologyCosts += 0.2*$servantsQuartersUpgradeMonitoring*$servantsQuarters*$facilityCost>>
	<</if>>
	<<if $nursery > 0>> /*TODO: this will definitely need to be expanded to take into account the number of children and other factors */
		/*

		Nursery: @@.yellowgreen;<<print cashFormat($nursery*$facilityCost)>>@@
		<<set _arcologyCosts += $nursery*$facilityCost>>
	<</if>>
	<<if ($masterSuiteUpgradePregnancy > 0)>>

		Master Suite: @@.yellowgreen;<<print cashFormat(((500*$masterSuiteUpgradePregnancy) + (1000*$masterSuitePregnancyFertilitySupplements)))>>@@
		<<set _arcologyCosts += ((500*$masterSuiteUpgradePregnancy) + (1000*$masterSuitePregnancyFertilitySupplements))>>
	<</if>>
	<<if $incubator > 0>>

		Incubation Facility: @@.yellowgreen;<<print cashFormat((10*$incubator*$facilityCost)+(0.2*$incubatorUpgradeWeight*$incubator*$facilityCost)+(0.2*$incubatorUpgradeMuscles*$incubator*$facilityCost)+(0.2*$incubatorUpgradeReproduction*$incubator*$facilityCost)+(0.2*$incubatorUpgradeGrowthStims*$incubator*$facilityCost)+(0.5*$incubatorUpgradeSpeed*$incubator*$facilityCost))>>@@
		<<set _arcologyCosts += (10*$incubator*$facilityCost)+(0.2*$incubatorUpgradeWeight*$incubator*$facilityCost)+(0.2*$incubatorUpgradeMuscles*$incubator*$facilityCost)+(0.2*$incubatorUpgradeReproduction*$incubator*$facilityCost)+(0.2*$incubatorUpgradeGrowthStims*$incubator*$facilityCost)+(0.5*$incubatorUpgradeSpeed*$incubator*$facilityCost)>>
		<<if $incubatorWeightSetting+$incubatorMusclesSetting+$incubatorReproductionSetting > 0>>

    Additional monitoring and maintenance costs for growing children: @@.yellowgreen;<<print cashFormat((($incubatorWeightSetting+$incubatorMusclesSetting+$incubatorReproductionSetting+$incubatorGrowthStimsSetting)*500))>>@@
			<<set _arcologyCosts += (($incubatorWeightSetting+$incubatorMusclesSetting+$incubatorReproductionSetting+$incubatorGrowthStimsSetting)*500)>>
		<</if>>
	<</if>>
	<<if $cyberMod != 0 && $researchLab.built == "true">>

		Research Lab: @@.yellowgreen;<<print cashFormat((100*$researchLab.maxSpace))>>@@
		<<set _arcologyCosts += 100*$researchLab.maxSpace>>
		<<if $researchLab.hired != 0>>
    Scientists: @@.yellowgreen;<<print cashFormat((300*$researchLab.hired))>>@@
		<<set _arcologyCosts += 300*$researchLab.hired>> <</if>>
		<<if $researchLab.menials != 0>>
>    Menial Slaves: @@.yellowgreen;<<print cashFormat((100*$researchLab.menials))>>@@
		<<set _arcologyCosts += 100*$researchLab.menials>> <</if>>
	<</if>>
<</if>>

/* security expansion */
/*<<if $secExp > 0>>

	<<if $edictsUpkeep + $SFSupportUpkeep > 0>>
		__Edicts Upkeep__: @@.yellowgreen;<<print cashFormat($edictsUpkeep + $SFSupportUpkeep)>>@@
		<<set _arcologyCosts += ($edictsUpkeep + $SFSupportUpkeep)>>
	<</if>>
	<<if $propHub != 0 || $secHQ != 0 || $secBarracks != 0 || $riotCenter != 0>>

__Security Apparatus Maintenance Costs__:
		<<if $propHub != 0>>

			Propaganda Hub: @@.yellowgreen;<<print cashFormat($propHubUpkeep)>>@@
			<<set _arcologyCosts += $propHubUpkeep>>
		<</if>>
		<<if $secHQ != 0>>

			Security Headquarters: @@.yellowgreen;<<print cashFormat(($secHQUpkeep)+(20*$secMenials))>>@@
			<<set _arcologyCosts += ($secHQUpkeep)+(20*$secMenials)>>
		<</if>>
		<<if $secBarracks != 0>>

			Barracks: @@.yellowgreen;<<print cashFormat($secBarracksUpkeep)>>@@
			<<set _arcologyCosts += $secBarracksUpkeep>>
		<</if>>
		<<if $riotCenter != 0>>

			Riot Control Center: @@.yellowgreen;<<print cashFormat($riotUpkeep)>>@@
			<<set _arcologyCosts += $riotUpkeep>>
		<</if>>
	<</if>>

	<<if $soldierWages == 0>>
		<<set _soldierMod = 1>>
	<<elseif $soldierWages == 1>>
		<<set _soldierMod = 1.5>>
	<<else>>
		<<set _soldierMod = 2>>
	<</if>>
	<<set _milTotal = 0, _slaveTotal = 0, _mercTotal = 0, _numItems = 0>>
	<<if $militiaUnits.length > 0>>

__Militia Platoons Upkeep__:
		<<for _i = 0; _i < $militiaUnits.length; _i++>>

			 <<print ordinalSuffix($militiaUnits.length-[_i])>>: @@.yellowgreen;<<print cashFormat($militiaUnits[_i].troops*$soldierUpkeep * _soldierMod)>>@@
			<<set _milTotal += $militiaUnits[_i].troops*$soldierUpkeep * _soldierMod>>
			<<set _numItems += 1>>
		<</for>>

    ''Total: @@.yellowgreen;<<print cashFormat(_milTotal)>>@@''
	<</if>>
	<<if $slaveUnits.length > 0>>

__Slave Platoons Upkeep__:
		<<for _i = 0; _i < $slaveUnits.length; _i++>>

			 <<print ordinalSuffix($slaveUnits.length-[_i])>>: @@.yellowgreen;<<print cashFormat($slaveUnits[_i].troops*$soldierUpkeep * 0.5 * _soldierMod)>>@@
			<<set _slaveTotal += $slaveUnits[_i].troops*$soldierUpkeep * 0.5 * _soldierMod>>
		<</for>>

    ''Total: @@.yellowgreen;<<print cashFormat(_slaveTotal)>>@@''
	<</if>>
	<<if $mercUnits.length > 0>>

__Mercenary Platoons Upkeep__:
		<<for _i = 0; _i < $mercUnits.length; _i++>>

			 <<print ordinalSuffix($mercUnits.length-[_i])>>: @@.yellowgreen;<<print cashFormat($mercUnits[_i].troops*$soldierUpkeep * 1.5 * _soldierMod)>>@@
			<<set _mercTotal += $mercUnits[_i].troops*$soldierUpkeep * 1.5 * _soldierMod>>
		<</for>>

    ''Total: @@.yellowgreen;<<print cashFormat(_mercTotal)>>@@''
		<<if (_milTotal+_slaveTotal+_mercTotal) > 0>>

__Total Defense Force Upkeep__: @@.yellowgreen;<<print cashFormat(_milTotal+_slaveTotal+_mercTotal)>>@@
			<<set _arcologyCosts += (_milTotal+_slaveTotal+_mercTotal)>>
		<</if>>
	<</if>>
<</if>>

<<if $econWeatherDamage && $disasterResponse > 0>>
	<<set _DRUUpkeep = Math.trunc($disasterResponse * 200000 / $localEcon)>>

__Disaster Response Unit Expenses__: @@.yellowgreen;<<print cashFormat(_DRUUpkeep)>>@@
	<<set _arcologyCosts += _DRUUpkeep>>
<</if>>
<<if $antiWeatherFreeze > 0>>
	<<set _AWFUpkeep = Math.trunc($antiWeatherFreeze * 200000 / $localEcon)>>

__Passenger Upgrades Expenses__: @@.yellowgreen;<<print cashFormat(_AWFUpkeep)>>@@
	<<set _arcologyCosts += _AWFUpkeep>>
<</if>>
<<if $FSSpending != 0>>

__Society Shaping Expenses__: @@.yellowgreen;<<print cashFormat($FSSpending)>>@@
	<<set _arcologyCosts += $FSSpending>>
<</if>>
<<if $Recruiter != 0>>

__Recruiting Expenses__: @@.yellowgreen;<<print cashFormat(250)>>@@
	<<set _arcologyCosts += 250>>
<</if>>

<<set _schoolPresent = 0, _schoolSubsidy = 0>>
<<if ($TSS.schoolPresent > 0)>>
	<<set _school = "The Slavegirl School">>
	<<set _schoolPresent = 1>>
	<<if $TSS.subsidize != 0>>
		<<set _schoolSubsidy = 1>>
	<</if>>
<</if>>
<<if ($GRI.schoolPresent > 0)>>
	<<set _school = "Growth Research Institute">>
	<<set _schoolPresent = 1>>
	<<if $GRI.subsidize != 0>>
		<<set _schoolSubsidy = 1>>
	<</if>>
<</if>>
<<if ($SCP.schoolPresent > 0)>>
	<<set _school = "St. Claver Prepatory">>
	<<set _schoolPresent = 1>>
	<<if $SCP.subsidize != 0>>
		<<set _schoolSubsidy = 1>>
	<</if>>
<</if>>
<<if ($LDE.schoolPresent > 0)>>
	<<set _school = "L'École des Enculées">>
	<<set _schoolPresent = 1>>
	<<if $LDE.subsidize != 0>>
		<<set _schoolSubsidy = 1>>
	<</if>>
<</if>>
<<if ($TGA.schoolPresent > 0)>>
	<<set _school = "The Gymnasium-Academy">>
	<<set _schoolPresent = 1>>
	<<if $TGA.subsidize != 0>>
		<<set _schoolSubsidy = 1>>
	<</if>>
<</if>>
<<if ($HA.schoolPresent > 0)>>
	<<set _school = "The Hippolyta Academy">>
	<<set _schoolPresent = 1>>
	<<if $HA.subsidize != 0>>
		<<set _schoolSubsidy = 1>>
	<</if>>
<</if>>
<<if ($TCR.schoolPresent > 0)>>
	<<set _school = "The Cattle Ranch">>
	<<set _schoolPresent = 1>>
	<<if $TCR.subsidize != 0>>
		<<set _schoolSubsidy = 1>>
	<</if>>
<</if>>
<<if ($TFS.schoolPresent > 0)>>
	<<set _school = "The Futanari Sisters">>
	<<set _schoolPresent = 1>>
	<<if $TFS.subsidize != 0>>
		<<set _schoolSubsidy = 1>>
	<</if>>
<</if>>

<<if _schoolPresent > 0>>
<<if _school == "Growth Research Institute">>

	__<<print _school>> Subsidiary Lab Upkeep__: @@.yellowgreen;<<print cashFormat(1000)>>@@
	<<set _arcologyCosts += 1000>>
	<<if _schoolSubsidy > 0>>

		__<<print _school>> Subsidiary Lab Influence__: @@.yellowgreen;<<print cashFormat(1000)>>@@
	<</if>>
<<elseif _school == "The Cattle Ranch">>

	__<<print _school>> Local Pasture Upkeep__: @@.yellowgreen;<<print cashFormat(1000)>>@@
	<<set _arcologyCosts += 1000>>
	<<if _schoolSubsidy > 0>>

		__<<print _school>> Local Pasture Influence__: @@.yellowgreen;<<print cashFormat(1000)>>@@
	<</if>>
<<elseif _school == "The Futanari Sisters">>

	__<<print _school>> Community Upkeep__: @@.yellowgreen;<<print cashFormat(1000)>>@@
	<<set _arcologyCosts += 1000>>
	<<if _schoolSubsidy > 0>>

		__<<print _school>> Community Influence__: @@.yellowgreen;<<print cashFormat(1000)>>@@
	<</if>>
<<else>>

	__<<print _school>> Branch Campus Upkeep__: @@.yellowgreen;<<print cashFormat(1000)>>@@
	<<set _arcologyCosts += 1000>>
	<<if _schoolSubsidy > 0>>

		__<<print _school>> Branch Campus Influence__: @@.yellowgreen;<<print cashFormat(1000)>>@@
	<</if>>
<</if>>
<</if>>

<<if $alwaysSubsidizeGrowth > 0 || $alwaysSubsidizeRep > 0 || $RegularParties > 0>>

__Weekly Costs__:
	<<if $alwaysSubsidizeGrowth > 0>>

    Arcology Growth Subsidy: @@.yellowgreen;<<print cashFormat($policyCost)>>@@
		<<set _arcologyCosts += $policyCost>>
	<</if>>
	<<if $alwaysSubsidizeRep > 0>>

    Self-promotion Budget: @@.yellowgreen;<<print cashFormat($policyCost)>>@@
		<<set _arcologyCosts += $policyCost>>
	<</if>>
	<<if $RegularParties > 0>>

    Social Gatherings: @@.yellowgreen;<<print cashFormat($policyCost)>>@@
		<<set _arcologyCosts += $policyCost>>
	<</if>>
<</if>>

<<if $ProImmigrationCash == 1>>

    Pro-immigration Promotion Budget: @@.yellowgreen;<<print cashFormat($policyCost)>>@@
	<<set _arcologyCosts += $policyCost>>
<</if>>
<<if $AntiEnslavementCash == 1>>

    Anti-enslavement Charity Budget: @@.yellowgreen;<<print cashFormat($policyCost)>>@@
	<<set _arcologyCosts += $policyCost>>
<</if>>

<<if $CoursingAssociation == 1>>

    Coursing Association Membership: @@.yellowgreen;<<print cashFormat(1000)>>@@
	<<set _arcologyCosts += 1000>>
<</if>>

''Overall Arcology Costs:'' @@.yellowgreen;<<print cashFormat(_arcologyCosts)>>@@

<<set _total = 0>> <<set _SL = $slaves.length>>
<<for $i = 0; $i < _SL; $i++>>
<<set _individualCosts = 0>>
	''$slaves[$i].slaveName'':
	<<switch $slaves[$i].assignment>>
		<<case "be confined in the arcade">>
			<<set _livingExpense = ($rulesCost*.75)>>
		<<case "work in the dairy">>
			<<if $dairyRestraintsSetting >= 2>>
				<<set _livingExpense = ($rulesCost*.75)>>
			<<elseif $slaves[$i].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*1.5)>>
			<<elseif $dairyDecoration == "Degradationist">>
				<<set _livingExpense = ($rulesCost*.9)>>
			<<else>>
				<<set _livingExpense = $rulesCost>>
			<</if>>
		<<case "work as a farmhand">>
			<<if $slaves[$i].livingRules == "luxurious">>
				<<set _livingExpense = ($rulesCost)>>
			<<elseif $slaves[$i].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*2)>>
			<<else>>
				<<set _livingExpense = ($rulesCost*.9)>>
			<</if>>
		<<case "work in the brothel">>
			<<if $slaves[$i].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*1.5)>>
			<<else>>
				<<set _livingExpense = $rulesCost>>
			<</if>>
		<<case "serve in the club" "learn in the schoolroom">>
			<<set _livingExpense = ($rulesCost*1.5)>>
		<<case "get treatment in the clinic">>
			<<if $slaves[$i].livingRules == "luxurious">>
				<<set _livingExpense = ($rulesCost*2)>>
			<<elseif $slaves[$i].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*1.5)>>
			<<else>>
				<<set _livingExpense = $rulesCost>>
			<</if>>
		<<case "rest in the spa" "work as a nanny">>
			<<if $slaves[$i].livingRules == "luxurious">>
				<<set _livingExpense = ($rulesCost*1.75)>>
			<<elseif $slaves[$i].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*1.5)>>
			<<else>>
				<<set _livingExpense = $rulesCost>>
			<</if>>
		<<case "be a servant">>
			<<if $slaves[$i].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*1.5)>>
			<<else>>
				<<if $servantsQuartersDecoration == "Degradationist">>
					<<set _livingExpense = ($rulesCost*.9)>>
				<<else>>
					<<set _livingExpense = $rulesCost>>
				<</if>>
			<</if>>
		<<case "be confined in the cellblock">>
			<<if $slaves[$i].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*1.25)>>
			<<else>>
				<<set _livingExpense = ($rulesCost*.9)>>
			<</if>>
		<<case "be the Madam" "be the DJ" "be the Nurse" "be the Wardeness" "be the Attendant" "be the Matron" "be the Schoolteacher" "be the Stewardess" "be the Milkmaid" "be the Farmer">>
			<<set _livingExpense = ($rulesCost*2)>>
		<<default>>
			<<if $slaves[$i].livingRules == "luxurious">>
				<<if $slaves[$i].relationship >= 4>>
					<<set _livingExpense = ($rulesCost*3)>>
				<<else>>
					<<set _livingExpense = ($rulesCost*4)>>
				<</if>>
			<<elseif $slaves[$i].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*2)>>
			<<else>>
				<<set _livingExpense = $rulesCost>>
			<</if>>
	<</switch>>

    Living expenses: @@.yellowgreen;<<print cashFormat(_livingExpense)>>@@
	<<set _individualCosts += _livingExpense>>

    Basic slave food cost: @@.yellowgreen;<<print cashFormat($foodCost*4)>>@@
	<<set _individualCosts += $foodCost*4>>
	<<switch $slaves[$i].diet>>
		<<case "fattening" "muscle building">>

    Heavy diet: @@.yellowgreen;<<print cashFormat($foodCost)>>@@
			<<set _individualCosts += $foodCost>>
		<<case "restricted" "slimming">>

    Light diet: //reduced by// @@.yellowgreen;<<print cashFormat($foodCost)>>@@
			<<set _individualCosts -= $foodCost>>
	<</switch>>
	<<if $slaves[$i].weight > 130 || $slaves[$i].weight > 50 || $slaves[$i].weight < -50>>

    Caloric adjustment for
		<<if $slaves[$i].weight > 130>>
			heavy weight: @@.yellowgreen;<<print cashFormat($foodCost*2)>>@@
			<<set _individualCosts += $foodCost*2>>
		<<elseif $slaves[$i].weight > 50>>
			high weight: @@.yellowgreen;<<print cashFormat($foodCost)>>@@
			<<set _individualCosts += $foodCost>>
		<<elseif $slaves[$i].weight < -50>>
			light weight: //reduced by// @@.yellowgreen;<<print cashFormat($foodCost)>>@@
			<<set _individualCosts -= $foodCost>>
		<</if>>
	<</if>>
	<<if ($slaves[$i].geneticQuirks.fertility == 2 && $slaves[$i].geneticQuirks.hyperFertility == 2 && $slaves[$i].preg == 0 && ($slaves[$i].ovaries == 1 || $slaves[$i].mpreg == 1))>>

		<<if $geneticMappingUpgrade >= 1>>
			Additional dietary supplements due to genetic hyper-fertility: @@.yellowgreen;<<print cashFormat($foodCost/2)>>@@
		<<else>>
			Adjustment for unusual deitary deficiencies: @@.yellowgreen;<<print cashFormat($foodCost/2)>>@@
		<</if>>
		<<set _individualCosts += $foodCost/2>>
	<</if>>
	<<if ($slaves[$i].geneticQuirks.rearLipedema == 2)>>

		<<if $geneticMappingUpgrade >= 1>>
			Additional dietary supplements due to lipedema: @@.yellowgreen;<<print cashFormat($foodCost/5)>>@@
		<<else>>
			Adjustment for unusual deitary deficiencies: @@.yellowgreen;<<print cashFormat($foodCost/5)>>@@
		<</if>>
		<<set _individualCosts += $foodCost/5>>
	<</if>>
	<<if $slaves[$i].drugs == "appetite suppressors">>

    Food saved via suppressed appetite: //reduced by// @@.yellowgreen;<<print cashFormat($foodCost)>>@@
		<<set _individualCosts -= $foodCost>>
	<</if>>
	<<if $slaves[$i].lactation > 0>>

    Food to support
		<<if $slaves[$i].lactation > 1>>heavy<<else>>natural<</if>> lactation from
		<<if Math.trunc($slaves[$i].boobs/10000) > 2>>absurd udders<<elseif Math.trunc($slaves[$i].boobs/10000) > 1>>enormous boobs<<else>>reasonable breasts<</if>>:
		@@.yellowgreen;<<print cashFormat($foodCost*$slaves[$i].lactation*(1+Math.trunc($slaves[$i].boobs/10000)))>>@@
		<<set _individualCosts += $foodCost*$slaves[$i].lactation*(1+Math.trunc($slaves[$i].boobs/10000))>>
	<</if>>
	<<if $slaves[$i].preg > $slaves[$i].pregData.normalBirth/8>>
		<<if $slaves[$i].assignment == "work in the dairy" && $dairyFeedersSetting > 0>>

    Extra feeding costs to support pregnancy are covered by dairy feeders.
		<<elseif ($slaves[$i].assignment == "serve in the master suite" || $slaves[$i].assignment == "be your concubine") && $masterSuiteUpgradePregnancy == 1>>

    Extra feeding costs to support pregnancy are covered by $masterSuiteName luxuries.
		<<else>>
			<<set _pAccMult = 1>>

    Extra feeding to support <<if $slaves[$i].pregControl == "speed up">>accelerated <<set _pAccMult = 3>><</if>>pregnancy:
			@@.yellowgreen;<<print cashFormat($foodCost*$slaves[$i].pregType*_pAccMult)>>@@
			<<set _individualCosts += $foodCost*$slaves[$i].pregType*_pAccMult>>
			<<if $slaves[$i].pregType >= 10>>

    Specialized food blend to support multiples:
				@@.yellowgreen;<<print cashFormat($foodCost*$slaves[$i].pregType*2*_pAccMult)>>@@
				<<set _individualCosts += $foodCost*$slaves[$i].pregType*_pAccMult>>
			<<elseif $slaves[$i].pregType >= 30>>

    Concentrated, quick to digest food blend to support extreme multiples: @@.yellowgreen;<<print cashFormat($foodCost*$slaves[$i].pregType*_pAccMult)>>@@
				<<set _individualCosts += $foodCost*2*$slaves[$i].pregType*_pAccMult>>
			<<elseif $slaves[$i].pregType >= 50>>

    Specialized dietary adjustments and concentrated, quick to digest food required to support absurd multiples: <<print cashFormat($foodCost*$slaves[$i].pregType*3*_pAccMult)>>
				<<set _individualCosts += $foodCost*$slaves[$i].pregType*3*_pAccMult>>
			<<elseif $slaves[$i].pregType >= 100>>

    Specialized dietary requirements and feeding methods to support absurd multiples:
				@@.yellowgreen;<<print cashFormat($foodCost*$slaves[$i].pregType*5*_pAccMult)>>@@
				<<set _individualCosts += $foodCost*$slaves[$i].pregType*5*_pAccMult>>
			<</if>>
		<</if>>
	<</if>>
	<<switch $slaves[$i].diet>>
		<<case "XX" "XY">>

    Hormone enriched diet:
			@@.yellowgreen;<<print cashFormat(25)>>@@
			<<set _individualCosts += 25>>
		<<case "XXY">>

    Specialized hermaphrodite diet:
			@@.yellowgreen;<<print cashFormat(75)>>@@
			<<set _individualCosts += 75>>
		<<case "cleansing">>

    Chemical cleansing diet:
			@@.yellowgreen;<<print cashFormat(50)>>@@
			<<set _individualCosts += 50>>
		<<case "fertility">>

    Specialized fertility diet:
			@@.yellowgreen;<<print cashFormat(25)>>@@
			<<set _individualCosts += 50>>
	<</switch>>
	<<if $boobAccessibility != 1>>
		<<if ($slaves[$i].boobs > 20000)>>
			<<if ($slaves[$i].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($slaves[$i].assignment != "be confined in the arcade")>>

    Increased living expenses due to inconveniently huge boobs:
				@@.yellowgreen;<<print cashFormat(50)>>@@
				<<set _individualCosts += 50>>
			<</if>>
		<</if>>
	<</if>>
	<<if $pregAccessibility != 1>>
		<<if ($slaves[$i].belly >= 60000)>>
			<<if ($slaves[$i].assignment != "labor in the production line") && ($slaves[$i].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($slaves[$i].assignment != "be confined in the arcade")>>

    Increased living expenses due to an inconveniently huge belly:
				@@.yellowgreen;<<print cashFormat(100)>>@@
				<<set _individualCosts += 100>>
			<</if>>
		<</if>>
	<</if>>
	<<if $dickAccessibility != 1>>
		<<if ($slaves[$i].dick > 45)>>
			<<if ($slaves[$i].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($slaves[$i].assignment != "be confined in the arcade")>>

    Increased living expenses due to an inconveniently huge penis:
				@@.yellowgreen;<<print cashFormat(50)>>@@
				<<set _individualCosts += 50>>
			<</if>>
		<</if>>
	<</if>>
	<<if $ballsAccessibility != 1>>
		<<if ($slaves[$i].balls > 90)>>
			<<if ($slaves[$i].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($slaves[$i].assignment != "be confined in the arcade")>>

    Increased living expenses due to inconveniently huge balls:
				@@.yellowgreen;<<print cashFormat(50)>>@@
				<<set _individualCosts += 50>>
			<</if>>
		<</if>>
	<</if>>
	<<if $buttAccessibility != 1>>
		<<if ($slaves[$i].butt > 15)>>
			<<if ($slaves[$i].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($slaves[$i].assignment != "be confined in the arcade")>>

    Increased living expenses due to an inconveniently huge butt:
				@@.yellowgreen;<<print cashFormat(50)>>@@
				<<set _individualCosts += 50>>
			<</if>>
		<</if>>
	<</if>>
	<<if !canSee($slaves[$i]) && ($slaves[$i].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($slaves[$i].assignment != "be confined in the arcade")>>

    Increased living expenses due to lack of sight:
		@@.yellowgreen;<<print cashFormat(50)>>@@
		<<set _individualCosts += 50>>
	<<elseif $slaves[$i].eyes <= -1 && $slaves[$i].eyewear != "corrective glasses" && $slaves[$i].eyewear != "corrective contacts">>

    Increased living expenses due to poor vision:
		@@.yellowgreen;<<print cashFormat(25)>>@@
		<<set _individualCosts += 25>>
	<<elseif ($slaves[$i].eyewear == "blurring glasses") || ($slaves[$i].eyewear == "blurring contacts")>>

    Increased living expenses due to blurred vision:
		@@.yellowgreen;<<print cashFormat(25)>>@@
		<<set _individualCosts += 25>>
	<</if>>
	<<if !canHear($slaves[$i]) && ($slaves[$i].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($slaves[$i].assignment != "be confined in the arcade")>>

    Increased living expenses due to lack of hearing:
		@@.yellowgreen;<<print cashFormat(20)>>@@
		<<set _individualCosts += 20>>
	<<elseif $slaves[$i].hears <= -1 && $slaves[$i].earwear != "hearing aids">>

    Increased living expenses due to poor hearing:
		@@.yellowgreen;<<print cashFormat(5)>>@@
		<<set _individualCosts += 5>>
	<<elseif ($slaves[$i].earwear == "muffling ear plugs")>>

    Increased living expenses due to muffled hearing:
		@@.yellowgreen;<<print cashFormat(5)>>@@
		<<set _individualCosts += 5>>
	<</if>>
	<<if ($slaves[$i].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($slaves[$i].assignment != "be confined in the arcade")>>
		<<if ($slaves[$i].amp != 0)>>
			<<if ($slaves[$i].amp == 1)>>

    Increased living expenses due to limblessness:
				@@.yellowgreen;<<print cashFormat($rulesCost)>>@@
				<<set _individualCosts += $rulesCost>>
			<<else>>

    Increased living expenses due to prosthetics:
				@@.yellowgreen;<<print cashFormat($rulesCost/2)>>@@
				<<set _individualCosts += $rulesCost/2>>
			<</if>>
		<<elseif !canWalk($slaves[$i])>>

    Increased living expenses due to immobility:
			@@.yellowgreen;<<print cashFormat($rulesCost)>>@@
			<<set _individualCosts += $rulesCost>>
		<</if>>
	<</if>>
	<<if $slaves[$i].boobs > 10000>>
		<<if $slaves[$i].boobsImplantType == 1>>

    Maintenance cost for oversized string implants:
			@@.yellowgreen;<<print cashFormat(50)>>@@
			<<set _individualCosts += 50>>
		<</if>>
	<</if>>
	<<if $slaves[$i].butt > 10>>
		<<if $slaves[$i].buttImplantType == 1>>

    Maintenance cost for oversized string implants:
			@@.yellowgreen;<<print cashFormat(50)>>@@
			<<set _individualCosts += 50>>
		<</if>>
	<</if>>
	<<if $slaves[$i].preg > $slaves[$i].pregData.minLiveBirth>>
		<<if $universalRulesBirthing == 1>>
			<<if ($slaves[$i].assignment != "work in the dairy" || $dairyRestraintsSetting < 2)>>

    Coverage cost for daily pregnancy scanning:
				@@.yellowgreen;<<print cashFormat(50)>>@@
				<<set _individualCosts += 50>>
			<</if>>
		<</if>>
	<</if>>
	<<if $CitizenRetirement == 1>>

    Retirement account payments:
		@@.yellowgreen;<<print cashFormat(250)>>@@
		<<set _individualCosts += 250>>
	<</if>>
	<<if ($slaves[$i].inflation == 3)>>
		<<switch $slaves[$i].inflationType>>
		<<case "water">>

    Costs of specially formulated water for enemas; 2 gallons:
			@@.yellowgreen;<<print cashFormat(100)>>@@
			<<set _individualCosts += 100>>
		<<case "food">>

    Costs of filler food for slave stuffing; 2 gallons:
			@@.yellowgreen;<<print cashFormat(($foodCost*4))>>@@
			<<set _individualCosts += ($foodCost*4)>>
		<<case "curative" "aphrodisiac" "tightener">>

    Costs of specially formulated drug mixtures for enemas; 2 gallons:
			@@.yellowgreen;<<print cashFormat((100+($drugsCost*2)))>>@@
			<<set _individualCosts += (100+($drugsCost*2))>>
		<</switch>>
	<<elseif ($slaves[$i].inflation == 2)>>
		<<switch $slaves[$i].inflationType>>
		<<case "water">>

    Costs of specially formulated water for enemas; 1 gallon:
			@@.yellowgreen;<<print cashFormat(50)>>@@
			<<set _individualCosts += 50>>
		<<case "food">>

    Costs of filler food for slave stuffing; 1 gallon:
			@@.yellowgreen;<<print cashFormat(($foodCost*2))>>@@
			<<set _individualCosts += ($foodCost*4)>>
		<<case "curative" "aphrodisiac" "tightener">>

    Costs of specially formulated drug mixtures for enemas; 1 gallon:
			@@.yellowgreen;<<print cashFormat((50+($drugsCost*2)))>>@@
			<<set _individualCosts += (50+($drugsCost*2))>>
		<</switch>>
	<<elseif ($slaves[$i].inflation == 1)>>
		<<switch $slaves[$i].inflationType>>
		<<case "water">>

    Costs of specially formulated water for enemas; 2 liters:
			@@.yellowgreen;<<print cashFormat(25)>>@@
			<<set _individualCosts += 25>>
		<<case "food">>

    Costs of filler food for slave stuffing; 2 liters:
			<<print cashFormat(($foodCost))>>
			<<set _individualCosts += ($foodCost)>>
		<<case "curative" "aphrodisiac" "tightener">>

    Costs of specially formulated drug mixtures for enemas; 2 liters:
			@@.yellowgreen;<<print cashFormat((25+($drugsCost*2)))>>@@
			<<set _individualCosts += (25+($drugsCost*2))>>
		<</switch>>
	<</if>>
	<<switch $slaves[$i].drugs>>
	<<case "anti-aging cream">>

    Anti-aging creams:
		<<print cashFormat(($drugsCost*10))>>
		<<set _individualCosts += ($drugsCost*10)>>
	<<case "female hormone injections" "male hormone injections">>

    Hormonal injections:
		@@.yellowgreen;<<print cashFormat(($drugsCost*5))>>@@
		<<set _individualCosts += ($drugsCost*5)>>
	<<case "growth stimulants">>

    Growth stimulants:
		@@.yellowgreen;<<print cashFormat(($drugsCost*5))>>@@
		<<set _individualCosts += ($drugsCost*5)>>
	<<case "intensive breast injections" "intensive butt injections" "intensive penis enhancement" "intensive testicle enhancement" "intensive lip injections" "hyper breast injections" "hyper butt injections" "hyper penis enhancement" "hyper testicle enhancement" "hyper lip injections">>

    Intensive drugs:
		@@.yellowgreen;<<print cashFormat($drugsCost*5)>>@@
		<<set _individualCosts += $drugsCost*5>>
	<<case "sag-B-gone">>

    Questionable infomercial creams:
		@@.yellowgreen;<<print cashFormat(Math.trunc($drugsCost/10))>>@@
		<<set _individualCosts += ($drugsCost/10)>>
	<<case "no drugs" "none">>
	<<default>>

    Standard drugs:
		@@.yellowgreen;<<print cashFormat(($drugsCost*2))>>@@
		<<set _individualCosts += ($drugsCost*2)>>
	<</switch>>
	<<if $slaves[$i].curatives == 1 && $slaves[$i].assignmentVisible != 1>>
	<<elseif $slaves[$i].curatives > 0>>

    Health drugs:
		@@.yellowgreen;<<print cashFormat($drugsCost+($slaves[$i].curatives*$drugsCost))>>@@
		<<set _individualCosts += $drugsCost+($slaves[$i].curatives*$drugsCost)>>
	<</if>>
	<<if ($slaves[$i].aphrodisiacs !== 0)>>

    Aphrodisiacs/Anaphrodisiacs:
		@@.yellowgreen;<<print cashFormat(Math.trunc($drugsCost*Math.abs($slaves[$i].aphrodisiacs)))>>@@
		<<set _individualCosts += $drugsCost*Math.abs($slaves[$i].aphrodisiacs)>>
	<</if>>
	<<if ($slaves[$i].hormones != 0)>>

    Hormones:
		@@.yellowgreen;<<print cashFormat((Math.trunc($drugsCost*Math.abs($slaves[$i].hormones)*0.5)))>>@@
		<<set _individualCosts += Math.trunc($drugsCost*Math.abs($slaves[$i].hormones)*0.5)>>
	<</if>>
	<<if ($slaves[$i].bodySwap > 0)>>

    JS-Suppressants:
		@@.yellowgreen;<<print cashFormat(($drugsCost*10*$slaves[$i].bodySwap))>>@@
		<<set _individualCosts += Math.trunc($drugsCost*10*$slaves[$i].bodySwap)>>
	<</if>>
	<<if ($slaves[$i].preg == -1) && isFertile($slaves[$i])>>

    Contraceptives:
		@@.yellowgreen;<<print cashFormat((Math.trunc($drugsCost*0.5)))>>@@
		<<set _individualCosts += Math.trunc($drugsCost*0.5)>>
	<</if>>
	<<if ($studio == 1)>>
		<<if ($slaves[$i].pornFameSpending > 0)>>

    Publicity:
			@@.yellowgreen;<<print cashFormat($slaves[$i].pornFameSpending/$PCSlutContacts)>>@@
			<<set _individualCosts += ($slaves[$i].pornFameSpending/$PCSlutContacts)>>
		<</if>>
	<</if>> <<set _total += Math.trunc(_individualCosts)>>

        __Total__:
	@@.yellowgreen;<<print cashFormat(Math.trunc(_individualCosts))>>@@

<</for>>
*/
<<set _total = 0>> <<set _SL = $slaves.length>>
<<for $i = 0; $i < _SL; $i++>>
	<<capture $i>>

<<if $lineSeparations == 0>>
<<else>>
<</if>>
	[[$slaves[$i].slaveName|Slave Interact][$activeSlave = $slaves[$i]]] will $slaves[$i].assignment.
	<<SlaveExpenses $slaves[$i]>>
	<</capture>>
<</for>>
/*

Overall slave costs: @@.yellowgreen;<<print cashFormat(_total)>>@@

This brings the overall total to ''@@.yellowgreen;<<print cashFormat(_arcologyCosts+_total)>>@@'' before reductions.

<<if $PC.career == "servant">>

Using your prior experience, you managed to lower your home's upkeep by @@.green;<<if $personalAttention == "upkeep">><<if $PC.belly >= 5000>>20%<<else>>25%<</if>><<else>>10%<</if>>.@@
<</if>>

<<if $secExp == 1>>

	<<if $terrain == "oceanic" || $terrain == "marine">>
		<<if $docks > 0>>

The infrastructure you've built eases the transportation and safe handling of the supplies required by the arcology. @@.green;Upkeep is lowered by <<print $docks * 5>>%.@@
		<</if>>
	<<else>>
		<<if $railway > 0>>

The infrastructure you've built eases the transportation and safe handling of the supplies required by the arcology. @@.green;Upkeep is lowered by <<print $railway * 5>>%.@@
		<</if>>
	<</if>>
<</if>>
*/

repo_name: Fekenol/fc


code:
:: Costs Report Slaves [nobr]

<<set _arcologyCosts = 0>>
<<if $PCSlutContacts == 0>><<set $PCSlutContacts = 1>><</if>>

<<set _total = 0>> <<set _SL = $slaves.length>>
<<for $i = 0; $i < _SL; $i++>>
	<<capture $i>>

<<if $lineSeparations == 0>>
<<else>>
<</if>>
	[[$slaves[$i].slaveName|Slave Interact][$activeSlave = $slaves[$i]]] will $slaves[$i].assignment.
	<<SlaveExpenses $slaves[$i]>>
	<</capture>>
<</for>>


code:
:: Cost widgets [nobr widget]

<<widget "SlaveExpenses">>
	<<set _individualCosts = 0>>
	<<setLocalPronouns $args[0]>>
	<<switch $args[0].assignment>>
		<<case "be confined in the arcade">>
			<<set _livingExpense = ($rulesCost*.75)>>
		<<case "work in the dairy">>
			<<if $dairyRestraintsSetting >= 2>>
				<<set _livingExpense = ($rulesCost*.75)>>
			<<elseif $args[0].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*1.5)>>
			<<elseif $dairyDecoration == "Degradationist">>
				<<set _livingExpense = ($rulesCost*.9)>>
			<<else>>
				<<set _livingExpense = $rulesCost>>
			<</if>>
		<<case "work as a farmhand">>
			<<if $args[0].livingRules == "luxurious">>
				<<set _livingExpense = ($rulesCost)>>
			<<elseif $args[0].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*2)>>
			<<else>>
				<<set _livingExpense = ($rulesCost*.9)>>
			<</if>>
		<<case "work in the brothel">>
			<<if $args[0].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*1.5)>>
			<<else>>
				<<set _livingExpense = $rulesCost>>
			<</if>>
		<<case "serve in the club" "learn in the schoolroom">>
			<<set _livingExpense = ($rulesCost*1.5)>>
		<<case "get treatment in the clinic">>
			<<if $args[0].livingRules == "luxurious">>
				<<set _livingExpense = ($rulesCost*2)>>
			<<elseif $args[0].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*1.5)>>
			<<else>>
				<<set _livingExpense = $rulesCost>>
			<</if>>
		<<case "rest in the spa" "work as a nanny">>
			<<if $args[0].livingRules == "luxurious">>
				<<set _livingExpense = ($rulesCost*1.75)>>
			<<elseif $args[0].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*1.5)>>
			<<else>>
				<<set _livingExpense = $rulesCost>>
			<</if>>
		<<case "be a servant">>
			<<if $args[0].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*1.5)>>
			<<else>>
				<<if $servantsQuartersDecoration == "Degradationist">>
					<<set _livingExpense = ($rulesCost*.9)>>
				<<else>>
					<<set _livingExpense = $rulesCost>>
				<</if>>
			<</if>>
		<<case "be confined in the cellblock">>
			<<if $args[0].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*1.25)>>
			<<else>>
				<<set _livingExpense = ($rulesCost*.9)>>
			<</if>>
		<<case "be the Madam" "be the DJ" "be the Nurse" "be the Wardeness" "be the Attendant" "be the Matron" "be the Schoolteacher" "be the Stewardess" "be the Milkmaid" "be the Farmer">>
			<<set _livingExpense = ($rulesCost*2)>>
		<<default>>
			<<if $args[0].livingRules == "luxurious">>
				<<if $args[0].relationship >= 4>>
					<<set _livingExpense = ($rulesCost*3)>>
				<<else>>
					<<set _livingExpense = ($rulesCost*4)>>
				<</if>>
			<<elseif $args[0].livingRules == "normal">>
				<<set _livingExpense = ($rulesCost*2)>>
			<<else>>
				<<set _livingExpense = $rulesCost>>
			<</if>>
	<</switch>>

    Living expenses: @@.yellowgreen;<<print cashFormat(_livingExpense)>>@@
	<<set _individualCosts += _livingExpense>>

    Basic slave food cost: @@.yellowgreen;<<print cashFormat($foodCost*4)>>@@
	<<set _individualCosts += $foodCost*4>>
	<<switch $args[0].diet>>
		<<case "fattening" "muscle building">>

    Heavy diet: @@.yellowgreen;<<print cashFormat($foodCost)>>@@
			<<set _individualCosts += $foodCost>>
		<<case "restricted" "slimming">>

    Light diet: //reduced by// @@.yellowgreen;<<print cashFormat($foodCost)>>@@
			<<set _individualCosts -= $foodCost>>
	<</switch>>
	<<if $args[0].weight > 130 || $args[0].weight > 50 || $args[0].weight < -50>>

    Caloric adjustment for
		<<if $args[0].weight > 130>>
			heavy weight: @@.yellowgreen;<<print cashFormat($foodCost*2)>>@@
			<<set _individualCosts += $foodCost*2>>
		<<elseif $args[0].weight > 50>>
			high weight: @@.yellowgreen;<<print cashFormat($foodCost)>>@@
			<<set _individualCosts += $foodCost>>
		<<elseif $args[0].weight < -50>>
			light weight: //reduced by// @@.yellowgreen;<<print cashFormat($foodCost)>>@@
			<<set _individualCosts -= $foodCost>>
		<</if>>
	<</if>>
	<<if ($args[0].geneticQuirks.fertility == 2 && $args[0].geneticQuirks.hyperFertility == 2 && $args[0].preg == 0 && ($args[0].ovaries == 1 || $args[0].mpreg == 1))>>

		<<if $geneticMappingUpgrade >= 1>>
			Additional dietary supplements due to genetic hyper-fertility: @@.yellowgreen;<<print cashFormat($foodCost/2)>>@@
		<<else>>
			Adjustment for unusual deitary deficiencies: @@.yellowgreen;<<print cashFormat($foodCost/2)>>@@
		<</if>>
		<<set _individualCosts += $foodCost/2>>
	<</if>>
	<<if ($args[0].geneticQuirks.rearLipedema == 2)>>

		<<if $geneticMappingUpgrade >= 1>>
			Additional dietary supplements due to lipedema: @@.yellowgreen;<<print cashFormat($foodCost/5)>>@@
		<<else>>
			Adjustment for unusual deitary deficiencies: @@.yellowgreen;<<print cashFormat($foodCost/5)>>@@
		<</if>>
		<<set _individualCosts += $foodCost/5>>
	<</if>>
	<<if $args[0].drugs == "appetite suppressors">>

    Food saved via suppressed appetite: //reduced by// @@.yellowgreen;<<print cashFormat($foodCost)>>@@
		<<set _individualCosts -= $foodCost>>
	<</if>>
	<<if $args[0].lactation > 0>>

    Food to support
		<<if $args[0].lactation > 1>>heavy<<else>>natural<</if>> lactation from
		<<if Math.trunc($args[0].boobs/10000) > 2>>absurd udders<<elseif Math.trunc($args[0].boobs/10000) > 1>>enormous boobs<<else>>reasonable breasts<</if>>:
		@@.yellowgreen;<<print cashFormat($foodCost*$args[0].lactation*(1+Math.trunc($args[0].boobs/10000)))>>@@
		<<set _individualCosts += $foodCost*$args[0].lactation*(1+Math.trunc($args[0].boobs/10000))>>
	<</if>>
	<<if $args[0].preg > $args[0].pregData.normalBirth/8>>
		<<if $args[0].assignment == "work in the dairy" && $dairyFeedersSetting > 0>>

    Extra feeding costs to support pregnancy are covered by dairy feeders.
		<<elseif ($args[0].assignment == "serve in the master suite" || $args[0].assignment == "be your concubine") && $masterSuiteUpgradePregnancy == 1>>

    Extra feeding costs to support pregnancy are covered by $masterSuiteName luxuries.
		<<else>>
			<<set _pAccMult = 1>>

    Extra feeding to support <<if $args[0].pregControl == "speed up">>accelerated <<set _pAccMult = 3>><</if>>pregnancy:
			@@.yellowgreen;<<print cashFormat($foodCost*$args[0].pregType*_pAccMult)>>@@
			<<set _individualCosts += $foodCost*$args[0].pregType*_pAccMult>>
			<<if $args[0].pregType >= 10>>

    Specialized food blend to support multiples:
				@@.yellowgreen;<<print cashFormat($foodCost*$args[0].pregType*2*_pAccMult)>>@@
				<<set _individualCosts += $foodCost*$args[0].pregType*_pAccMult>>
			<<elseif $args[0].pregType >= 30>>

    Concentrated, quick to digest food blend to support extreme multiples: @@.yellowgreen;<<print cashFormat($foodCost*$args[0].pregType*_pAccMult)>>@@
				<<set _individualCosts += $foodCost*2*$args[0].pregType*_pAccMult>>
			<<elseif $args[0].pregType >= 50>>

    Specialized dietary adjustments and concentrated, quick to digest food required to support absurd multiples: <<print cashFormat($foodCost*$args[0].pregType*3*_pAccMult)>>
				<<set _individualCosts += $foodCost*$args[0].pregType*3*_pAccMult>>
			<<elseif $args[0].pregType >= 100>>

    Specialized dietary requirements and feeding methods to support absurd multiples:
				@@.yellowgreen;<<print cashFormat($foodCost*$args[0].pregType*5*_pAccMult)>>@@
				<<set _individualCosts += $foodCost*$args[0].pregType*5*_pAccMult>>
			<</if>>
		<</if>>
	<</if>>
	<<switch $args[0].diet>>
		<<case "XX" "XY">>

    Hormone enriched diet:
			@@.yellowgreen;<<print cashFormat(25)>>@@
			<<set _individualCosts += 25>>
		<<case "XXY">>

    Specialized hermaphrodite diet:
			@@.yellowgreen;<<print cashFormat(75)>>@@
			<<set _individualCosts += 75>>
		<<case "cleansing">>

    Chemical cleansing diet:
			@@.yellowgreen;<<print cashFormat(50)>>@@
			<<set _individualCosts += 50>>
		<<case "fertility">>

    Specialized fertility diet:
			@@.yellowgreen;<<print cashFormat(25)>>@@
			<<set _individualCosts += 50>>
	<</switch>>
	<<if $boobAccessibility != 1>>
		<<if ($args[0].boobs > 20000)>>
			<<if ($args[0].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($args[0].assignment != "be confined in the arcade")>>

    Increased living expenses due to inconveniently huge boobs:
				@@.yellowgreen;<<print cashFormat(50)>>@@
				<<set _individualCosts += 50>>
			<</if>>
		<</if>>
	<</if>>
	<<if $pregAccessibility != 1>>
		<<if ($args[0].belly >= 60000)>>
			<<if ($args[0].assignment != "labor in the production line") && ($args[0].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($args[0].assignment != "be confined in the arcade")>>

    Increased living expenses due to an inconveniently huge belly:
				@@.yellowgreen;<<print cashFormat(100)>>@@
				<<set _individualCosts += 100>>
			<</if>>
		<</if>>
	<</if>>
	<<if $dickAccessibility != 1>>
		<<if ($args[0].dick > 45)>>
			<<if ($args[0].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($args[0].assignment != "be confined in the arcade")>>

    Increased living expenses due to an inconveniently huge penis:
				@@.yellowgreen;<<print cashFormat(50)>>@@
				<<set _individualCosts += 50>>
			<</if>>
		<</if>>
	<</if>>
	<<if $ballsAccessibility != 1>>
		<<if ($args[0].balls > 90)>>
			<<if ($args[0].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($args[0].assignment != "be confined in the arcade")>>

    Increased living expenses due to inconveniently huge balls:
				@@.yellowgreen;<<print cashFormat(50)>>@@
				<<set _individualCosts += 50>>
			<</if>>
		<</if>>
	<</if>>
	<<if $buttAccessibility != 1>>
		<<if ($args[0].butt > 15)>>
			<<if ($args[0].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($args[0].assignment != "be confined in the arcade")>>

    Increased living expenses due to an inconveniently huge butt:
				@@.yellowgreen;<<print cashFormat(50)>>@@
				<<set _individualCosts += 50>>
			<</if>>
		<</if>>
	<</if>>
	<<if !canSee($args[0]) && ($args[0].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($args[0].assignment != "be confined in the arcade")>>

    Increased living expenses due to lack of sight:
		@@.yellowgreen;<<print cashFormat(50)>>@@
		<<set _individualCosts += 50>>
	<<elseif $args[0].eyes <= -1 && $args[0].eyewear != "corrective glasses" && $args[0].eyewear != "corrective contacts">>

    Increased living expenses due to poor vision:
		@@.yellowgreen;<<print cashFormat(25)>>@@
		<<set _individualCosts += 25>>
	<<elseif ($args[0].eyewear == "blurring glasses") || ($args[0].eyewear == "blurring contacts")>>

    Increased living expenses due to blurred vision:
		@@.yellowgreen;<<print cashFormat(25)>>@@
		<<set _individualCosts += 25>>
	<</if>>
	<<if !canHear($args[0]) && ($args[0].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($args[0].assignment != "be confined in the arcade")>>

    Increased living expenses due to lack of hearing:
		@@.yellowgreen;<<print cashFormat(20)>>@@
		<<set _individualCosts += 20>>
	<<elseif $args[0].hears <= -1 && $args[0].earwear != "hearing aids">>

    Increased living expenses due to poor hearing:
		@@.yellowgreen;<<print cashFormat(5)>>@@
		<<set _individualCosts += 5>>
	<<elseif ($args[0].earwear == "muffling ear plugs")>>

    Increased living expenses due to muffled hearing:
		@@.yellowgreen;<<print cashFormat(5)>>@@
		<<set _individualCosts += 5>>
	<</if>>
	<<if ($args[0].assignment != "work in the dairy" || $dairyRestraintsSetting < 2) && ($args[0].assignment != "be confined in the arcade")>>
		<<if ($args[0].amp != 0)>>
			<<if ($args[0].amp == 1)>>

    Increased living expenses due to limblessness:
				@@.yellowgreen;<<print cashFormat($rulesCost)>>@@
				<<set _individualCosts += $rulesCost>>
			<<else>>

    Increased living expenses due to prosthetics:
				@@.yellowgreen;<<print cashFormat($rulesCost/2)>>@@
				<<set _individualCosts += $rulesCost/2>>
			<</if>>
		<<elseif !canWalk($args[0])>>

    Increased living expenses due to immobility:
			@@.yellowgreen;<<print cashFormat($rulesCost)>>@@
			<<set _individualCosts += $rulesCost>>
		<</if>>
	<</if>>
	<<if $args[0].boobs > 10000>>
		<<if $args[0].boobsImplantType == 1>>

    Maintenance cost for oversized string implants:
			@@.yellowgreen;<<print cashFormat(50)>>@@
			<<set _individualCosts += 50>>
		<</if>>
	<</if>>
	<<if $args[0].butt > 10>>
		<<if $args[0].buttImplantType == 1>>

    Maintenance cost for oversized string implants:
			@@.yellowgreen;<<print cashFormat(50)>>@@
			<<set _individualCosts += 50>>
		<</if>>
	<</if>>
	<<if $args[0].preg > $args[0].pregData.minLiveBirth>>
		<<if $universalRulesBirthing == 1>>
			<<if ($args[0].assignment != "work in the dairy" || $dairyRestraintsSetting < 2)>>

    Coverage cost for daily pregnancy scanning:
				@@.yellowgreen;<<print cashFormat(50)>>@@
				<<set _individualCosts += 50>>
			<</if>>
		<</if>>
	<</if>>
	<<if $CitizenRetirement == 1>>

    Retirement account payments:
		@@.yellowgreen;<<print cashFormat(250)>>@@
		<<set _individualCosts += 250>>
	<</if>>
	<<if ($args[0].inflation == 3)>>
		<<switch $args[0].inflationType>>
		<<case "water">>

    Costs of specially formulated water for enemas; 2 gallons:
			@@.yellowgreen;<<print cashFormat(100)>>@@
			<<set _individualCosts += 100>>
		<<case "food">>

    Costs of filler food for slave stuffing; 2 gallons:
			@@.yellowgreen;<<print cashFormat(($foodCost*4))>>@@
			<<set _individualCosts += ($foodCost*4)>>
		<<case "curative" "aphrodisiac" "tightener">>

    Costs of specially formulated drug mixtures for enemas; 2 gallons:
			@@.yellowgreen;<<print cashFormat((100+($drugsCost*2)))>>@@
			<<set _individualCosts += (100+($drugsCost*2))>>
		<</switch>>
	<<elseif ($args[0].inflation == 2)>>
		<<switch $args[0].inflationType>>
		<<case "water">>

    Costs of specially formulated water for enemas; 1 gallon:
			@@.yellowgreen;<<print cashFormat(50)>>@@
			<<set _individualCosts += 50>>
		<<case "food">>

    Costs of filler food for slave stuffing; 1 gallon:
			@@.yellowgreen;<<print cashFormat(($foodCost*2))>>@@
			<<set _individualCosts += ($foodCost*4)>>
		<<case "curative" "aphrodisiac" "tightener">>

    Costs of specially formulated drug mixtures for enemas; 1 gallon:
			@@.yellowgreen;<<print cashFormat((50+($drugsCost*2)))>>@@
			<<set _individualCosts += (50+($drugsCost*2))>>
		<</switch>>
	<<elseif ($args[0].inflation == 1)>>
		<<switch $args[0].inflationType>>
		<<case "water">>

    Costs of specially formulated water for enemas; 2 liters:
			@@.yellowgreen;<<print cashFormat(25)>>@@
			<<set _individualCosts += 25>>
		<<case "food">>

    Costs of filler food for slave stuffing; 2 liters:
			<<print cashFormat(($foodCost))>>
			<<set _individualCosts += ($foodCost)>>
		<<case "curative" "aphrodisiac" "tightener">>

    Costs of specially formulated drug mixtures for enemas; 2 liters:
			@@.yellowgreen;<<print cashFormat((25+($drugsCost*2)))>>@@
			<<set _individualCosts += (25+($drugsCost*2))>>
		<</switch>>
	<</if>>
	<<switch $args[0].drugs>>
	<<case "anti-aging cream">>

    Anti-aging creams:
		<<print cashFormat(($drugsCost*10))>>
		<<set _individualCosts += ($drugsCost*10)>>
	<<case "female hormone injections" "male hormone injections">>

    Hormonal injections:
		@@.yellowgreen;<<print cashFormat(($drugsCost*5))>>@@
		<<set _individualCosts += ($drugsCost*5)>>
	<<case "growth stimulants">>

    Growth stimulants:
		@@.yellowgreen;<<print cashFormat(($drugsCost*5))>>@@
		<<set _individualCosts += ($drugsCost*5)>>
	<<case "intensive breast injections" "intensive butt injections" "intensive penis enhancement" "intensive testicle enhancement" "intensive lip injections" "hyper breast injections" "hyper butt injections" "hyper penis enhancement" "hyper testicle enhancement" "hyper lip injections">>

    Intensive drugs:
		@@.yellowgreen;<<print cashFormat($drugsCost*5)>>@@
		<<set _individualCosts += $drugsCost*5>>
	<<case "sag-B-gone">>

    Questionable infomercial creams:
		@@.yellowgreen;<<print cashFormat(Math.trunc($drugsCost/10))>>@@
		<<set _individualCosts += ($drugsCost/10)>>
	<<case "no drugs" "none">>
	<<default>>

    Standard drugs:
		@@.yellowgreen;<<print cashFormat(($drugsCost*2))>>@@
		<<set _individualCosts += ($drugsCost*2)>>
	<</switch>>
	<<if $args[0].curatives > 0>>

    Health drugs:
		@@.yellowgreen;<<print cashFormat($args[0].curatives*$drugsCost)>>@@
		<<set _individualCosts += $drugsCost+($args[0].curatives*$drugsCost)>>
	<</if>>
	<<if ($args[0].aphrodisiacs !== 0)>>

    Aphrodisiacs/Anaphrodisiacs:
		@@.yellowgreen;<<print cashFormat(Math.trunc($drugsCost*Math.abs($args[0].aphrodisiacs)))>>@@
		<<set _individualCosts += $drugsCost*Math.abs($args[0].aphrodisiacs)>>
	<</if>>
	<<if ($args[0].hormones != 0)>>

    Hormones:
		@@.yellowgreen;<<print cashFormat((Math.trunc($drugsCost*Math.abs($args[0].hormones)*0.5)))>>@@
		<<set _individualCosts += Math.trunc($drugsCost*Math.abs($args[0].hormones)*0.5)>>
	<</if>>
	<<if ($args[0].bodySwap > 0)>>

    JS-Suppressants:
		@@.yellowgreen;<<print cashFormat(($drugsCost*10*$args[0].bodySwap))>>@@
		<<set _individualCosts += Math.trunc($drugsCost*10*$args[0].bodySwap)>>
	<</if>>
	<<if ($args[0].preg == -1) && isFertile($args[0])>>

    Contraceptives:
		@@.yellowgreen;<<print cashFormat((Math.trunc($drugsCost*0.5)))>>@@
		<<set _individualCosts += Math.trunc($drugsCost*0.5)>>
	<</if>>
	<<if ($studio == 1)>>
		<<if ($args[0].pornFameSpending > 0)>>

    Publicity:
			@@.yellowgreen;<<print cashFormat($args[0].pornFameSpending/$PCSlutContacts)>>@@
			<<set _individualCosts += ($args[0].pornFameSpending/$PCSlutContacts)>>
		<</if>>
	<</if>> <<set _total += Math.trunc(_individualCosts)>>

        __Predicted expense__: @@.red;<<print cashFormat(Math.trunc(_individualCosts))>>@@
	<<if $assistantPower > 0>>
		<<if $args[0].lastWeeksCashIncome > 0>>

    Income: @@.yellowgreen;<<print cashFormat($args[0].lastWeeksCashIncome)>>@@
			<<set _total = (Math.trunc($args[0].lastWeeksCashIncome - _individualCosts))>>

        __Total__:
			<<if _total > 0>>
				@@.yellowgreen;<<print cashFormat(Math.trunc(_total))>>@@
			<<else>>
				@@.red;<<print cashFormat(Math.trunc(_total))>>@@
			<</if>>
		<</if>>
	<</if>>

	<<if $args[0].origin != 0>>
		$args[0].origin

	<</if>>
	<<if $args[0].slaveCost < 0>>
		You bought $him for: @@.red;<<print cashFormat($args[0].slaveCost)>>.@@
		<<set _Cost = $args[0].slaveCost>>
	<<elseif $args[0].slaveCost == 0>>
		You spent nothing to acquire $him.
		<<set _Cost = $args[0].slaveCost>>
	<<else>>
		You have no record of how much <<if $args[0].origin != 0>>this<<else>>$he originally<</if>> cost.
		<<set _Cost = 0>>
	<</if>>

	<<if $assistantPower > 0>>
		<<set _weeksOwned = $week - $args[0].weekAcquired>>

		<<if $args[0].lifetimeCashExpenses < 0>>
			In $his <<if _weeksOwned > 0>>_weeksOwned <<if _weeksOwned == 1>>week<<else>>weeks<</if>><<else>>time<</if>> with you, $he has cost @@.red;<<print cashFormat($args[0].lifetimeCashExpenses)>>.@@
			<<set _Expense = $args[0].lifetimeCashExpenses>>
		<<else>>
			You have no record of $him costing you any ¤.
			<<set _Expense = 0>>
		<</if>>

		<<if $args[0].lifetimeCashIncome > 0>>
			In $his <<if _weeksOwned > 0>>_weeksOwned <<if _weeksOwned == 1>>week<<else>>weeks<</if>><<else>>time<</if>> with you, $he has earned @@.yellowgreen;<<print cashFormat($args[0].lifetimeCashIncome)>>.@@
			<<set _Income = $args[0].lifetimeCashIncome>>
		<<else>>
			You have no record of $him making you any ¤.
			<<set _Income = 0>>
		<</if>>

		Overall,
		<<if (_Income + _Cost + _Expense) > 0>>
			you have made @@.yellowgreen;<<print cashFormat(_Income + _Cost + _Expense)>>@@ net from $his labors.
		<<elseif (_Income + _Cost + _Expense) == 0>>
			$he is even in cost and income.
		<<else>>
			$he has cost you @@.red;<<print cashFormat(_Income + _Cost + _Expense)>>.@@
		<</if>>

		/* Reputation: */
		<<if ($args[0].lifetimeRepIncome != 0 || $args[0].lifetimeRepExpenses != 0)>>

			<<set _repTotal = ($args[0].lifetimeRepIncome + $args[0].lifetimeRepExpenses)>>
			<<if ($cheatMode == 1 || $debugMode == 1)>>
				<<if $args[0].lifetimeRepIncome != 0>>

					This week $he has
					<<if $args[0].lastWeeksRepIncome == 0>>
						had no positive effect on your reputation, but
					<<else>>
						improved your reputation by @@.green;<<print num($args[0].lastWeeksRepIncome)>>@@ and
					<</if>>
					over $his entire time with you, $he gained @@.green;<<print num($args[0].lifetimeRepIncome)>>.@@
				<</if>>
				<<if $args[0].lifetimeRepExpenses != 0>>

					This week $he has
					<<if $args[0].lastWeeksRepExpenses == 0>>
						had no negative effect on your reputation, but
					<<else>>
						lowered your reputation by @@.red;<<print num($args[0].lastWeeksRepExpenses)>>@@ and
					<</if>>
					over $his entire time with you, $he cost @@.red;<<print num($args[0].lifetimeRepExpenses)>>.@@
				<</if>>

				Overall then, $he has changed your reputation by
				<<if _repTotal > 0>>
					@@.green;<<print num(_repTotal)>>@@
				<<elseif _repTotal < 0>>
					@@.red;<<print num(_repTotal)>>@@
				<<else>>
					<<print num(_repTotal)>>
				<</if>>
			<<else>> /* lowercasedonkey: TODO: I don't like how vague my placeholder is. Probably need to set up some kind of sliding scale to describe how much rep (roughly) she has made or lost. Need to get a sense of common ranges. */

				Overall, $he has
				<<if _repTotal == 0>>
					had no impact on your reputation.
				<<elseif _repTotal > 0>>
					@@.green;increased@@ your reputation.
				<<elseif _repTotal < 0>>
					@@.red;decreased@@ your reputation.
				<</if>>
			<</if>>
		<</if>>
	<</if>>
<</widget>>

<<widget "setupLastWeeksCash">>
/* Feel free to add categories. Just make sure to display them in costsBudget.tw as well! */
<<set $lastWeeksCashIncome = {
/*Slave Jobs*/
whore: 0,
whoreBrothel: 0,
rest: 0,
houseServant: 0,
confined: 0,
publicServant: 0,
classes: 0,
milked: 0,
milkedDairy: 0,
extraMilk: 0, /*milk from slaves doing other things*/
gloryhole: 0,
gloryholeArcade: 0,
porn: 0,

recruiter: 0,

/*Slaves in general*/
fuckdolls: 0,
menialTrades: 0,
menialBioreactors: 0,

slaveTransfer: 0,
fuckdollsTransfer: 0,
menialTransfer: 0,
menialBioreactorsTransfer: 0,
babyTransfer: 0,
menialRetirement: 0,

slaveMod: 0,
slaveSurgery: 0,
slaveUpkeep: 0,
birth: 0,

/*Buildings*/
lab: 0,
brothel: 0,
brothelAds: 0,
club: 0,
clubAds: 0,
arcade: 0,
dairy: 0,
servantsQuarters: 0,
masterSuite: 0,
school: 0,
spa: 0,
clinic: 0,
cellblock: 0,
incubator: 0,
nursery: 0,
farmyard: 0,
pit: 0,

environment: 0,
weather: 0,

mercenaries: 0,
peacekeepers: 0,
specialForces: 0,
securityExpansion: 0,

citizenOrphanage: 0,
privateOrphanage: 0,

capEx: 0,
futureSocieties: 0,
schoolBacking: 0,
policies: 0,

/*Personal Finance*/
personalBusiness: 0,
personalLivingExpenses: 0,
PCtraining: 0,
PCmedical: 0,
PCskills: 0,
stocksTraded: 0, /*trading*/
stocks: 0, /*share growth*/
fines: 0,
event: 0, /* poker night etc. Try to file things elsewhere if you can. */
war: 0,

rents: 0,

cheating: 0,
total: 0

}>>

<<set $lastWeeksCashExpenses = clone($lastWeeksCashIncome)>>
<<set $lastWeeksCashProfits = clone($lastWeeksCashIncome)>>

<</widget>>

<<widget "setupLastWeeksRep">>
/* Feel free to add categories. Just make sure to display them in costsBudget.tw as well! */
<<set $lastWeeksRepIncome = {
/*Slave Jobs*/
fucktoy: 0,
publicServant: 0,
gloryholeArcade: 0,
gloryhole: 0,

concubine: 0,
headGirl: 0,
bodyguard: 0,
recruiter: 0,

/*Slaves in general*/
fuckdolls: 0,
slaveTransfer: 0,
babyTransfer: 0,
birth: 0,
retirement: 0,
slavesViewOfPC: 0,
prestigiousSlave: 0,
vignette: 0,
porn: 0,

/*Buildings*/
arcade: 0,
brothel: 0,
club: 0,
publicServantClub: 0,
clubAds: 0,
pit: 0,
servantsQuarters: 0,
spa: 0,

architecture: 0,

/*Policies*/
capEx: 0,
futureSocieties: 0,
policies: 0,
war: 0,
food: 0,

/*Forces */
peacekeepers: 0,
specialForces: 0,

/*Personal Finance*/
personalBusiness: 0,
PCappearance: 0,
PCactions: 0, /* actions involving your body: becoming pregnant, etc. */
PCRelationships: 0,
SlaveRelationships: 0,
event: 0, /*poker night etc. Try to file things elsewhere if you can.*/

/*special*/
multiplier: 0,
overflow: 0,
cheating: 0,

total: 0

}>>

<<set $lastWeeksRepExpenses = clone($lastWeeksRepIncome)>>
<<set $lastWeeksRepProfits = clone($lastWeeksRepIncome)>>

<</widget>>


code:
:: Coursing Association [nobr]

<<set $nextButton = "Back to Main">>
<<set $nextLink = "Main">>
<<set $returnTo = "Coursing Association">>
<<showallAssignmentFilter>>

You are a member of $arcologies[0].name's Coursing Association. Coursing is a Free Cities revival of the old sport of hunting rabbits and hares with sighthounds, with the typically Free Cities amendments that the hares are replaced by newly enslaved people, the sighthounds are replaced by trained slaves, and the killing of the hare is replaced by rape. Truly, a sport of gentlemen.

The chasing slaves are known as lurchers, the term once used for the sighthounds. They require speed most of all, but must also be able to tackle their quarry; lurchers with the ability and willingness to make a spectacle of molesting the hares can improve their owners' reputations.

<<showallAssignmentFilter>>
<<if $Lurcher != 0>>
	<<= SlaveFullName($Lurcher)>> is assigned to compete as your lurcher.
<<else>>
	You have not selected a lurcher, meaning that you will not participate in coursing events.
<</if>>

//
<<= properTitle()>>, slaves assigned here can continue their usual duties.//

<<if $Lurcher != 0>>

''Fire your Lurcher:''
	<<set $Flag = 1>>
	<<include "Slave Summary">>
<</if>>

''Select a slave to course as a Lurcher:''

<<assignmentFilter>>

	<<set $Flag = 0>>
	<<showallAssignmentFilter>>
	<<include "Slave Summary">>
	<<resetAssignmentFilter>>