:: Generate XX Slave [nobr]

<<BaseSlave>>
/*missed variables - getting tired of this shit */
<<set $activeSlave.vaginaLube = 1, $activeSlave.ovaries = 1, $activeSlave.canRecruit = 1>>

<<if $activeSlaveOneTimeMaxAge > 998>>
	<<if $pedo_mode == 1>>
		<<set $activeSlaveOneTimeMaxAge = 18>>
	<<else>>
		<<set $activeSlaveOneTimeMaxAge = 42>>
	<</if>>
<<elseif $pedo_mode == 1 && $one_time_age_overrides_pedo_mode == 0 && $activeSlaveOneTimeMaxAge > 18>>
	<<set $activeSlaveOneTimeMaxAge = 18>>
<</if>>
<<if $retirementAge < $activeSlaveOneTimeMaxAge>>
	<<set $activeSlaveOneTimeMaxAge = ($retirementAge-1)>>
<</if>>
<<if $activeSlaveOneTimeMinAge < $minimumSlaveAge>>
	<<set $activeSlaveOneTimeMinAge = $minimumSlaveAge>>
<<elseif $pedo_mode == 1 && $one_time_age_overrides_pedo_mode == 0>>
	<<set $activeSlaveOneTimeMinAge = $minimumSlaveAge>>
<</if>>
<<if $activeSlaveOneTimeMaxAge < $activeSlaveOneTimeMinAge>>
	<<set $activeSlaveOneTimeMaxAge = $activeSlaveOneTimeMinAge>>
<</if>>
<<if ($activeSlaveOneTimeMaxAge >= 30) && ($FSMaturityPreferentialist != "unset")>>
	<<set $activeSlaveOneTimeMaxAge = ($activeSlaveOneTimeMaxAge + 10)>>
<</if>>
<<set $activeSlave.actualAge = random($activeSlaveOneTimeMinAge,$activeSlaveOneTimeMaxAge)>>
<<set $activeSlaveOneTimeMinAge = random($activeSlaveOneTimeMinAge,$activeSlaveOneTimeMaxAge)>>
<<if ($FSYouthPreferentialist != "unset") && ($FSYouthPreferentialist >= random (1, 100))>>
	<<set $activeSlave.actualAge = Math.min($activeSlave.actualAge, $activeSlaveOneTimeMinAge)>>
<<elseif ($FSMaturityPreferentialist != "unset") && ($FSMaturityPreferentialist >= random (1, 100))>>
	<<set $activeSlave.actualAge = Math.max($activeSlave.actualAge, $activeSlaveOneTimeMaxAge)>>
<</if>>
<<if $activeSlave.actualAge >= $retirementAge>>
	<<set $activeSlave.actualAge = ($retirementAge-2)>>
<</if>>
<<set $activeSlaveOneTimeMinAge = 0>>
<<set $activeSlaveOneTimeMaxAge = 999>>
<<set $one_time_age_overrides_pedo_mode = 0>>
<<set $activeSlave.visualAge = $activeSlave.actualAge>>
<<set $activeSlave.physicalAge = $activeSlave.actualAge>>
<<set $activeSlave.ovaryAge = $activeSlave.actualAge>>
<<set $activeSlave.age = $activeSlave.actualAge>> /*compatibility*/
<<set $activeSlave.pubertyAgeXX = $fertilityAge>>
<<if $activeSlave.ovaries == 1>>
	<<if $activeSlave.physicalAge >= $activeSlave.pubertyAgeXX>>
		<<set $activeSlave.pubertyXX = 1>>
	<<else>>
		<<set $activeSlave.pubertyXX = 0>>
	<</if>>
<<else>>
	<<set $activeSlave.pubertyXX = 0>>
<</if>>
<<set $activeSlave.pubertyAgeXY = $potencyAge>>
<<if $activeSlave.balls > 0>>
	<<if $activeSlave.physicalAge >= $activeSlave.pubertyAgeXY>>
		<<set $activeSlave.pubertyXY = 1>>
	<<else>>
		<<set $activeSlave.pubertyXY = 0>>
	<</if>>
<<else>>
	<<set $activeSlave.pubertyXY = 0>>
<</if>>

<<set $activeSlave.ID = $IDNumber++>>
<<set $activeSlave.weekAcquired = $week>>

<<set $seed = random(1,100)>>
<<if $seed > 98>>
	<<set $activeSlave.intelligence = 3>>
<<elseif $seed > 85>>
	<<set $activeSlave.intelligence = 2>>
<<elseif $seed > 65>>
	<<set $activeSlave.intelligence = 1>>
<<elseif $seed > 35>>
	<<set $activeSlave.intelligence = 0>>
<<elseif $seed > 15>>
	<<set $activeSlave.intelligence = -1>>
<<elseif $seed > 5>>
	<<set $activeSlave.intelligence = -2>>
<<else>>
	<<set $activeSlave.intelligence = -3>>
<</if>>
<<if random(1,100) < 50+(20*$activeSlave.intelligence)>>
	<<set $activeSlave.intelligenceImplant = 1>>
<</if>>

<<if $AgePenalty == 1>>
	<<if ($activeSlave.actualAge < 16)>>
		<<set $activeSlave.career = setup.veryYoungCareers.random()>>
	<<elseif ($activeSlave.actualAge <= 24)>>
		<<set $activeSlave.career = setup.youngCareers.random()>>
	<<elseif ($activeSlave.intelligenceImplant == 1)>>
		<<set $activeSlave.career = setup.educatedCareers.random()>>
	<<else>>
		<<set $activeSlave.career = setup.uneducatedCareers.random()>>
	<</if>>
<<else>>
	<<if ($activeSlave.actualAge < 16)>>
		<<set $activeSlave.career = setup.veryYoungCareers.random()>>
	<<elseif ($activeSlave.intelligenceImplant == 1)>>
		<<set $activeSlave.career = setup.educatedCareers.random()>>
	<<elseif ($activeSlave.actualAge <= 24)>>
		<<set $activeSlave.career = setup.youngCareers.random()>>
	<<else>>
		<<set $activeSlave.career = setup.uneducatedCareers.random()>>
	<</if>>
<</if>>

<<set $activeSlave.vaginalSkill = random(0,15)>>
<<set $activeSlave.analSkill = random(0,15)>>
<<set $activeSlave.oralSkill = random(0,15)>>
<<set $activeSlave.entertainSkill = random(0,15)>>
<<set $activeSlave.whoreSkill = random(0,15)>>

<<set $activeSlave.energy = random(1,85)>>
<<RandomizeAttraction>>
<<set $activeSlave.fetishStrength = random(0,90)>>
<<set $activeSlave.fetish = either("none", "none", "none", "none", "none", "none", "none", "none", "none", "none", "none", "none", "none", "submissive", "submissive", "cumslut", "humiliation", "humiliation", "buttslut", "boobs", "pregnancy", "dom", "sadist", "masochist")>>

<<set $activeSlave.behavioralFlaw = either("none", "none", "none", "arrogant", "bitchy", "odd", "hates men", "hates women", "hates women", "anorexic", "gluttonous", "devout", "liberated")>>
<<if ($activeSlave.behavioralFlaw is "devout")>>
	<<set $activeSlave.sexualFlaw = either("none", "repressed",  "shamefast", "apathetic", "crude", "judgemental")>>
<<else>>
	<<set $activeSlave.sexualFlaw = either("none", "none", "none", "none", "hates oral", "hates anal", "hates penetration", "repressed", "idealistic", "shamefast", "apathetic", "crude", "judgemental")>>
<</if>>
<<if ($activeSlave.behavioralFlaw == "none") && random(1,10) == 1>>
	<<set $activeSlave.behavioralQuirk = either("confident", "cutting", "funny", "adores women", "adores men", "fitness", "insecure", "sinful", "advocate")>>
<</if>>
<<if ($activeSlave.sexualFlaw == "none") && random(1,10) == 1>>
	<<set $activeSlave.sexualQuirk = either("gagfuck queen", "painal queen", "strugglefuck queen", "tease", "romantic", "perverted", "caring", "unflinching", "size queen")>>
<</if>>

<<set $activeSlave.health = random(-50,50)>>

<<set $activeSlave.devotion = random(-90,-60)>>
<<set $activeSlave.trust = random(-45,-25)>>

/% Begin height replacement section. %/
/% Since we use nationality for height effects we need to initialize it now instead of later on like in vanilla Free Cities. %/
<<if $fixedNationality == 0>>
	<<set $activeSlave.nationality = $nationalities.random()>>
<<else>>
	<<set $activeSlave.nationality = $fixedNationality>>
<</if>>
<<NationalityToRace $activeSlave>>
/* Corporate slavegen with race selection */
<<if passage() == "Corporate Market" && ($captureUpgradeRace != "unselected") && ($captureUpgradeRace != "none")>> 
	<<if $captureUpgradeRace == "mixed race">>
		<<set $activeSlave.race = "mixed race">>
	<<else>>
		<<set _capUpgradeCheck = setup[$captureUpgradeRace.toLowerCase().replace(/[ -]/g, '')+'Nationalities']>>
		<<set _capUpgradeNationalities = []>>
		<<for _u = 0; _u < _capUpgradeCheck.length; _u++>>
			<<set _capNation = _capUpgradeCheck[_u]>>
			<<if $nationalities.includes(_capNation)>>
				<<set _capUpgradeNationalities.push(_capNation)>>
			<</if>>
		<</for>>
		<<if _capUpgradeNationalities.length > 0>>
			<<set $activeSlave.nationality = _capUpgradeNationalities.random(), $activeSlave.race = $captureUpgradeRace>>
		<<else>>
			<<set $activeSlave.nationality = _capUpgradeCheck.random(), $activeSlave.race = $captureUpgradeRace>>
		<</if>>
	<</if>>
	<<if $activeSlave.race != $captureUpgradeRace>>
		<<set $activeSlave.race = $captureUpgradeRace>>
	<</if>>
<</if>>
/*end Corporate slavegen with race selection */
<<NationalityToName $activeSlave>>
<<NationalityToAccent $activeSlave>>

<<set $activeSlave.height = Math.round(Height.random($activeSlave))>>

<<if $activeSlave.height >= Height.mean($activeSlave) * 170/162.5>>
	<<set $activeSlave.hips = either(-1, 0, 0, 1, 1, 2, 2)>>
	<<set $activeSlave.shoulders = either(-1, -1, 0, 0, 0, 1)>>
<<else>>
	<<set $activeSlave.hips = either(-1, 0, 0, 0, 1, 1, 2)>>
	<<set $activeSlave.shoulders = either(-2, -1, -1, 0, 0, 1)>>
<</if>>
/% End height replacement section. %/

<<set $activeSlave.weight = random(-100,180)>>
<<if ($activeSlave.weight < -30)>>
	<<set $activeSlave.waist = random(-55,0)>>
<<elseif ($activeSlave.weight <= 30)>>
	<<set $activeSlave.waist = random(-45,45)>>
<<elseif $activeSlave.physicalAge < 13>>
	<<set $activeSlave.waist = random(-25,25)>>
<<elseif ($activeSlave.weight <= 160)>>
	<<set $activeSlave.waist = random(0,55)>>
<<else>>
	<<set $activeSlave.waist = random(50,100)>>
<</if>>

<<if ($activeSlave.physicalAge > random(0,100))>>
	<<set $activeSlave.eyes = -1>>
	<<if random(0,100) > 90>>
		<<set $activeSlave.eyes = -2>>
	<</if>>
<</if>>


<<if ($activeSlave.intelligenceImplant == 1) && ($activeSlave.accent >= 3) && (3+$activeSlave.intelligence) > random(0, 6)>>
	<<set $activeSlave.accent -= 1>>
<</if>>

<<set $seed = 4+$activeSlave.intelligence+$activeSlave.intelligenceImplant>>
<<if "American" == $activeSlave.nationality>>
	<<set $seed += 2>>
<<elseif ["Canadian", "Israeli", "Japanese", "Korean", "Irish", "Icelandic", "Finnish", "Swiss", "Danish", "Norwegian", "Austrian", "Slovak", "Dutch", "Belgian", "Czech", "Portuguese", "Hungarian", "Portuguese", "Estonian", "Polish", "Lithuanian", "Romanian", "German", "Swedish", "French", "Italian", "Spanish", "British", "Australian", "a New Zealander"].includes($activeSlave.nationality)>>
<<else>>
	<<set $seed -= 2>>
<</if>>
<<if random(1,$seed) == 1>>
	<<set $activeSlave.teeth = "crooked">>
<</if>>

<<switch $activeSlave.race>>
<<case "black">>
	<<set $activeSlave.butt = either(1, 2, 2, 3, 3, 4, 4)>>
	<<set $activeSlave.boobs = BoobGenerator.rollBreast(150)>>
	<<set $activeSlave.lips = random(5,30)>>
	<<set $activeSlave.skin = either("black", "brown", "light brown")>>
	<<set $activeSlave.hColor = either("black", "black", "black", "brown")>>
	<<set $activeSlave.hStyle = either("neat", "crinkled")>>
<<case "white">>
	<<set $activeSlave.butt = either(1, 2, 2, 3, 3, 4)>>
	<<set $activeSlave.boobs = BoobGenerator.rollBreast(50)>>
	<<set $activeSlave.lips = random(5,25)>>
	<<if $activeSlave.nationality == "German">>
		<<set $activeSlave.skin = either("pale", "tanned", "fair")>>
		<<set $activeSlave.eyeColor = either("blue", "blue", "blue", "brown", "green")>>
		<<set $activeSlave.hColor = either("black", "blonde", "blonde", "blonde", "red", "brown")>>
	<<elseif $activeSlave.nationality == "Icelandic">>
		<<set $activeSlave.skin = either("pale", "pale", "tanned", "fair")>>
		<<set $activeSlave.eyeColor = either("blue", "blue", "blue", "brown", "green")>>
		<<set $activeSlave.hColor = either("black", "blonde", "blonde", "blonde", "red", "brown")>>
	<<elseif $activeSlave.nationality == "Irish">>
		<<set $activeSlave.skin = either("pale", "pale", "tanned", "fair")>>
		<<set $activeSlave.eyeColor = either("blue", "brown", "green", "green", "green")>>
		<<set $activeSlave.hColor = either("black", "blonde", "red", "red", "red", "brown")>>
	<<elseif $activeSlave.nationality == "Scottish">>
		<<set $activeSlave.skin = either("pale", "fair", "tanned", "fair")>>
		<<set $activeSlave.eyeColor = either("blue", "brown", "brown", "green", "green", "green")>>
		<<set $activeSlave.hColor = either("black", "black", "blonde", "red", "red", "red", "brown")>>
	<<else>>
		<<set $activeSlave.skin = either("pale", "tanned", "fair")>>
		<<set $activeSlave.eyeColor = either("blue", "brown", "green")>>
		<<set $activeSlave.hColor = either("black", "blonde", "red", "brown")>>
	<</if>>
	<<set $activeSlave.hStyle = "neat">>
<<case "latina">>
	<<set $activeSlave.butt = either(1, 2, 2, 3, 3, 4)>>
	<<set $activeSlave.boobs = BoobGenerator.rollBreast(0)>>
	<<set $activeSlave.lips = random(5,25)>>
	<<set $activeSlave.skin = either("olive", "brown", "light brown")>>
	<<set $activeSlave.hColor = either("black", "black", "brown", "brown")>>
	<<set $activeSlave.hStyle = "neat">>
<<case "indo-aryan" "malay" "pacific islander" "amerindian">>
	<<set $activeSlave.butt = either(1, 2, 2, 3, 3)>>
	<<set $activeSlave.boobs = BoobGenerator.rollBreast(0)>>
	<<set $activeSlave.lips = random(5,25)>>
	<<set $activeSlave.skin = either("dark", "light")>>
	<<set $activeSlave.hColor = either("black")>>
	<<set $activeSlave.hStyle = "neat">>
<<case "asian">>
	<<set $activeSlave.butt = either(1, 2, 2, 3, 3)>>
	<<set $activeSlave.boobs = BoobGenerator.rollBreast(-100)>>
	<<set $activeSlave.lips = random(5,25)>>
	<<set $activeSlave.skin = either("pale", "dark", "light")>>
	<<set $activeSlave.hColor = either("black")>>
	<<set $activeSlave.hStyle = "neat">>
<<case "middle eastern" "semitic" "southern european">>
	<<set $activeSlave.butt = either(1, 2, 2, 3, 3)>>
	<<set $activeSlave.boobs = BoobGenerator.rollBreast(0)>>
	<<set $activeSlave.lips = random(5,25)>>
	<<set $activeSlave.skin = either("pale", "dark", "light")>>
	<<set $activeSlave.hColor = either("black")>>
	<<set $activeSlave.hStyle = "neat">>
<<default>>
	<<set $activeSlave.butt = either(1, 2, 2, 3, 3, 4)>>
	<<set $activeSlave.boobs = BoobGenerator.rollBreast(0)>>
	<<set $activeSlave.lips = random(5,25)>>
	<<set $activeSlave.skin = either("pale", "dark", "light")>>
	<<set $activeSlave.hColor = either("black", "black", "black", "black", "brown", "brown", "blonde", "red")>>
	<<set $activeSlave.hStyle = "neat">>
<</switch>>
<<if ($activeSlave.skin == "pale") || ($activeSlave.skin == "fair")>>
	<<if random(1,4) == 1>>
	<<set $activeSlave.markings = either("freckles", "freckles", "freckles", "heavily freckled", "beauty mark", "beauty mark", "birthmark", "birthmark")>>
	<</if>>
<<elseif random(1,8) == 1>>
	<<set $activeSlave.markings = either("beauty mark", "birthmark")>>
<</if>>

<<set $activeSlave.origEye = $activeSlave.eyeColor>>
<<set $activeSlave.origHColor = $activeSlave.hColor>>
<<set $activeSlave.origSkin = $activeSlave.skin>>
<<set $activeSlave.pubicHColor = $activeSlave.hColor>>
<<set $activeSlave.pubicHStyle = either("hairless", "bald", "bald", "waxed", "waxed", "waxed", "waxed", "waxed", "waxed", "in a strip", "in a strip", "in a strip", "in a strip", "in a strip", "neat", "neat", "neat", "neat", "neat", "bushy in the front and neat in the rear", "bushy in the front and neat in the rear", "bushy in the front and neat in the rear", "bushy in the front and neat in the rear", "bushy", "bushy", "bushy", "bushy", "bushy")>>
<<set $activeSlave.underArmHColor = $activeSlave.hColor>>
<<set $activeSlave.underArmHStyle = either("hairless", "bald", "bald", "waxed", "waxed", "waxed", "waxed", "shaved", "shaved", "shaved", "shaved", "shaved", "neat", "neat", "neat", "neat", "neat", "bushy", "bushy", "bushy")>>
<<if ($activeSlave.pubicHStyle == "hairless" || $activeSlave.underArmHStyle == "hairless") && random(1,100) > 40>>
	<<set $activeSlave.pubicHStyle = "hairless", $activeSlave.underArmHStyle = "hairless">>
<</if>>

/*LM*/
<<if ($activeSlave.physicalAge <= 10)>>
	<<set $activeSlave.boobs = either(100)>>
<<elseif ($activeSlave.physicalAge == 11)>>
	<<set $activeSlave.boobs = either(100, 100, 150, 150, 150, 300)>>
<<elseif ($activeSlave.physicalAge == 12)>>
	<<set $activeSlave.boobs = either(100, 100, 150, 150, 150, 200, 200, 300)>>
<<elseif ($activeSlave.physicalAge == 13)>>
	<<set $activeSlave.boobs = either(100, 150, 200, 200, 300, 300, 300, 400)>>
<<elseif ($activeSlave.physicalAge == 14)>>
	<<set $activeSlave.boobs = either(100 ,150, 200, 300, 300, 300, 350, 400, 400)>>
<<elseif ($activeSlave.physicalAge == 15)>>
	<<set $activeSlave.boobs = either(150 ,200, 300, 300, 300, 350, 350, 350, 400, 400, 450, 450)>>
<</if>>

<<if ($activeSlave.physicalAge <= 11)>>
	<<set $activeSlave.butt = either(1, 1, 1, 1, 1, 1, 1)>>
<<elseif ($activeSlave.physicalAge <= 12)>>
	<<set $activeSlave.butt = either(1, 1, 1, 1, 1, 2, 2)>>
<<elseif ($activeSlave.physicalAge <= 13)>>
	<<set $activeSlave.butt = either(1, 1, 1, 1, 2, 2, 2)>>
<<elseif ($activeSlave.physicalAge <= 14)>>
	<<set $activeSlave.butt = either(1, 1, 1, 2, 2, 2, 3)>>
<<elseif ($activeSlave.physicalAge <= 15)>>
	<<set $activeSlave.butt = either(1, 1, 2, 2, 2, 2, 3)>>
<</if>>
/*end LM*/

<<if ($weightAffectsAssets != 0)>>
	<<if $activeSlave.weight < -10 && $activeSlave.butt > 1>>
		<<set $activeSlave.butt -= 1>>
	<<elseif $activeSlave.weight > 100 && $activeSlave.butt < 6>>
		<<set $activeSlave.butt += random(1,2)>>
	<<elseif $activeSlave.weight > 10 && $activeSlave.butt < 4>>
		<<set $activeSlave.butt += 1>>
	<</if>>

	<<if $activeSlave.weight < -10 && $activeSlave.boobs > 200>>
		<<set $activeSlave.boobs -= 100>>
	<<elseif $activeSlave.weight > 190 && $activeSlave.boobs < 3000>>
		<<set $activeSlave.boobs += (random(3,8)*100)>>
	<<elseif $activeSlave.weight > 160 && $activeSlave.boobs < 1500>>
		<<set $activeSlave.boobs += (random(2,6)*100)>>
	<<elseif $activeSlave.weight > 130 && $activeSlave.boobs < 1500>>
		<<set $activeSlave.boobs += (random(1,4)*100)>>
	<<elseif $activeSlave.weight > 95 && $activeSlave.boobs < 1200>>
		<<set $activeSlave.boobs += (random(1,3)*100)>>
	<<elseif $activeSlave.weight > 30 && $activeSlave.boobs < 1000>>
		<<set $activeSlave.boobs += 100>>
	<</if>>
<</if>>

<<set $seed = []>>
<<if $activeSlave.boobs > 250 && $activeSlave.boobs < 800>>
	<<set $seed.push("perky")>>
	<<set $seed.push("downward-facing")>>
<</if>>
<<if $activeSlave.boobs > 400 && $activeSlave.boobs < 1200>>
	<<set $seed.push("torpedo-shaped")>>
	<<set $seed.push("wide-set")>>
<</if>>
<<if $activeSlave.boobs > 800 && $activeSlave.physicalAge > random(10,50)>>
	<<set $seed.push("saggy")>>
<</if>>
<<if $seed.length == 1>>
	<<if random(1,2) != 1>>
	<<set $activeSlave.boobShape = $seed.random()>>
	<</if>>
<<elseif $seed.length > 1>>
	<<if random(1,3) != 1>>
	<<set $activeSlave.boobShape = $seed.random()>>
	<</if>>
<</if>>

<<set $activeSlave.earPiercing = either(0,1)>>
<<set $activeSlave.nosePiercing = either(0,0,0,1)>>
<<set $activeSlave.eyebrowPiercing = either(0,0,0,0,0,1)>>
<<set $activeSlave.clitPiercing = either(0,0,0,0,0,1)>>
<<set $activeSlave.lipsPiercing = either(0,0,0,0,0,1)>>
<<set $activeSlave.navelPiercing = either(0,0,0,1)>>
<<set $activeSlave.nipplesPiercing = either(0,0,0,1)>>

<<set $activeSlave.face = random(-60,60)>>
<<if random(0,2) == 1>><<set $activeSlave.face = random(-10,10)>><</if>>
<<if $activeSlave.physicalAge > 40>>
	<<set $activeSlave.face -= random(0,20)>>
<<elseif $activeSlave.physicalAge > 35>>
	<<set $activeSlave.face -= random(0,10)>>
<<elseif $activeSlave.physicalAge <= 20>>
	<<set $activeSlave.face += random(0,20)>>
<<elseif $activeSlave.physicalAge <= 25>>
	<<set $activeSlave.face += random(0,10)>>
<</if>>
<<if $activeSlave.physicalAge > 10>>
	<<set $activeSlave.faceShape = either("androgynous", "cute", "sensual", "exotic", "normal", "normal")>>
<<else>>
	<<set $activeSlave.faceShape = either("androgynous", "androgynous", "cute", "cute", "sensual", "exotic", "normal", "normal")>>
<</if>>
<<switch $activeSlave.faceShape>>
<<case "sensual" "cute">>
	<<set $activeSlave.face += random(0,20)>>
<<case "exotic" "androgynous">>
	<<set $activeSlave.face += random(-10,10)>>
<<case "masculine">>
	<<set $activeSlave.face += random(-10,0)>>
<</switch>>

<<if $activeSlave.boobs < 250>>
	<<set $activeSlave.nipples = either("tiny", "tiny", "tiny", "tiny", "cute", "cute", "puffy", "partially inverted")>>
<<elseif $activeSlave.boobs < 500>>
	<<set $activeSlave.nipples = either("tiny", "cute", "cute", "cute", "puffy", "partially inverted")>>
<<elseif $activeSlave.boobs < 1000>>
	<<set $activeSlave.nipples = either("tiny", "cute", "cute", "cute", "puffy", "puffy", "partially inverted", "inverted")>>
<<else>>
	<<set $activeSlave.nipples = either("cute", "puffy", "partially inverted", "inverted", "huge")>>
<</if>>

<<set $activeSlave.vagina = either(0, 0, 1, 1, 1)>>
<<if $activeSlave.actualAge < 20>>
	<<set $activeSlave.vagina = either(0, 1)>>
<</if>>
<<if $activeSlave.actualAge > 30>>
	<<set $activeSlave.vagina = either(1, 1, 1, 1, 2)>>
<</if>>
<<if $activeSlave.vagina == 0>>
	<<set $activeSlave.vaginalSkill = 0>>
<</if>>
<<if $activeSlave.energy < random(1,80)>>
	<<set $activeSlave.vaginaLube = 0>>
<<elseif $activeSlave.physicalAge > random(35,60)>>
	<<set $activeSlave.vaginaLube = 0>>
<</if>>

<<set $activeSlave.clit = either(0, 0, 0, 0, 0, 0, 1, 1, 2)>>
<<set $activeSlave.labia = either(0, 0, 0, 1, 1, 1, 1, 2, 2, 3)>>
<<set $activeSlave.foreskin = random(0,4)>>

<<set $activeSlave.voice = either(1, 2, 2, 2, 2, 2, 2, 3, 3, 3)>>

<<set $activeSlave.anus = either(0, 0, 1, 1, 2)>>
<<set $activeSlave.analArea = $activeSlave.anus + either(0, 0, 0, 1)>>

<<if $activeSlave.anus == 0>>
	<<set $activeSlave.analSkill = 0>>
<<elseif random(1,4) == 1>>
	<<set $activeSlave.anusTat = "bleached">>
<</if>>

/%pedoshit%/
<<if $activeSlave.physicalAge <= 11>>
  <<set $activeSlave.hips = either(-2, -2, -1, -1, 0)>>
<<elseif $activeSlave.physicalAge <= 13>>
  <<set $activeSlave.hips = either(-2, -1, -1, 0, 1)>>
<</if>>
<<if $activeSlave.physicalAge <= 13>>
	<<set $activeSlave.vagina = either(0, 0, 0, 0, 0, 0, 0, 1)>>
<<elseif $activeSlave.physicalAge <= 15>>
	<<set $activeSlave.vagina = either(0, 0, 0, 0, 0, 1, 1)>>
<<elseif $activeSlave.physicalAge <= 17>>
	<<set $activeSlave.vagina = either(0, 0, 0, 1, 1, 1)>>
<</if>>

<<if $activeSlave.vagina == 0>>
	<<set $activeSlave.vaginalSkill = 0>>
<</if>>

<<if ($activeSlave.physicalAge <= 11)>>
	<<set $activeSlave.clit = either(0, 0, 0, 0, 0, 0, 0, 0, 1)>>
<<elseif ($activeSlave.physicalAge <= 13)>>
	<<set $activeSlave.clit = either(0, 0, 0, 0, 0, 0, 0, 1, 1)>>
<<elseif ($activeSlave.physicalAge <= 15)>>
	<<set $activeSlave.clit = either(0, 0, 0, 0, 0, 0, 0, 1, 2)>>
<</if>>

<<if ($activeSlave.physicalAge <= 11)>>
	<<set $activeSlave.labia = either(0, 0, 0, 0, 0, 0, 0, 1, 1)>>
<<elseif ($activeSlave.physicalAge <= 12)>>
	<<set $activeSlave.labia = either(0, 0, 0, 0, 0, 0, 1, 1, 1)>>
<<elseif ($activeSlave.physicalAge <= 13)>>
	<<set $activeSlave.labia = either(0, 0, 0, 0, 0, 1, 1, 1, 1)>>
<<elseif ($activeSlave.physicalAge <= 14)>>
	<<set $activeSlave.labia = either(0, 0, 0, 0, 1, 1, 1, 1, 2)>>
<<elseif ($activeSlave.physicalAge <= 15)>>
	<<set $activeSlave.labia = either(0, 0, 0, 1, 1, 1, 1, 2, 2)>>
<</if>>

<<if ($activeSlave.physicalAge <= 13)>>
	<<set $activeSlave.voice = either(2, 2, 2, 3, 3, 3, 3, 3, 3)>>
<<elseif ($activeSlave.physicalAge <= 16)>>
	<<set $activeSlave.voice = either(2, 2, 2, 2, 2, 3, 3, 3, 3)>>
<</if>>

<<if passage() == "Slave Markets" && $slaveMarket == "corporate">>
	<<if ($captureUpgradeRace != "unselected") && ($captureUpgradeRace != "none")>>
	<<if $activeSlave.race != $captureUpgradeRace>>
        <<set $slaveMarket = "corporate">>
        <<goto "Slave Markets">>
	<</if>>
	<</if>>
<</if>>
