:: attackReport [nobr]

<<set $nextButton = "Continue", $nextLink = "Scheduled Event", $encyclopedia = "Battles">>

/*init*/
<<set _oldRep = $rep>>
<<set _oldAuth = $SecExp.core.authority>>
<<set $enemyLosses = Math.trunc($enemyLosses)>>
<<if $enemyLosses > $attackTroops>>
	<<set $enemyLosses = $attackTroops>>
<</if>>
<<set $totalKills += $enemyLosses>>
<<set $losses = Math.trunc($losses)>>
<<set _loot = 0>>

/* result */
<<if $majorBattle == 0>>
	<<set $battlesCount++>>
	<<set _majorBattleMod = 1>>
	<<if $battleResult == 3>>
		<strong>Victory!</strong>
		<<set $PClossStreak = 0>>
		<<set $PCvictoryStreak += 1>>
		<<set $PCvictories++>>
	<<elseif $battleResult == -3>>
		<strong>Defeat!</strong>
		<<set $PClossStreak += 1>>
		<<set $PCvictoryStreak = 0>>
		<<set $PClosses++>>
	<<elseif $battleResult == 2>>
		<strong>Partial victory!</strong>
		<<set $PCvictories++>>
	<<elseif $battleResult == -2>>
		<strong>Partial defeat!</strong>
		<<set $PClosses++>>
	<<elseif $battleResult == -1>>
		<strong>We surrendered</strong>
		<<set $PClosses++>>
	<<elseif $battleResult == 0>>
		<strong>Failed bribery!</strong>
		<<set $PClosses++>>
	<<elseif $battleResult == 1>>
		<strong>Successful bribery!</strong>
		<<set $PCvictories++>>
	<</if>>
<<else>>
	<<set _majorBattleMod = 2>>
	<<set $battlesCount++>>
	<<set $majorBattlesCount++>>
	<<if $battleResult == 3>>
		<strong>Major victory!</strong>
		<<set $PClossStreak = 0>>
		<<set $PCvictoryStreak += 1>>
		<<set $PCvictories++>>
	<<elseif $battleResult == -3>>
		<strong>Major Defeat!</strong>
		<<set $PClossStreak += 1>>
		<<set $PCvictoryStreak = 0>>
		<<set $PClosses++>>
	<<elseif $battleResult == 2>>
		<strong>Partial victory!</strong>
		<<set $PCvictories++>>
	<<elseif $battleResult == -2>>
		<strong>Partial defeat!</strong>
		<<set $PClosses++>>
	<<elseif $battleResult == -1>>
		<strong>We surrendered</strong>
		<<set $PClosses++>>
	<<elseif $battleResult == 0>>
		<strong>Failed bribery!</strong>
		<<set $PClosses++>>
	<<elseif $battleResult == 1>>
		<strong>Successful bribery!</strong>
		<<set $PCvictories++>>
	<</if>>
<</if>>
<hr>

<<if $attackType == "raiders">>
	Today, <<= asDateString($week, random(0,7))>>, our arcology was attacked by a band of wild raiders, <<print num(Math.trunc($attackTroops))>> men strong.
	<<if $battleResult != 1 && $battleResult != 0 && $battleResult != -1>>
		Our defense forces, <<print num(Math.trunc(App.SecExp.conflict.troopCount()))>> strong, clashed with them
		<<if $battleTerrain == "urban">>
			in the streets of <<if $terrain == "urban">>the old world city surrounding the arcology<<else>>of the free city<</if>>,
			<<elseif $battleTerrain == "rural">>
			in the rural land surrounding the free city,
		<<elseif $battleTerrain == "hills">>
			on the hills around the free city,
		<<elseif $battleTerrain == "coast">>
			along the coast just outside the free city,
			<<elseif $battleTerrain == "outskirts">>
			just against the walls of the arcology,
		<<elseif $battleTerrain == "mountains">>
			in the mountains overlooking the arcology,
		<<elseif $battleTerrain == "wasteland">>
			in the wastelands outside the free city territory,
		<</if>>
		<<if $enemyLosses != $attackTroops>>
			inflicting <<print num(Math.trunc($enemyLosses))>> casualties, while sustaining <<if $losses > 1>><<print num(Math.trunc($losses))>> casualties<<elseif $losses > 0>>a casualty<<else>>zero<</if>> themselves.
		<<else>>
			completely annihilating their troops, while sustaining <<if $losses > 1>><<print num(Math.trunc($losses))>> casualties<<elseif $losses > 0>>a casualty<<else>>zero casualties<</if>>.
		<</if>>
	<</if>>
	<<if $battleResult == 3>>
		<<if $battleTurns <= 5>>
			The fight was quick and one sided, our men easily stopped the disorganized horde's futile attempt at raiding your arcology<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<elseif $battleTurns <= 7>>
			The fight was hard, but in the end our men stopped the disorganized horde attempt at raiding your arcology<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<else>>
			The fight was long and hard, but our men managed to stop the horde raiding party<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<</if>>
		<<if $PCvictoryStreak >= 2>>
			adding another victory to the growing list of our military's successes.
		<<elseif $PClossStreak >= 2>>
			finally putting an end to a series of unfortunate defeats.
		<</if>>
	<<elseif $battleResult == -3>>
		<<if $battleTurns <= 5>>
			The fight was quick and one sided, our men were easily crushed by the barbaric horde of raiders<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<elseif $battleTurns <= 7>>
			The fight was hard and in the end the bandits proved too much to handle for our men<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<else>>
			The fight was long and hard, but despite their bravery the horde proved too much for our men<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<</if>>
		<<if $PCvictoryStreak >= 2>>
			so interrupting a long series of military successes.
		<<elseif $PClossStreak >= 2>>
			confirming the long list of recent failures our armed forces collected.
		<</if>>
	<<elseif $battleResult == 2>>
		The fight was long and hard, but in the end our men managed to repel the raiders, though not without difficulty.
	<<elseif $battleResult == -2>>
		The fight was long and hard. Our men in the end had to yield to the horde raiders, which was fortunately unable to capitalized on their victory.
	<<elseif $battleResult == -1>>
		You gave your troops the order to surrender, obediently they stand down.
	<<elseif $battleResult == 0>>
		You decided in favor of a financial approach rather than open hostilities. Your troops remain inside the arcology's walls.
	<<elseif $battleResult == 1>>
		You decided in favor of a financial approach rather than open hostilities. Your troops remain inside the arcology's walls.
	<</if>>
<<elseif $attackType == "free city">>
	Today, <<= asDateString($week, random(0,7))>>, our arcology was attacked by a contingent of mercenaries hired by a competing free city, <<print num(Math.trunc($attackTroops))>> men strong.
	<<if $battleResult != 1 && $battleResult != 0 && $battleResult != -1>>
		Our defense forces, <<print num(Math.trunc(App.SecExp.conflict.troopCount()))>> strong, clashed with them
		<<if $battleTerrain == "urban">>
			in the streets of <<if $terrain == "urban">>the old world city surrounding the arcology<<else>>of the free city<</if>>,
		<<elseif $battleTerrain == "rural">>
			in the rural land surrounding the free city,
		<<elseif $battleTerrain == "hills">>
			on the hills around the free city,
		<<elseif $battleTerrain == "coast">>
			along the coast just outside the free city,
		<<elseif $battleTerrain == "outskirts">>
			just against the walls of the arcology,
		<<elseif $battleTerrain == "mountains">>
			in the mountains overlooking the arcology,
		<<elseif $battleTerrain == "wasteland">>
			in the wastelands outside the free city territory,
		<</if>>
		<<if $enemyLosses != $attackTroops>>
			inflicting <<print $enemyLosses>> casualties, while sustaining <<if $losses > 1>> <<print num(Math.trunc($losses))>> casualties <<elseif $losses > 0>> a casualty <<else>> zero <</if>> themselves.
		<<else>>
			completely annihilating their troops, while sustaining <<if $losses > 1>> <<print num(Math.trunc($losses))>> casualties. <<elseif $losses > 0>> a casualty.<<else>> zero casualties.<</if>>
		<</if>>
	<</if>>
	<<if $battleResult == 3>>
		<<if $battleTurns <= 5>>
			The fight was quick and one sided, our men easily stopped the mercenaries dead in their tracks<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<elseif $battleTurns <= 7>>
			The fight was hard, but in the end our men stopped the slavers attempt at weakening your arcology<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<else>>
			The fight was long and hard, but our men managed to stop the free city mercenaries<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<</if>>
		<<if $PCvictoryStreak >= 2>>
			adding another victory to the growing list of our military's successes.
		<<elseif $PClossStreak >= 2>>
			finally putting an end to a series of unfortunate defeats.
		<</if>>
	<<elseif $battleResult == -3>>
		<<if $battleTurns <= 5>>
			The fight was quick and one sided, our men were easily crushed by the consumed mercenary veterans sent against us<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<elseif $battleTurns <= 7>>
			The fight was hard and in the end the slavers proved too much to handle for our men<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<else>>
			The fight was long and hard, but despite their bravery the mercenary slavers proved too much for our men<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<</if>>
		<<if $PCvictoryStreak >= 2>>
			so interrupting a long series of military successes.
		<<elseif $PClossStreak >= 2>>
			confirming the long list of recent failures our armed forces collected.
		<</if>>
	<<elseif $battleResult == 2>>
		The fight was long and hard, but in the end our men managed to repel the mercenaries, though not without difficulty.
	<<elseif $battleResult == -2>>
		The fight was long and hard. Our men in the end had to yield to the slavers, which were fortunately unable to capitalized on their victory.
	<<elseif $battleResult == -1>>
		You gave your troops the order to surrender, obediently they stand down.
	<<elseif $battleResult == 0>>
		You decided in favor of a financial approach rather than open hostilities. Your troops remain inside the arcology's walls.
	<<elseif $battleResult == 1>>
		You decided in favor of a financial approach rather than open hostilities. Your troops remain inside the arcology's walls.
	<</if>>
<<elseif $attackType == "freedom fighters">>
	Today, <<= asDateString($week, random(0,7))>>, our arcology was attacked by a group of freedom fighters bent on the destruction of the institution of slavery, <<print num(Math.trunc($attackTroops))>> men strong.
	<<if $battleResult != 1 && $battleResult != 0 && $battleResult != -1>>
		Our defense forces, <<print num(Math.trunc(App.SecExp.conflict.troopCount()))>> strong, clashed with them
		<<if $battleTerrain == "urban">>
			in the streets of <<if $terrain == "urban">>the old world city surrounding the arcology<<else>>of the free city<</if>>,
		<<elseif $battleTerrain == "rural">>
			in the rural land surrounding the free city,
		<<elseif $battleTerrain == "hills">>
			on the hills around the free city,
		<<elseif $battleTerrain == "coast">>
			along the coast just outside the free city,
		<<elseif $battleTerrain == "outskirts">>
			just against the walls of the arcology,
		<<elseif $battleTerrain == "mountains">>
			in the mountains overlooking the arcology,
		<<elseif $battleTerrain == "wasteland">>
			in the wastelands outside the free city territory,
		<</if>>
		<<if $enemyLosses != $attackTroops>>
			inflicting <<print $enemyLosses>> casualties, while sustaining <<if $losses > 1>> <<print num(Math.trunc($losses))>> casualties <<elseif $losses > 0>> a casualty <<else>> zero <</if>> themselves.
		<<else>>
			completely annihilating their troops, while sustaining <<if $losses > 1>> <<print num(Math.trunc($losses))>> casualties. <<elseif $losses > 0>> a casualty. <<else>> zero casualties.<</if>>
		<</if>>
	<</if>>
	<<if $battleResult == 3>>
		<<if $battleTurns <= 5>>
			The fight was quick and one sided, our men easily stopped the freedom fighters dead in their tracks<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<elseif $battleTurns <= 7>>
			The fight was hard, but in the end our men stopped the fighters attack<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<else>>
			The fight was long and hard, but our men managed to stop the freedom fighters<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<</if>>
		<<if $PCvictoryStreak >= 2>>
			adding another victory to the growing list of our military's successes.
		<<elseif $PClossStreak >= 2>>
			finally putting an end to a series of unfortunate defeats.
		<</if>>
	<<elseif $battleResult == -3>>
		<<if $battleTurns <= 5>>
			The fight was quick and one sided, our men were easily crushed by the fanatical fury of the freedom fighters<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<elseif $battleTurns <= 7>>
			The fight was hard and in the end the freedom fighters proved too much to handle for our men<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<else>>
			The fight was long and hard, but despite their bravery the freedom fighters fury proved too much for our men<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<</if>>
		<<if $PCvictoryStreak >= 2>>
			so interrupting a long series of military successes.
		<<elseif $PClossStreak >= 2>>
			confirming the long list of recent failures our armed forces collected.
		<</if>>
	<<elseif $battleResult == 2>>
			The fight was long and hard, but in the end our men managed to repel the freedom fighters, though not without difficulty.
	<<elseif $battleResult == -2>>
		The fight was long and hard. Our men in the end had to yield to the freedom fighters, which were fortunately unable to capitalized on their victory.
	<<elseif $battleResult == -1>>
		You gave your troops the order to surrender, obediently they stand down.
	<<elseif $battleResult == 0>>
		You decided in favor of a financial approach rather than open hostilities. Your troops remain inside the arcology's walls.
	<<elseif $battleResult == 1>>
		You decided in favor of a financial approach rather than open hostilities. Your troops remain inside the arcology's walls.
	<</if>>
<<elseif $attackType == "old world">>
	Today, <<= asDateString($week, random(0,7))>>, our arcology was attacked by an old world nation boasting a misplaced sense of superiority, <<print num(Math.trunc($attackTroops))>> men strong.
	<<if $battleResult != 1 && $battleResult != 0 && $battleResult != -1>>
		Our defense forces, <<print num(Math.trunc(App.SecExp.conflict.troopCount()))>> strong, clashed with them
		<<if $battleTerrain == "urban">>
			in the streets of <<if $terrain == "urban">>the old world city surrounding the arcology<<else>>of the free city<</if>>,
		<<elseif $battleTerrain == "rural">>
			in the rural land surrounding the free city,
		<<elseif $battleTerrain == "hills">>
			on the hills around the free city,
		<<elseif $battleTerrain == "coast">>
			along the coast just outside the free city,
		<<elseif $battleTerrain == "outskirts">>
			just against the walls of the arcology,
		<<elseif $battleTerrain == "mountains">>
			in the mountains overlooking the arcology,
		<<elseif $battleTerrain == "wasteland">>
			in the wastelands outside the free city territory,
		<</if>>
		<<if $enemyLosses != $attackTroops>>
			inflicting <<print $enemyLosses>> casualties, while sustaining <<if $losses > 1>> <<print num(Math.trunc($losses))>> casualties <<elseif $losses > 0>> a casualty <<else>> zero <</if>> themselves.
		<<else>>
			completely annihilating their troops, while sustaining <<if $losses > 1>> <<print num(Math.trunc($losses))>> casualties. <<elseif $losses > 0>> a casualty. <<else>> zero casualties.<</if>>
		<</if>>
	<</if>>
	<<if $battleResult == 3>>
		<<if $battleTurns <= 5>>
			The fight was quick and one sided, our men easily stopped the old world soldiers dead in their tracks<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<elseif $battleTurns <= 7>>
			The fight was hard, but in the end our men stopped the soldiers of the old world<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<else>>
			The fight was long and hard, but our men managed to stop the old world soldiers<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<</if>>
		<<if $PCvictoryStreak >= 2>>
			adding another victory to the growing list of our military's successes.
		<<elseif $PClossStreak >= 2>>
			finally putting an end to a series of unfortunate defeats.
		<</if>>
	<<elseif $battleResult == -3>>
		<<if $battleTurns <= 5>>
			The fight was quick and one sided, our men were easily crushed by the discipline of the old world armies<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<elseif $battleTurns <= 7>>
			The fight was hard and in the end the old world proved too much to handle for our men<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<<else>>
			The fight was long and hard, but despite their bravery the determination of the old world troops proved too much for our men<<if $PCvictoryStreak >= 2 || $PClossStreak >= 2>>,<<else>>.<</if>>
		<</if>>
		<<if $PCvictoryStreak >= 2>>
			so interrupting a long series of military successes.
		<<elseif $PClossStreak >= 2>>
			confirming the long list of recent failures our armed forces collected.
		<</if>>
	<<elseif $battleResult == 2>>
		The fight was long and hard, but in the end our men managed to repel the old world soldiers, though not without difficulty.
	<<elseif $battleResult == -2>>
		The fight was long and hard. Our men in the end had to yield to the old world soldiers, which were fortunately unable to capitalized on their victory.
	<<elseif $battleResult == -1>>
		You gave your troops the order to surrender, obediently they stand down.
	<<elseif $battleResult == 0>>
		You decided in favor of a financial approach rather than open hostilities. Your troops remain inside the arcology's walls.
	<<elseif $battleResult == 1>>
		You decided in favor of a financial approach rather than open hostilities. Your troops remain inside the arcology's walls.
	<</if>>
<</if>>
<br><br>
/* calculates effects on the city */
<<if $battleResult == 3>>
	Thanks to your victory, your @@.green;reputation@@ and @@.darkviolet;authority@@ increased. You were also able to capture
	<<if $attackType == "raiders">>
		<<run repX(4000 * _majorBattleMod, "war")>>
		<<set $SecExp.core.authority += 800 * _majorBattleMod>>
	<<elseif $attackType == "free city">>
		<<run repX(6000 * _majorBattleMod, "war")>>
		<<set $SecExp.core.authority += 1200 * _majorBattleMod>>
	<<elseif $attackType == "freedom fighters">>
		<<run repX(7500 * _majorBattleMod, "war")>>
		<<set $SecExp.core.authority += 1500 * _majorBattleMod>>
	<<elseif $attackType == "old world">>
		<<run repX(6000 * _majorBattleMod, "war")>>
		<<set $SecExp.core.authority += 1200 * _majorBattleMod>>
	<</if>>
	<<if $attackTroops - $enemyLosses <= 50>>
		a small amount of attackers,
		<<set _captives = ($attackTroops - $enemyLosses) * 0.1 * random(1,3)>>
	<<elseif $attackTroops - $enemyLosses <= 100>>
		an healthy group of attackers,
		<<set _captives = ($attackTroops - $enemyLosses) * 0.1 * random(1,3)>>
	<<elseif $attackTroops - $enemyLosses <= 150>>
		a big group of attackers,
		<<set _captives = ($attackTroops - $enemyLosses) * 0.1 * random(1,3)>>
	<<elseif $attackTroops - $enemyLosses <= 200>>
		a huge group of attackers,
		<<set _captives = ($attackTroops - $enemyLosses) * 0.1 * random(1,3)>>
	<<elseif $attackTroops - $enemyLosses > 200>>
		a great amount of attackers,
		<<set _captives = ($attackTroops - $enemyLosses) * 0.1 * random(1,3)>>
	<</if>>
	and some of their equipment, which once sold produced
	<<if $attackEquip == 0>>
		@@.yellowgreen;a small amount of cash.@@
		<<set _loot += 1000 * _majorBattleMod>>
	<<elseif $attackEquip == 1>>
		@@.yellowgreen;a moderate amount of cash.@@
		<<set _loot += 5000 * _majorBattleMod>>
	<<elseif $attackEquip == 2>>
		@@.yellowgreen;a good amount of cash.@@
		<<set _loot += 10000 * _majorBattleMod>>
	<<elseif $attackEquip == 3>>
		@@.yellowgreen;a great amount of cash.@@
		<<set _loot += 15000 * _majorBattleMod>>
	<<elseif $attackEquip == 4>>
		@@.yellowgreen;wealth worthy of the mightiest warlord.@@
		<<set _loot += 20000 * _majorBattleMod>>
	<</if>>
	<<if $mercSoldierPrivilege == 1 && App.SecExp.conflict.deployedUnits('mercs') >= 1>>
		Part of the loot is distributed to your mercenaries.
		<<set _captives = Math.trunc(_captives * 0.6)>>
		<<set _loot = Math.trunc(_loot * 0.6)>>
	<</if>>
	<<run cashX(_loot, "war")>>
	<br>
	Damage to the infrastructure was @@.yellow;virtually non-existent,@@ costing only pocket cash to bring the structure back to normal. The inhabitants as well reported little to no injuries, because of this the prosperity of the arcology did not suffer.
	<<= IncreasePCSkills('engineering', 0.1)>>
	<<run cashX(forceNeg(1000 * _majorBattleMod), "war")>>
	<<if $PCvictoryStreak >= 3>>
		It seems your victories over the constant threats directed your way is having @@.green;a positive effect on the prosperity of the arcology,@@ due to the security your leadership affords.
		<<set $arcologies[0].prosperity += 5 * _majorBattleMod>>
	<</if>>
<<elseif $battleResult == -3>>
	Due to your defeat, your @@.red;reputation@@ and @@.red;authority@@ decreased. Obviously your troops were not able to capture anyone or anything.
	<<if $attackType == "raiders">>
		<<run repX(forceNeg(400 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 400 * _majorBattleMod>>
	<<elseif $attackType == "free city">>
		<<run repX(forceNeg(600 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 600 * _majorBattleMod>>
	<<elseif $attackType == "freedom fighters">>
		<<run repX(forceNeg(750 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 750 * _majorBattleMod>>
	<<elseif $attackType == "old world">>
		<<run repX(forceNeg(600 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 600 * _majorBattleMod>>
	<</if>>
	<br>
	In the raiding following the battle @@.red;the arcology sustained heavy damage,@@ which will cost quite the amount of cash to fix. Reports of @@.red;citizens or slaves killed or missing@@ flood your office for a few days following the defeat.
	<<= IncreasePCSkills('engineering', 0.1)>>
	<<run cashX(forceNeg(5000 * _majorBattleMod), "war")>>
	<<if $week <= 30>>
		<<set $lowerClass -= random(100) * _majorBattleMod>>
		<<set _lostSlaves = random(150) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(5) * _majorBattleMod>>
	<<elseif $week <= 60>>
		<<set $lowerClass -= random(120) * _majorBattleMod>>
		<<set _lostSlaves = random(170) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(10) * _majorBattleMod>>
	<<elseif $week <= 90>>
		<<set $lowerClass -= random(140) * _majorBattleMod>>
		<<set _lostSlaves = random(190) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(15) * _majorBattleMod>>
	<<elseif $week <= 120>>
		<<set $lowerClass -= random(160) * _majorBattleMod>>
		<<set _lostSlaves = random(210) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(20) * _majorBattleMod>>
	<<else>>
		<<set $lowerClass -= random(180) * _majorBattleMod>>
		<<set _lostSlaves = random(230) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(25) * _majorBattleMod>>
	<</if>>
	<<if $PClossStreak >= 3>>
		This only confirms the fears of many, @@.red;your arcology is not safe@@ and it is clear their business will be better somewhere else.
		<<set $arcologies[0].prosperity -= 5 * _majorBattleMod>>
	<</if>>
<<elseif $battleResult == 2>>
	Thanks to your victory, your @@.green;reputation@@ and @@.darkviolet;authority@@ slightly increased. Our men were not able to capture any combatants, however some equipment was seized during the enemy's hasty retreat,
	<<if $attackType == "raiders">>
		<<run repX(1000 * _majorBattleMod, "war")>>
		<<set $SecExp.core.authority += 200 * _majorBattleMod>>
	<<elseif $attackType == "free city">>
		<<run repX(1500 * _majorBattleMod, "war")>>
		<<set $SecExp.core.authority += 300 * _majorBattleMod>>
	<<elseif $attackType == "freedom fighters">>
		<<run repX(2000 * _majorBattleMod, "war")>>
		<<set $SecExp.core.authority += 450 * _majorBattleMod>>
	<<elseif $attackType == "old world">>
		<<run repX(1500 * _majorBattleMod, "war")>>
		<<set $SecExp.core.authority += 300 * _majorBattleMod>>
	<</if>>
	which once sold produced
	<<if $attackEquip == 0>>
		@@.yellowgreen;a bit of cash.@@
		<<set _loot += 500 * _majorBattleMod>>
	<<elseif $attackEquip == 1>>
		@@.yellowgreen;a small amount of cash.@@
		<<set _loot += 2500 * _majorBattleMod>>
	<<elseif $attackEquip == 2>>
		@@.yellowgreen;a moderate amount of cash.@@
		<<set _loot += 5000 * _majorBattleMod>>
	<<elseif $attackEquip == 3>>
		@@.yellowgreen;a good amount of cash.@@
		<<set _loot += 7500 * _majorBattleMod>>
	<<elseif $attackEquip == 4>>
		@@.yellowgreen;a great amount of cash.@@
		<<set _loot += 10000 * _majorBattleMod>>
	<</if>>
	<<if $mercSoldierPrivilege == 1 && App.SecExp.conflict.deployedUnits('mercs') >= 1>>
		Part of the loot is distributed to your mercenaries.
		<<set _loot = Math.trunc(_loot * 0.6)>>
	<</if>>
	<<run cashX(_loot, "war")>>
	<br>
	Damage to the city was @@.red;limited,@@ it won't take much to rebuild. Very few citizens or slaves were involved in the fight and even fewer met their end, safeguarding the prosperity of the arcology.
	<<= IncreasePCSkills('engineering', 0.1)>>
	<<run cashX(forceNeg(2000 * _majorBattleMod), "war")>>
	<<set $lowerClass -= random(10) * _majorBattleMod>>
	<<set _lostSlaves = random(20) * _majorBattleMod,
	$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
	$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
	$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
	$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
<<elseif $battleResult == -2>>
	It was a close defeat, but nonetheless your @@.red;reputation@@ and @@.red;authority@@ slightly decreased. Your troops were not able to capture anyone or anything.
	<<if $attackType == "raiders">>
		<<run repX(forceNeg(40 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 40 * _majorBattleMod>>
	<<elseif $attackType == "free city">>
		<<run repX(forceNeg(60 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 60 * _majorBattleMod>>
	<<elseif $attackType == "freedom fighters">>
		<<run repX(forceNeg(75 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 75 * _majorBattleMod>>
	<<elseif $attackType == "old world">>
		<<run repX(forceNeg(60 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 60 * _majorBattleMod>>
	<</if>>
	<br>
	The enemy did not have the strength to raid the arcology for long, still @@.red;the arcology sustained some damage,@@ which will cost a moderate amount of cash to fix. Some citizens and slaves found themselves on the wrong end of a gun and met their demise.
	Some business sustained heavy damage, slightly impacting the arcology's prosperity.
	<<= IncreasePCSkills('engineering', 0.1)>>
	<<run cashX(forceNeg(3000 * _majorBattleMod), "war")>>
	<<if $week <= 30>>
		<<set $lowerClass -= random(50) * _majorBattleMod>>
		<<set _lostSlaves = random(75) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(2) * _majorBattleMod>>
	<<elseif $week <= 60>>
		<<set $lowerClass -= random(60) * _majorBattleMod>>
		<<set _lostSlaves = random(85) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(5) * _majorBattleMod>>
	<<elseif $week <= 90>>
		<<set $lowerClass -= random(70) * _majorBattleMod>>
		<<set _lostSlaves = random(95) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(7) * _majorBattleMod>>
	<<elseif $week <= 120>>
		<<set $lowerClass -= random(80) * _majorBattleMod>>
		<<set _lostSlaves = random(105) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(10) * _majorBattleMod>>
	<<else>>
		<<set $lowerClass -= random(90) * _majorBattleMod>>
		<<set _lostSlaves = random(115) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(12) * _majorBattleMod>>
	<</if>>
<<elseif $battleResult == -1>>
	Rather than waste the lives of your men you decided to surrender, hoping your enemy will cause less damage if you indulge them, this is however a big hit to your status. Your @@.red;reputation@@ and @@.red;authority@@ are significantly impacted.
	<<if $attackType == "raiders">>
		<<run repX(forceNeg(600 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 600 * _majorBattleMod>>
	<<elseif $attackType == "free city">>
		<<run repX(forceNeg(800 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 800 * _majorBattleMod>>
	<<elseif $attackType == "freedom fighters">>
		<<run repX(forceNeg(1000 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 1000 * _majorBattleMod>>
	<<elseif $attackType == "old world">>
		<<run repX(forceNeg(800 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 800 * _majorBattleMod>>
	<</if>>
	<br>
	The surrender allows the arcology to survive @@.red;mostly intact,@@ however reports of @@.red;mass looting and killing of citizens@@ flood your office for a few days.
	<<= IncreasePCSkills('engineering', 0.1)>>
	<<run cashX(forceNeg(1000 * _majorBattleMod), "war")>>
	<<if $week <= 30>>
		<<set $lowerClass -= random(80) * _majorBattleMod>>
		<<set _lostSlaves = random(120) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(5) * _majorBattleMod>>
	<<elseif $week <= 60>>
		<<set $lowerClass -= random(100) * _majorBattleMod>>
		<<set _lostSlaves = random(140) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(10) * _majorBattleMod>>
	<<elseif $week <= 90>>
		<<set $lowerClass -= random(120) * _majorBattleMod>>
		<<set _lostSlaves = random(160) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(15) * _majorBattleMod>>
	<<elseif $week <= 120>>
		<<set $lowerClass -= random(140) * _majorBattleMod>>
		<<set _lostSlaves = random(180) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(20) * _majorBattleMod>>
	<<else>>
		<<set $lowerClass -= random(160) * _majorBattleMod>>
		<<set _lostSlaves = random(200) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(25) * _majorBattleMod>>
	<</if>>
<<elseif $battleResult == 0>>
	Unfortunately your adversary did not accept your money. <<if $attackType == "freedom fighters">> Their ideological crusade would not allow such thing<<else>>They saw your attempt as nothing more than admission of weakness<</if>>. There was no time to organize a defense and so the enemy walked into the arcology as it was his.
	Your reputation and authority suffer a hit.
	<<if $attackType == "raiders">>
		<<run repX(forceNeg(400 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 400 * _majorBattleMod>>
	<<elseif $attackType == "free city">>
		<<run repX(forceNeg(600 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 600 * _majorBattleMod>>
	<<elseif $attackType == "freedom fighters">>
		<<run repX(forceNeg(750 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 750 * _majorBattleMod>>
	<<elseif $attackType == "old world">>
		<<run repX(forceNeg(600 * _majorBattleMod), "war")>>
		<<set $SecExp.core.authority -= 600 * _majorBattleMod>>
	<</if>>
	<br>
	Fortunately the arcology survives @@.yellow;mostly intact,@@ however reports of @@.red;mass looting and killing of citizens@@ flood your office for a few days.
	<<= IncreasePCSkills('engineering', 0.1)>>
	<<run cashX(-1000, "war")>>
	<<if $week <= 30>>
		<<set $lowerClass -= random(80) * _majorBattleMod>>
		<<set _lostSlaves = random(120) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(5) * _majorBattleMod>>
	<<elseif $week <= 60>>
		<<set $lowerClass -= random(100) * _majorBattleMod>>
		<<set _lostSlaves = random(140) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(10) * _majorBattleMod>>
	<<elseif $week <= 90>>
		<<set $lowerClass -= random(120) * _majorBattleMod>>
		<<set _lostSlaves = random(160) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(15) * _majorBattleMod>>
	<<elseif $week <= 120>>
		<<set $lowerClass -= random(140) * _majorBattleMod>>
		<<set _lostSlaves = random(180) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(20) * _majorBattleMod>>
	<<else>>
		<<set $lowerClass -= random(160) * _majorBattleMod>>
		<<set _lostSlaves = random(200) * _majorBattleMod,
		$NPCSlaves -= Math.trunc(($NPCSlaves / $ASlaves) * _lostSlaves),
		$menials -= Math.trunc(($menials / $ASlaves) * _lostSlaves),
		$fuckdolls -= Math.trunc(($fuckdolls / $ASlaves) * _lostSlaves),
		$menialBioreactors -= Math.trunc(($menialBioreactors / $ASlaves) * _lostSlaves)>>
		<<set $arcologies[0].prosperity -= random(25) * _majorBattleMod>>
	<</if>>
	<br>
<<elseif $battleResult == 1>>
	The attackers wisely take the money offered them to leave your territory without further issues. The strength of the Free Cities was never in their guns but in their dollars, and today's events are the perfect demonstration of such strength.
	Your @@.green;reputation slightly increases.@@
	<<if $attackType == "raiders">>
		<<run repX(500 * _majorBattleMod, "war")>>
	<<elseif $attackType == "free city">>
		<<run repX(750 * _majorBattleMod, "war")>>
	<<elseif $attackType == "freedom fighters">>
		<<run repX(1000 * _majorBattleMod, "war")>>
	<<elseif $attackType == "old world">>
		<<run repX(750 * _majorBattleMod, "war")>>
	<</if>>
	<<run cashX(forceNeg($bribeCost), "war")>>
<</if>>
<<if !Number.isInteger($lowerClass)>>
	<<if isNaN($lowerClass)>>
		<br>@@.red;Error: lowerClass is NaN, please report this issue@@
	<<elseif $lowerClass > 0>>
		<<set $lowerClass = Math.trunc($lowerClass)>>
	<<else>>
		<<set $lowerClass = 0>>
	<</if>>
<</if>>
<<if !Number.isInteger($NPCSlaves)>>
	<<if isNaN($NPCSlaves)>>
		<br>@@.red;Error: NPCSlaves is NaN, please report this issue@@
	<<elseif $NPCSlaves > 0>>
		<<set $NPCSlaves = Math.trunc($NPCSlaves)>>
	<<else>>
		<<set $NPCSlaves = 0>>
	<</if>>
<</if>>

<br><br>
<<if $battleResult != 1 && $battleResult != 0 && $battleResult != -1>>

	/* leaders */
	<<if $leadingTroops == "PC">>
		<<setPlayerPronouns>>
		You decided to personally lead the defense of your arcology.
		<<if App.SecExp.conflict.deployedUnits('militia') >= 1>>
			<<if _oldRep <= 2500>>
				<<if _oldRep > 1000>>
					You're not particularly popular between the inhabitants of your arcology, so your presence does little to reassure the volunteers.
				<<else>>
					As your low reputation proves, your volunteers do not particularly enjoy your company. As far as they are concerned your presence is more of a hindrance than an advantage.
				<</if>>
				<<if $PC.career == "celebrity">>
					Still, your past celebrity does carry some weight, and many look forward to fight alongside a famous name.
				<<elseif $PC.career == "capitalist">>
					Still, your past life as a famous venture capitalist does carry some weight, and many trust in your cunning to save them in the incoming battle.
				<<elseif $PC.career == "gang">>
					The situation is not made easier by your past. Many still remember you as the gang leader who used to be on the other side of their guns.
				<<elseif $PC.career == "escort">>
					The situation is not made easier by your past. Many still remember your past career as an escort and doubt you'll be of any use during the fighting.
				<<elseif $PC.career == "mercenary">>
					Still, your past mercenary work does carry some weight, and many look forward to fight alongside a battle hardened name.
				<</if>>
			<<elseif _oldRep >= 5000>>
				<<if _oldRep < 15000>>
					Your citizens are honored that their arcology owner is willing to put _hisP life in danger.
				<<else>>
					Many among the volunteers are awed by your presence; never would they have thought they would fight shoulder to shoulder with their famous arcology owner.
				<</if>>
				<<if $PC.career == "celebrity">>
					They consider it a priceless opportunity to fight together with someone with such a renowned past as yours. Your celebrity past still carries weight.
				<<elseif $PC.career == "capitalist">>
					They consider it a priceless opportunity to fight together with one of the great capitalist sharks of their time. Such a fine mind on their side can only bring victory!
				<<elseif $PC.career == "gang">>
					Your past, however, does not help you. Many still remember you as the gang leader who used to be on the other side of their guns.
				<<elseif $PC.career == "escort">>
					Your past, however, does not help you. Many still remember your past career as an escort and doubt you'll be of any use during the fighting.
				<<elseif $PC.career == "mercenary">>
					Your past mercenary work does carries some weight, and many look forward to fight alongside a battle hardened name.
				<</if>>
			<</if>>
		<</if>>
		<<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>
			<<if _oldAuth <= 2500>>
				<<if _oldAuth > 1000>>
					Your slave soldiers do not feel bound to you as much as they should, as your authority is far from absolute.
				<<else>>
					Your slave soldiers are often openly rebellious. Only the threat of execution holds them in line.
				<</if>>
				<<if $PC.career == "escort">>
					Fortunately many feel some level of kinship with you, thanks to your past as an escort.
				<<elseif $PC.career == "servant">>
					Fortunately many feel some level of kinship with you, thanks to your past as a servant.
				<<elseif $PC.career == "slaver">>
					Things are made worse by your past as a notorious slaver.
				<<elseif $PC.career == "mercenary">>
					Your past mercenary work carries some weight, and many look forward to fighting alongside a battle hardened name.
				<</if>>
			<<elseif _oldAuth >= 5000>>
				<<if _oldAuth < 15000>>
					Your slave soldiers show a surprising amount of discipline, thanks to your high authority.
				<<else>>
					Your slave soldiers show almost a fanatical level of martial discipline. Your absolute authority has a great effect on them.
				<</if>>
				<<if $PC.career == "escort">>
					Many have an instinctual feeling of kinship towards you because of your past as an escort.
				<<elseif $PC.career == "servant">>
					Many have an instinctual feeling of kinship towards you because of your past as a servant.
				<<elseif $PC.career == "slaver">>
					Still, some rebellious looks can be spotted once in a while. In their eyes your slaver past will always paint you in a dark light.
				<<elseif $PC.career == "mercenary">>
					Your past mercenary work carries some weight, and many look forward to fighting alongside a battle hardened name.
				<</if>>
			<</if>>
		<</if>>
		<<if App.SecExp.conflict.deployedUnits('mercs') >= 1>>
			<<if $mercLoyalty <= 25>>
				<<if $mercLoyalty <= 10>>
					Your mercenaries barely bother to pretend being loyal; their battle performance is obviously barely passable.
				<<else>>
					Your presence does little to spur your mercenaries into action; their loyalty is straining and their performance suffers.
				<</if>>
				<<if $PC.career == "mercenary">>
					Thankfully they hold in high regard someone who made their fortune as a mercenary themselves.
				<<elseif $PC.career == "wealth">>
					They do little to hide the contempt they have for someone who was born into wealth, rather than gaining it through blood, sweat, and tears.
				<<elseif $PC.career == "servant">>
					They do little to hide their disgust at being ordered around by an ex-servant.
				<<elseif $PC.career == "BlackHat">>
					They do little to hide their disgust at being ordered around by some unscrupulous code monkey.
				<</if>>
			<<elseif $mercLoyalty >= 50>>
				<<if $mercLoyalty < 75>>
					Your mercenaries are ready to fight their hardest for you, their loyalty a testament to your capability as a leader.
				<<else>>
					Your mercenaries fight with a martial fury worthy of religious fanatics. Their loyalty to you is absolute.
				<</if>>
				<<if $PC.career == "mercenary">>
					They're more than willing to follow someone who walked their same steps once as a gun for hire.
				<<elseif $PC.career == "wealth">>
					Unfortunately many still resent you being born into your wealth and power, rather than having earned it through blood, sweat, and tears.
				<<elseif $PC.career == "servant">>
					Unfortunately some still resent the fact they are ordered around by an ex-servant.
				<<elseif $PC.career == "BlackHat">>
					Unfortunately some still resent the fact they are ordered around by an unscrupulous hacker.
				<</if>>
			<</if>>
			<<if _oldRep >= 15000>>
				Your reputation is so high your name carries power by itself. Having you on the battlefield puts fear even in the hardiest of warriors.
			<</if>>
		<</if>>
		<<if $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
			<<if $PC.career == "mercenary" || $PC.career == "slaver" || $PC.career == "capitalist" || $PC.career == "gang" || $PC.skill.warfare > 75>>
				The soldiers of $SF.Lower are ready and willing to follow you into battle, confident in your past experience.
			<<elseif $PC.career == "wealth" || $PC.career == "medicine" || $PC.career == "engineer">>
				The soldiers of $SF.Lower, as loyal as they are, are not enthusiastic to follow the orders of someone who has no experience leading men.
			<<elseif $PC.career == "servant">>
				The soldiers of $SF.Lower, as loyal as they are, are not enthusiastic to follow the orders of an ex-servant.
			<<elseif $PC.career == "escort">>
				The soldiers of $SF.Lower, as loyal as they are, are not enthusiastic to follow the orders of an ex-escort.
			<<elseif $PC.career == "BlackHat">>
				The soldiers of $SF.Lower, as loyal as they are, are not enthusiastic to follow the orders of a dubious incursion specialist.
			<</if>>
		<</if>>
		<<if $PC.skill.warfare <= 25 && $PC.skill.warfare > 10>>
			Your inexperience in military matters has a negative impact on your troops performance and the effectiveness of your battle plan.
		<<elseif $PC.skill.warfare <= 10>>
			Your ignorance in military matters has a severe negative impact on your troops performance and the effectiveness of your battle plan.
		<<elseif $PC.skill.warfare >= 50 && $PC.skill.warfare >= 50>>
			Your experience in military matters has a positive impact on your troops performance and the effectiveness of your battle plan.
		<<elseif $PC.skill.warfare >= 75>>
			Your great experience in military matters has a major positive impact on your troops performance and the effectiveness of your battle plan.
		<</if>>
		<<if $gainedWarfare == 1>>
			Battlefield experience increased your understanding of warfare, making you a better commander.
		<</if>>
		<<if $PC.health.shortDamage >= 60>>
			During the fighting @@.red;you were wounded.@@ Your medics assure you it's nothing life threatening, but you'll be weakened for a few weeks.
		<</if>>
	<<elseif $leadingTroops == "assistant">>
		<<setAssistantPronouns>>
		<<if $auto == 1>>$assistant.name<<else>>You<</if>> let your personal assistant lead the troops.
		<<if App.SecExp.conflict.deployedUnits('mercs') >= 1 || App.SecExp.conflict.deployedUnits('militia') >= 1 || App.SecExp.conflict.deployedUnits('slaves') >= 1>>
			No soldier trusts a computer to be their commander,
			<<if _oldRep < 10000 && _oldAuth < 10000>>
				no algorithm can substitute experience, <<if $assistant.power == 0>>and as expected, <<else>>however, <</if>>
			<<else>>
				but they trust you enough to not question your decision<<if $assistant.power == 0>>, however<<else>>, and <</if>>
			<</if>>
		<<else>>
			You find
		<</if>>
		<<if $assistant.power == 0>>
			your assistant gives a rather poor field performance, due to the limited computing power available to _himA.
		<<elseif $assistant.power == 1>>
			your assistant performs decently. While nothing to write home about your men are pleasantly surprised.
		<<elseif $assistant.power == 2>>
			your assistant performs admirably. _HisA upgraded computing power allows _himA to monitor the battlefield closely, enhancing the efficiency of your troops and the effectiveness of your battle plan.
		<<elseif $assistant.power >= 3>>
			your assistant performs admirably. _HisA vast computing power allows _himA to be everywhere on the battlefield, greatly enhancing the efficiency of your troops and the effectiveness of your battle plan.
		<</if>>
	<<elseif $leadingTroops == "bodyguard">>
		<<setLocalPronouns $Bodyguard>>
		<<if $auto == 1>>$assistant.name<<else>>You<</if>> decided it will be your bodyguard that leads the troops.
		<<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>
			<<if $Bodyguard.devotion < -20>>
				$His low devotion has a negative impact on the morale of your slave soldiers.
			<<elseif $Bodyguard.devotion > 51>>
				$His devotion to you has a positive impact on the morale of your slave soldiers, proud to be led by one of their own.
			<</if>>
		<</if>>
		<<if _oldRep < 10000 && _oldAuth < 10000 || $Bodyguard.prestige < 1>>
			<<if App.SecExp.conflict.deployedUnits('militia') >= 1>>
				Your volunteers <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however<</if>> are not enthusiastic to have a slave as a
				<<if $SF.Toggle && $SF.Active >= 1 && App.SecExp.conflict.deployedUnits('mercs') == 1 && $SFIntervention>>
					commander, and neither are your mercenaries or your soldiers.
				<<elseif App.SecExp.conflict.deployedUnits('mercs') >= 1>>
					commander, and neither are your mercenaries.
				<<elseif $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
					commander, and neither are your soldiers.
				<<else>>
					commander.
				<</if>>
			<<elseif $SF.Toggle && $SF.Active >= 1 && App.SecExp.conflict.deployedUnits('mercs') == 1 && $SFIntervention>>
				Your mercenaries and soldiers <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however<</if>> are not enthusiastic to have a slave as a commander.
			<<elseif App.SecExp.conflict.deployedUnits('mercs') >= 1>>
				Your mercenaries <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however<</if>> are not enthusiastic to have a slave as a commander.
			<<elseif $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
				Your soldiers <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however<</if>> are not enthusiastic to have a slave as a commander.
			<</if>>
		<<elseif $Bodyguard.prestige >= 2>>
			<<if App.SecExp.conflict.deployedUnits('militia') >= 1>>
				Your
				<<if App.SecExp.conflict.deployedUnits('mercs') == 1 && $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
					volunteers, your mercenaries and your soldiers are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
				<<elseif App.SecExp.conflict.deployedUnits('mercs') >= 1>>
					volunteers and your mercenaries are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
				<<elseif $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
					volunteers and your soldiers are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
				<<else>>
					volunteers are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
				<</if>>
			<<elseif App.SecExp.conflict.deployedUnits('mercs') == 1 && $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
				Your mercenaries and soldiers are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
			<<elseif App.SecExp.conflict.deployedUnits('mercs') >= 1>>
				Your mercenaries are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
			<<elseif $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
				Your soldiers are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
			<</if>>
		<<else>>
			<<if App.SecExp.conflict.deployedUnits('militia') >= 1>>
				Your volunteers <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however<</if>> are not enthusiastic to have a slave as a
				<<if App.SecExp.conflict.deployedUnits('mercs') == 1 && $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
					commander, and neither are your mercenaries and soldiers, but they trust you enough not to question your decision.
				<<elseif App.SecExp.conflict.deployedUnits('mercs') >= 1>>
					commander, and neither are your mercenaries, but they trust you enough not to question your decision.
				<<elseif $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
					commander, and neither are your soldiers, but they trust you enough not to question your decision.
				<<else>>
					commander, but they trust you enough not to question your decision.
				<</if>>
			<<elseif App.SecExp.conflict.deployedUnits('mercs') == 1 && $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
				Your mercenaries and soldiers <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however,<</if>> are not enthusiastic to have a slave as a commander, but they trust you enough not to question your decision.
			<<elseif App.SecExp.conflict.deployedUnits('mercs') >= 1>>
				Your mercenaries <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however,<</if>> are not enthusiastic to have a slave as a commander, but they trust you enough not to question your decision.
			<<elseif $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
				Your soldiers <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however,<</if>> are not enthusiastic to have a slave as a commander, but they trust you enough not to question your decision.
			<</if>>
		<</if>>
		<<if (setup.bodyguardCareers.includes($Bodyguard.career) || setup.HGCareers.includes($Bodyguard.career) || setup.secExCombatPrestige.includes($Bodyguard.prestigeDesc)) && $Bodyguard.intelligence+$Bodyguard.intelligenceImplant > 95>>
			With $his experience and $his great intellect, $he is able to exploit the smallest of tactical advantages, making your troops very effective.
		<<elseif $Bodyguard.intelligence+$Bodyguard.intelligenceImplant > 95>>
			While $he lacks experience, $his great intellect allows $him to seize and exploit any tactical advantage the battlefield offers $him.
		<<elseif (setup.bodyguardCareers.includes($Bodyguard.career) || setup.HGCareers.includes($Bodyguard.career) || setup.secExCombatPrestige.includes($Bodyguard.prestigeDesc)) && $Bodyguard.intelligence+$Bodyguard.intelligenceImplant > 50>>
			Having both the experience and the intelligence, $he performs admirably as your commander. $His competence greatly increases the efficiency of your troops.
		<<elseif $Bodyguard.intelligence+$Bodyguard.intelligenceImplant > 50>>
			Despite not having a lot of experience as a leader, $his intelligence makes $him a good commander, increasing the efficiency of your troops.
		<<elseif (setup.bodyguardCareers.includes($Bodyguard.career) || setup.HGCareers.includes($Bodyguard.career) || setup.secExCombatPrestige.includes($Bodyguard.prestigeDesc)) && $Bodyguard.intelligence+$Bodyguard.intelligenceImplant > 15>>
			Thanks to $his experience, $he is a decent commander, competently guiding your troops through the battle.
		<<elseif $Bodyguard.intelligence+$Bodyguard.intelligenceImplant > 15>>
			Lacking experience, $his performance as a commander is rather forgettable.
		<<elseif !(setup.bodyguardCareers.includes($Bodyguard.career) && setup.HGCareers.includes($Bodyguard.career) && setup.secExCombatPrestige.includes($Bodyguard.prestigeDesc)) || $Bodyguard.intelligence+$Bodyguard.intelligenceImplant < -50>>
			Despite the experience $he accumulated during $his past career, $his very low intelligence is a great disadvantage for your troops.
		<<elseif $Bodyguard.intelligence+$Bodyguard.intelligenceImplant < -50>>
			Without experience and low intelligence, $he performs horribly as a commander, greatly affecting your troops.
		<<elseif !(setup.bodyguardCareers.includes($Bodyguard.career) && setup.HGCareers.includes($Bodyguard.career) && setup.secExCombatPrestige.includes($Bodyguard.prestigeDesc)) || $Bodyguard.intelligence+$Bodyguard.intelligenceImplant < -15>>
			Despite the experience $he accumulated during $his past career, $he lacks the intelligence to apply it quickly and effectively, making for a rather poor performance in the field.
		<<elseif $Bodyguard.intelligence+$Bodyguard.intelligenceImplant < -15>>
			$He lacks the experience and the intelligence to be an effective commander, the performance of your troops suffers because of $his poor leadership.
		<</if>>
		<<if $gainedCombat == 1>>
			During the battle, $he had to fight for $his life, giving $him experience in modern combat. $He is now proficient with modern firearms and hand to hand combat.
		<</if>>
		<<if $woundType != 0>>
			Unfortunately, @@.red;$he sustained major injuries.@@
			<<if $woundType == 1>>
				A stray bullet hit $his neck. While $he fortunately avoided fatal hemorrhaging, $his vocal cords were irreparably damaged.
			<<elseif $woundType == 2>>
				Some shrapnel found $his eyes as their final target, blinding $him permanently.
			<<elseif $woundType == 3>>
				A grenade landed close to $him, rendering $him a quadruple amputee.
			<<elseif $woundType >= 4>>
				While gravely wounded, it seems $he will be able to fully recover, given enough time.
			<</if>>
			Your troops were greatly affected by the loss of their leader.
		<</if>>
		<<if $battleResult == 3 && $SecExp.settings.battle.allowSlavePrestige == 1>>
			<<set _found = 0>>
			<<for _i = 0; _i < $slaveVictories.length; _i++>>
				<<if $slaveVictories[_i].ID == $Bodyguard.ID>>
					<<set $slaveVictories[_i].victories++>>
					<<set _found = 1>>
					<<if $slaveVictories[_i].victories >= 10>>
						<<if $Bodyguard.prestige < 3>>
							<<set _j = $slaveIndices[$Bodyguard.ID]>>
							<<set $slaves[_j].prestige++>>
							<<if $slaves[_j].prestige == 1>>
								<<set $slaves[_j].prestigeDesc = "$He is well known for being a great commander.">>
							<<elseif $slaves[_j].prestige == 2>>
								<<set $slaves[_j].prestigeDesc = "$He is famous for being an incredible commander.">>
							<<elseif $slaves[_j].prestige == 3>>
								<<set $slaves[_j].prestigeDesc = "$He is known as a legendary commander all over the world.">>
							<</if>>
							<<set $slaveVictories[_i].victories = 0>>
							<<set $slaveIncreasedPrestige = 1>>
						<</if>>
					<</if>>
					<<break>>
				<</if>>
			<</for>>
			<<if _found == 0>>
				<<set _newSlave = {ID: $Bodyguard.ID, victories: 0}>>
				<<set $slaveVictories.push(_newSlave)>>
			<</if>>
		<</if>>
		<<if $slaveIncreasedPrestige == 1>>
			$He brought your army to victory so many times that $his @@.green;prestige has increased.@@
		<</if>>
	<<elseif $leadingTroops == "headGirl">>
		<<setLocalPronouns $HeadGirl>>
		<<if $auto == 1>>$assistant.name<<else>>You<</if>> decided it will be your Head Girl that leads the troops.
		<<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>
			<<if $HeadGirl.devotion < -20>>
				$His low devotion has a negative impact on the morale of your slave soldiers.
			<<elseif $HeadGirl.devotion > 51>>
				$His devotion to you has a positive impact on the morale of your slave soldiers, proud to be led by one of their own.
			<</if>>
		<</if>>
		<<if _oldRep < 10000 && _oldAuth < 10000 || $HeadGirl.prestige < 1>>
			<<if App.SecExp.conflict.deployedUnits('militia') >= 1>>
				Your volunteers <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however<</if>> are not enthusiastic to have a slave as a
				<<if App.SecExp.conflict.deployedUnits('mercs') == 1 && $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
					commander, and neither are your mercenaries or your soldiers.
				<<elseif App.SecExp.conflict.deployedUnits('mercs') >= 1>>
					commander, and neither are your mercenaries.
				<<elseif $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
					commander, and neither are your soldiers.
				<<else>>
					commander.
				<</if>>
			<<elseif App.SecExp.conflict.deployedUnits('mercs') == 1 && $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
				Your mercenaries and soldiers <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however<</if>> are not enthusiastic to have a slave as a commander.
			<<elseif App.SecExp.conflict.deployedUnits('mercs') >= 1>>
				Your mercenaries <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however<</if>> are not enthusiastic to have a slave as a commander.
			<<elseif $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
				Your soldiers <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however<</if>> are not enthusiastic to have a slave as a commander.
			<</if>>
		<<elseif $HeadGirl.prestige >= 2>>
			<<if App.SecExp.conflict.deployedUnits('militia') >= 1>>
				Your
				<<if App.SecExp.conflict.deployedUnits('mercs') == 1 && $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
					volunteers, your mercenaries and your soldiers are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
				<<elseif App.SecExp.conflict.deployedUnits('mercs') >= 1>>
					volunteers and your mercenaries are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
				<<elseif $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
					volunteers and your soldiers are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
				<<else>>
					volunteers are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
				<</if>>
			<<elseif App.SecExp.conflict.deployedUnits('mercs') == 1 && $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
				Your mercenaries and soldiers are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
			<<elseif App.SecExp.conflict.deployedUnits('mercs') >= 1>>
				Your mercenaries are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
			<<elseif $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
				Your soldiers are delighted to have such a prestigious individual as their commander, almost forgetting $he is a slave.
			<</if>>
		<<else>>
			<<if App.SecExp.conflict.deployedUnits('militia') >= 1>>
				Your volunteers <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however<</if>> are not enthusiastic to have a slave as a
				<<if App.SecExp.conflict.deployedUnits('mercs') == 1 && $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
					commander, and neither are your mercenaries and soldiers, but they trust you enough not to question your decision.
				<<elseif App.SecExp.conflict.deployedUnits('mercs') >= 1>>
					commander, and neither are your mercenaries, but they trust you enough not to question your decision.
				<<elseif $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
					commander, and neither are your soldiers, but they trust you enough not to question your decision.
				<<else>>
					commander, but they trust you enough not to question your decision.
				<</if>>
			<<elseif App.SecExp.conflict.deployedUnits('mercs') == 1 && $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
				Your mercenaries and soldiers <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however<</if>> are not enthusiastic to have a slave as a commander, but they trust you enough not to question your decision.
			<<elseif App.SecExp.conflict.deployedUnits('mercs') >= 1>>
				Your mercenaries <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however<</if>> are not enthusiastic to have a slave as a commander, but they trust you enough not to question your decision.
			<<elseif $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
				Your soldiers <<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>however<</if>> are not enthusiastic to have a slave as a commander, but they trust you enough not to question your decision.
			<</if>>
		<</if>>
		<<if (setup.bodyguardCareers.includes($HeadGirl.career) || setup.HGCareers.includes($HeadGirl.career) || setup.secExCombatPrestige.includes($HeadGirl.prestigeDesc)) && $HeadGirl.intelligence+$HeadGirl.intelligenceImplant > 95>>
			With $his experience and $his great intellect, $he is able to exploits the smallest of tactical advantages, making your troops greatly effective.
		<<elseif $HeadGirl.intelligence+$HeadGirl.intelligenceImplant > 95>>
			While $he lacks experience, $his great intellect allows $him to seize and exploit any tactical advantage the battlefield offers $him.
		<<elseif (setup.bodyguardCareers.includes($HeadGirl.career) || setup.HGCareers.includes($HeadGirl.career) || setup.secExCombatPrestige.includes($HeadGirl.prestigeDesc)) && $HeadGirl.intelligence+$HeadGirl.intelligenceImplant > 50>>
			Having both the experience and the intelligence, $he performs admirably as your commander. $His competence greatly increases the efficiency of your troops.
		<<elseif $HeadGirl.intelligence+$HeadGirl.intelligenceImplant > 50>>
			Despite not having a lot of experience as a leader, $his intelligence makes $him a good commander, increasing the efficiency of your troops.
		<<elseif (setup.bodyguardCareers.includes($HeadGirl.career) || setup.HGCareers.includes($HeadGirl.career) || setup.secExCombatPrestige.includes($HeadGirl.prestigeDesc)) && $HeadGirl.intelligence+$HeadGirl.intelligenceImplant > 15>>
			Thanks to $his experience, $he is a decent commander, competently guiding your troops through the battle.
		<<elseif $HeadGirl.intelligence+$HeadGirl.intelligenceImplant > 15>>
			Lacking experience $his performance as a commander is rather forgettable.
		<<elseif !(setup.bodyguardCareers.includes($HeadGirl.career) && setup.HGCareers.includes($HeadGirl.career) && setup.secExCombatPrestige.includes($HeadGirl.prestigeDesc)) || $HeadGirl.intelligence+$HeadGirl.intelligenceImplant < -50>>
			Despite the experience $he accumulated during $his past career, $his very low intelligence is a great disadvantage for your troops.
		<<elseif $HeadGirl.intelligence+$HeadGirl.intelligenceImplant < -50>>
			Without experience and low intelligence, $he performs horribly as a commander, greatly affecting your troops.
		<<elseif !(setup.bodyguardCareers.includes($HeadGirl.career) && setup.HGCareers.includes($HeadGirl.career) && setup.secExCombatPrestige.includes($HeadGirl.prestigeDesc)) || $HeadGirl.intelligence+$HeadGirl.intelligenceImplant < -15>>
			Despite the experience $he accumulated during $his past career, $he lacks the intelligence to apply it quickly and effectively, making for a rather poor performance in the field.
		<<elseif $HeadGirl.intelligence+$HeadGirl.intelligenceImplant < -15>>
			$He lacks the experience and the intelligence to be an effective commander, the performance of your troops suffers because of $his poor leadership.
		<</if>>
		<<if $gainedCombat == 1>>
			During the battle, $he had to fight for $his life, giving $him experience in modern combat. $He is now proficient with modern firearms and hand to hand combat.
		<</if>>
		<<if $woundType != 0>>
			Unfortunately, @@.red;$he sustained severe injuries.@@
			<<if $woundType == 1>>
				A stray bullet hit $his neck. While $he fortunately avoided fatal hemorrhaging, $his vocal cords were irreparably damaged.
			<<elseif $woundType == 2>>
				Some shrapnel found $his eyes as final their target, blinding $him permanently.
			<<elseif $woundType == 3>>
				A grenade landed close to $him, rendering $him a quadruple amputee.
			<<elseif $woundType >= 4>>
				While gravely wounded, it seems $he will be able to fully recover, given enough time.
			<</if>>
			Your troops were greatly affected by the loss of their leader.
		<</if>>
		<<if $battleResult == 3 && $SecExp.settings.battle.allowSlavePrestige == 1>>
			<<set _found = 0>>
			<<for _i = 0; _i < $slaveVictories.length; _i++>>
				<<if $slaveVictories[_i].ID == $HeadGirl.ID>>
					<<set $slaveVictories[_i].victories++>>
					<<set _found = 1>>
					<<if $slaveVictories[_i].victories >= 10>>
						<<if $HeadGirl.prestige < 3>>
							<<set _j = $slaveIndices[$HeadGirl.ID]>>
							<<set $slaves[_j].prestige++>>
							<<if $slaves[_j].prestige == 1>>
								<<set $slaves[_j].prestigeDesc = "$He is well known for being a great commander.">>
							<<elseif $slaves[_j].prestige == 2>>
								<<set $slaves[_j].prestigeDesc = "$He is famous for being an incredible commander.">>
							<<elseif $slaves[_j].prestige == 3>>
								<<set $slaves[_j].prestigeDesc = "$He is known as a legendary commander all over the world.">>
							<</if>>
							<<set $slaveVictories[_i].victories = 0>>
							<<set $slaveIncreasedPrestige = 1>>
						<</if>>
					<</if>>
					<<break>>
				<</if>>
			<</for>>
			<<if _found == 0>>
				<<set _newSlave = {ID: $HeadGirl.ID, victories: 0}>>
				<<set $slaveVictories.push(_newSlave)>>
			<</if>>
		<</if>>
		<<if $slaveIncreasedPrestige == 1>>
			$He brought your army to victory so many times that $his @@.green;prestige has increased.@@
		<</if>>
	<<elseif $leadingTroops == "citizen">>
		<<if $auto == 1>>$assistant.name<<else>>You<</if>> decided to appoint one of your volunteers as the commander.
		<<if $arcologies[0].FSDegradationist == "unset" && $arcologies[0].FSPaternalist == "unset">>
			<<if App.SecExp.conflict.deployedUnits('militia') >= 1>>
				Your volunteers are honored and pleased that one of their own is leading the defense force of the city.
			<</if>>
			<<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>
				Your slaves<<if App.SecExp.conflict.deployedUnits('militia') >= 1>>, however,<</if>> are not thrilled by the news.
			<</if>>
		<<elseif $arcologies[0].FSPaternalist != "unset">>
			<<if App.SecExp.conflict.deployedUnits('militia') >= 1>>
				Your volunteers are honored and pleased that one of their own is leading the defense force of the city.
			<</if>>
			<<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>
				Thanks to your paternalistic society, your slave soldiers trust your chosen citizen to treat them as more than cannon fodder.
			<</if>>
		<<elseif $arcologies[0].FSDegradationist != "unset">>
			<<if App.SecExp.conflict.deployedUnits('militia') >= 1>>
				Your volunteers are honored and pleased that one of their own is leading the defense force of the city.
			<</if>>
			<<if App.SecExp.conflict.deployedUnits('slaves') >= 1>>
				Because of your degradationist society,<<if App.SecExp.conflict.deployedUnits('militia') >= 1>> however,<</if>> your slave soldiers are deeply distrustful of the new leader.
			<</if>>
		<</if>>
		<<if $arcologies[0].FSRomanRevivalist != "unset" && App.SecExp.conflict.deployedUnits('mercs') >= 1>>
			Since you decided to revive old Rome, many of your citizens took on themselves to educate themselves in martial matters, because of this your mercenaries feel safe enough in the hands of one of your volunteers.
		<<elseif App.SecExp.conflict.deployedUnits('mercs') >= 1>>
			You mercenaries are not thrilled to be lead by a civilian without any formal martial training or education.
		<</if>>
		<<if $arcologies[0].FSRomanRevivalist != "unset" && $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
			Since you decided to revive old Rome, many of your citizens took on themselves to educate themselves in martial matters, because of this your soldiers feel safe enough in the hands of one of your volunteers.
		<<elseif $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
			You soldiers are not thrilled to be lead by a civilian without any formal martial training or education.
		<</if>>
		<<if $leaderWounded == 1>>
			During the battle a stray bullet managed to reach the leader. Your troops were greatly affected by the loss.
		<</if>>
	<<elseif $leadingTroops == "mercenary">>
		<<if $auto == 1>>$assistant.name<<else>>You<</if>> decided to appoint one of your mercenary officers as the commander.
		<<if App.SecExp.conflict.deployedUnits('mercs') >= 1>>
			Your mercenaries of course approve of your decision.
		<</if>>
		<<if $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
			Your soldiers feel more confident going into battle with an experienced commander.
		<</if>>
		<<if $arcologies[0].FSRomanRevivalist != "unset" && App.SecExp.conflict.deployedUnits('militia') >= 1>>
			Since you decided to revive old Rome, your volunteers are more willing to trust one of your mercenaries as their leader.
		<<elseif App.SecExp.conflict.deployedUnits('militia') >= 1>>
			Your volunteers are not enthusiastic at the prospect of being commanded around by a gun for hire.
		<</if>>
		<<if $arcologies[0].FSDegradationist != "unset" && App.SecExp.conflict.deployedUnits('slaves') >= 1>>
			Because of your degradationist society, your slave soldiers are highly distrustful of the gun for hire you forced them to accept as leader.
		<</if>>
		<<if $leaderWounded == 1>>
			During the battle a stray bullet managed to reach the mercenary. Your troops were greatly affected by the loss of their leader.
		<</if>>
	<<elseif $leadingTroops == "colonel">>
		<<if $auto == 1>>$assistant.name<<else>>You<</if>> decided to appoint The Colonel as the commander.
		<<if App.SecExp.conflict.deployedUnits('mercs') >= 1>>
			Your mercenaries approve of such decisions, as they feel more confident by having a good, experienced commander.
		<</if>>
		<<if $SF.Toggle && $SF.Active >= 1 && $SFIntervention>>
			The soldiers of $SF.Lower obviously approved of your decision.
		<</if>>
		<<if $arcologies[0].FSRomanRevivalist != "unset" && App.SecExp.conflict.deployedUnits('militia') >= 1>>
			Since you decided to revive old Rome, your volunteers are more willing to trust one of your soldiers as their leader.
		<<elseif App.SecExp.conflict.deployedUnits('militia') >= 1>>
			Your volunteers are not enthusiastic at the prospect of being commanded around by an old style military officer.
		<</if>>
		<<if $arcologies[0].FSDegradationist != "unset" && App.SecExp.conflict.deployedUnits('slaves') >= 1>>
			Because of your degradationist society, your slave soldiers are highly distrustful of the soldier you forced them to accept as leader.
		<</if>>
		<<if $leaderWounded == 1>>
			During the battle a stray bullet managed to reach The Colonel, wounding her slightly. Your troops were greatly affected by the loss of their leader.
		<</if>>
	<</if>>

	<br><br>

	/* tactics */
	<<if $auto == 1>>$assistant.name<<else>>You<</if>>
	<<if $chosenTactic == "Bait and Bleed">>
		chose to employ "bait and bleed" tactics or relying on quick attacks and harassment to tire and wound the enemy until their surrender.
	<<elseif $chosenTactic == "Guerrilla">>
		chose to employ "guerrilla" tactics or relying on stealth, terrain knowledge and subterfuge to undermine and ultimately destroy the enemy.
	<<elseif $chosenTactic == "Choke Points">>
		chose to employ "choke points" tactics or the extensive use of fortified or highly defensive positions to slow down and eventually stop the enemy.
	<<elseif $chosenTactic == "Interior Lines">>
		chose to employ "interior lines" tactics or exploiting the defender's shorter front to quickly disengage and concentrate troops when and where needed.
	<<elseif $chosenTactic == "Pincer Maneuver">>
			chose to employ "pincer maneuver" tactics or attempting to encircle the enemy by faking a collapsing center front.
	<<elseif $chosenTactic == "Defense In Depth">>
		chose to employ "defense in depth" tactics or relying on mobility to disengage and exploit overextended enemy troops by attacking their freshly exposed flanks.
	<<elseif $chosenTactic == "Blitzkrieg">>
		chose to employ "blitzkrieg" tactics or shattering the enemy's front-line with a violent, concentrated armored assault.
	<<elseif $chosenTactic == "Human Wave">>
		chose to employ "human wave" tactics or overwhelming the enemy's army with a massive infantry assault.
	<</if>>
	<<if $battleTerrain == "urban">>
		<<if $chosenTactic == "Bait and Bleed">>
			The urban terrain synergized well with bait and bleed tactics, slowly chipping away at the enemy's forces from the safety of the narrow streets and empty buildings.
		<<elseif $chosenTactic == "Guerrilla">>
			The urban terrain synergized well with guerrilla tactics, eroding your enemy's determination from the safety of the narrow streets and empty buildings.
		<<elseif $chosenTactic == "Choke Points">>
			The urban environment offers many opportunities to hunker down and stop the momentum of the enemy's assault while keeping your soldiers in relative safety.
		<<elseif $chosenTactic == "Interior Lines">>
			While the urban environment offers many highly defensive position, it does restrict movement and with it the advantages of exploiting interior lines.
		<<elseif $chosenTactic == "Pincer Maneuver">>
			The urban terrain does not allow for wide maneuvers, the attempts of your forces to encircle the attackers are mostly unsuccessful.
		<<elseif $chosenTactic == "Defense In Depth">>
			While the urban environment offers many defensive positions, it limits mobility, limiting the advantages of using a defense in depth tactic.
		<<elseif $chosenTactic == "Blitzkrieg">>
			The urban terrain is difficult to traverse, making your troops attempt at a lightning strike unsuccessful.
		<<elseif $chosenTactic == "Human Wave">>
			The urban terrain offers great advantages to the defender, your men find themselves in great disadvantage while mass assaulting the enemy's position.
		<</if>>
	<<elseif $battleTerrain == "rural">>
		<<if $chosenTactic == "Bait and Bleed">>
			The open terrain of rural lands does not lend itself well to bait and bleed tactics, making it harder for your men to achieve tactical superiority.
		<<elseif $chosenTactic == "Guerrilla">>
			The open terrain of rural lands does not offer many hiding spots, making it harder for your men to perform guerrilla actions effectively.
		<<elseif $chosenTactic == "Choke Points">>
			The open terrain of rural lands does not offer many natural choke points, making it hard for your troops to funnel the enemy towards highly defended positions.
		<<elseif $chosenTactic == "Interior Lines">>
			The open terrain allows your men to easily exploit the superior mobility of the defender, making excellent use of interior lines to strike where it hurts.
		<<elseif $chosenTactic == "Pincer Maneuver">>
			The open terrain affords your men great mobility, allowing them to easily position themselves for envelopment.
		<<elseif $chosenTactic == "Defense In Depth">>
			The open terrain affords your men great mobility, allowing them to exploit overextended assaults and concentrate where and when it matters.
		<<elseif $chosenTactic == "Blitzkrieg">>
			The open terrain affords your men great mobility, making it easier to accomplish concentrated lightning strikes.
		<<elseif $chosenTactic == "Human Wave">>
			The open terrain affords your men great mobility, making it easier to overwhelm the enemy with mass assaults.
		<</if>>
	<<elseif $battleTerrain == "hills">>
		<<if $chosenTactic == "Bait and Bleed">>
			While the hills offer some protection, they also make it harder to maneuver; bait and bleed tactics will not be 100% effective here.
		<<elseif $chosenTactic == "Guerrilla">>
			The hills offer protection to both your troops and your enemy's, making it harder for your men to accomplish guerrilla attacks effectively.
		<<elseif $chosenTactic == "Choke Points">>
			While not as defensible as mountains, hills offer numerous opportunities to funnel the enemy towards highly defensible choke points.
		<<elseif $chosenTactic == "Interior Lines">>
			The limited mobility on hills hampers the capability of your troops to exploit the defender's greater mobility afforded by interior lines.
		<<elseif $chosenTactic == "Pincer Maneuver">>
			Limited mobility due to the hills is a double edged sword, affording your men a decent shot at encirclement.
		<<elseif $chosenTactic == "Defense In Depth">>
			The limited mobility on hills hampers the capability of your troops to use elastic defense tactics.
		<<elseif $chosenTactic == "Blitzkrieg">>
			The limited mobility on hills hampers the capability of your troops to organize lightning strikes.
		<<elseif $chosenTactic == "Human Wave">>
			The defensibility of hills makes it harder to accomplish victory through mass assaults.
		<</if>>
	<<elseif $battleTerrain == "coast">>
		<<if $chosenTactic == "Bait and Bleed">>
			On the coast there's little space and protection to effectively employ bait and bleed tactics.
		<<elseif $chosenTactic == "Guerrilla">>
			On the coast there's little space and protection to effectively employ guerrilla tactics.
		<<elseif $chosenTactic == "Choke Points">>
			Amphibious attacks are difficult in the best of situations; the defender has a very easy time funneling the enemy towards their key defensive positions.
		<<elseif $chosenTactic == "Interior Lines">>
			While in an amphibious landing mobility is not the defender's best weapon, exploiting interior lines still affords your troops some advantages.
		<<elseif $chosenTactic == "Pincer Maneuver">>
			Attempting to encircle a landing party is not the best course of action, but not the worst either.
		<<elseif $chosenTactic == "Defense In Depth">>
			In an amphibious assault it's very easy for the enemy to overextend, making defense in depth tactics quite effective.
		<<elseif $chosenTactic == "Blitzkrieg">>
			The rough, restricted terrain does not lend itself well to lightning strikes, but the precarious position of the enemy still gives your mobile troops tactical superiority.
		<<elseif $chosenTactic == "Human Wave">>
			The rough, restricted terrain does not lend itself well to mass assaults, but the precarious position of the enemy still gives your troops tactical superiority.
		<</if>>
	<<elseif $battleTerrain == "outskirts">>
		<<if $chosenTactic == "Bait and Bleed">>
			Fighting just beneath the walls of the arcology does not allow for the dynamic redeployment of troops bait and bleed tactics would require.
		<<elseif $chosenTactic == "Guerrilla">>
			Fighting just beneath the walls of the arcology does not allow for the dynamic redeployment of troops guerrilla tactics would require.
		<<elseif $chosenTactic == "Choke Points">>
			The imposing structure of the arcology itself provides plenty of opportunities to create fortified choke points from which to shatter the enemy assault.
		<<elseif $chosenTactic == "Interior Lines">>
			While the presence of the arcology near the battlefield is an advantage, it does limit maneuverability, lowering overall effectiveness of interior lines tactics.
		<<elseif $chosenTactic == "Pincer Maneuver">>
			While the presence of the arcology near the battlefield is an advantage, it does limit maneuverability, lowering the chances of making an effective encirclement.
		<<elseif $chosenTactic == "Defense In Depth">>
			Having the arcology near the battlefield means there are limited available maneuvers to your troops, who still needs to defend the structure, making defense in depth tactics not as effective.
		<<elseif $chosenTactic == "Blitzkrieg">>
			While an assault may save the arcology from getting involved at all, having the imposing structure so near does limit maneuverability and so the impetus of the lightning strike.
		<<elseif $chosenTactic == "Human Wave">>
			While an attack may save the arcology from getting involved at all, having the imposing structure so near does limit maneuverability and so the impetus of the mass assault.
		<</if>>
	<<elseif $battleTerrain == "mountains">>
		<<if $chosenTactic == "Bait and Bleed">>
			While the mountains offer great protection, they also limit maneuverability; bait and bleed tactics will not be quite as effective here.
		<<elseif $chosenTactic == "Guerrilla">>
			The mountains offer many excellent hiding spots and defensive positions, making guerrilla tactics very effective.
		<<elseif $chosenTactic == "Choke Points">>
			The mountains offer plenty of opportunity to build strong defensive positions from which to shatter the enemy's assault.
		<<elseif $chosenTactic == "Interior Lines">>
			While the rough terrain complicates maneuvers, the defensive advantages offered by the mountains offsets its negative impact.
		<<elseif $chosenTactic == "Pincer Maneuver">>
			The rough terrain complicates maneuvers; your men have a really hard time pulling off an effective encirclement in this environment.
		<<elseif $chosenTactic == "Defense In Depth">>
			While mobility is limited, defensive positions are plentiful; your men are not able to fully exploit overextended assaults, but are able to better resist them.
		<<elseif $chosenTactic == "Blitzkrieg">>
			The rough terrain complicates maneuvers; your men have a really hard time pulling off an effective lightning strike in this environment.
		<<elseif $chosenTactic == "Human Wave">>
			The rough terrain complicates maneuvers; your men have a really hard time pulling off an effective mass assault in this environment.
		<</if>>
	<<elseif $battleTerrain == "wasteland">>
		<<if $chosenTactic == "Bait and Bleed">>
			While the wastelands are mostly open terrain, there are enough hiding spots to make bait and bleed tactics work well enough.
		<<elseif $chosenTactic == "Guerrilla">>
			While the wastelands are mostly open terrain, there are enough hiding spots to make guerrilla tactics work well enough.
		<<elseif $chosenTactic == "Choke Points">>
			The wastelands are mostly open terrain; your men have a difficult time setting up effective fortified positions.
		<<elseif $chosenTactic == "Interior Lines">>
			The wastelands, while rough, are mostly open terrain, where your men can exploit to the maximum the superior mobility of the defender.
		<<elseif $chosenTactic == "Pincer Maneuver">>
			The wastelands, while rough, are mostly open terrain; your men can set up an effective encirclement here.
		<<elseif $chosenTactic == "Defense In Depth">>
			The wastelands, while rough, are mostly open terrain, allowing your men to liberally maneuver to exploit overextended enemies.
		<<elseif $chosenTactic == "Blitzkrieg">>
			The wastelands, while rough, are mostly open terrain, where your men are able to mount effective lightning strikes.
		<<elseif $chosenTactic == "Human Wave">>
			The wastelands, while rough, are mostly open terrain, where your men are able to mount effective mass assaults.
		<</if>>
	<</if>>

	<<if $chosenTactic == "Bait and Bleed">>
		<<if $attackType == "raiders">>
			Since the bands of raiders are used to be on high alert and on the move constantly, bait and bleed tactics are not effective against them.
		<<elseif $attackType == "free city">>
			The modern armies hired by Free Cities are decently mobile, which means quick hit and run attacks will be less successful, but their discipline and confidence still make them quite susceptible to this type of attack.
		<<elseif $attackType == "old world">>
			While old world armies are tough nuts to crack, their predictability makes them the perfect target for hit and run and harassment tactics.
		<<elseif $attackType == "freedom fighters">>
			Freedom fighters live every day as chasing and being chased by far superior forces, they are far more experienced than your troops in this type of warfare and much less susceptible to it.
		<</if>>
	<<elseif $chosenTactic == "Guerrilla">>
		<<if $attackType == "raiders">>
			Since the bands of raiders are used to be on high alert and on the move constantly, guerrilla tactics are not effective against them.
		<<elseif $attackType == "free city">>
			The modern armies hired by Free Cities are highly mobile, which means quick hit and run attacks will be less successful, but their discipline and confidence still make them quite susceptible to this type of attack.
		<<elseif $attackType == "old world">>
			While old world armies are tough nuts to crack, their predictability makes them the perfect target for hit and run and harassment tactics.
		<<elseif $attackType == "freedom fighters">>
			Freedom fighters live every day as chasing and being chased by far superior forces, they are far more experienced than your troops in this type of warfare and much less susceptible to it.
		<</if>>
	<<elseif $chosenTactic == "Choke Points">>
		<<if $attackType == "raiders">>
			Raiders lack heavy weaponry or armor, so making use of fortified positions is an excellent way to dissipate the otherwise powerful momentum of their assault.
		<<elseif $attackType == "free city">>
			The high tech equipment Free Cities can afford to give their guns for hire means there's no defensive position strong enough to stop them, still the relatively low numbers means they will have to take a careful approach, slowing them down.
		<<elseif $attackType == "old world">>
			Old world armies have both the manpower and the equipment to conquer any defensive position, making use of strong fortifications will only bring you this far against them.
		<<elseif $attackType == "freedom fighters">>
			The lack of specialized weaponry means freedom fighters have a rather hard time overcoming tough defensive positions, unfortunately they have also a lot of experience in avoiding them.
		<</if>>
	<<elseif $chosenTactic == "Interior Lines">>
		<<if $attackType == "raiders">>
			The highly mobile horde of raiders will not give much room for your troops to maneuver, lowering their tactical superiority.
		<<elseif $attackType == "free city">>
			While decently mobile, Free Cities forces are not in high enough numbers to risk maintaining prolonged contact, allowing your troops to quickly disengage and redeploy where it hurts.
		<<elseif $attackType == "old world">>
			Old world armies are not famous for the mobility, which makes them highly susceptible to any tactic that exploits maneuverability and speed.
		<<elseif $attackType == "freedom fighters">>
			While not the best equipped army, the experience and mobility typical of freedom fighters groups make them tough targets for an army that relies itself on mobility.
		<</if>>
	<<elseif $chosenTactic == "Pincer Maneuver">>
		<<if $attackType == "raiders">>
			While numerous, the undisciplined masses of raiders are easy prey for encirclements.
		<<elseif $attackType == "free city">>
			While decently mobile, the low number of Free Cities expedition forces make them good candidates for encirclements.
		<<elseif $attackType == "old world">>
			The discipline and numbers of old world armies make them quite difficult to encircle.
		<<elseif $attackType == "freedom fighters">>
			While not particularly mobile, freedom fighters are used to fight against overwhelming odds, diminishing the effectiveness of the encirclement.
		<</if>>
	<<elseif $chosenTactic == "Defense In Depth">>
		<<if $attackType == "raiders">>
			While their low discipline makes them prime candidates for an elastic defense type of strategy, their high numbers limit your troops maneuverability.
		<<elseif $attackType == "free city">>
			With their low numbers Free Cities mercenaries are quite susceptible to this type of tactic, despite their mobility.
		<<elseif $attackType == "old world">>
			With their low mobility old world armies are very susceptible to this type of strategy.
		<<elseif $attackType == "freedom fighters">>
			Low mobility and not particularly high numbers mean freedom fighters can be defeated by employing elastic defense tactics.
		<</if>>
	<<elseif $chosenTactic == "Blitzkrieg">>
		<<if $attackType == "raiders">>
			With their low discipline and lack of heavy equipment, lightning strikes are very effective against raider hordes.
		<<elseif $attackType == "free city">>
			Having good equipment and discipline on their side, Free Cities expeditions are capable of responding to even strong lightning strikes.
		<<elseif $attackType == "old world">>
			While disciplined, old world armies low mobility makes them highly susceptible to lightning strikes.
		<<elseif $attackType == "freedom fighters">>
			While not well equipped, freedom fighters have plenty of experience fighting small, mobile attacks, making them difficult to defeat with lightning strikes.
		<</if>>
	<<elseif $chosenTactic == "Human Wave">>
		<<if $attackType == "raiders">>
			The hordes of raiders are much more experienced than your soldiers in executing mass assaults and they also have a lot more bodies to throw in the grinder.
		<<elseif $attackType == "free city">>
			The good equipment and mobility of Free Cities mercenaries cannot save them from an organized mass assault.
		<<elseif $attackType == "old world">>
			Unfortunately the discipline and good equipment of old world armies allow them to respond well against a mass assault.
		<<elseif $attackType == "freedom fighters">>
			The relative low numbers and not great equipment typical of freedom fighters make them susceptible to being overwhelmed by an organized mass assault.
		<</if>>
	<</if>>
	<<if $tacticsSuccessful == 1>>
		In the end <<if $leadingTroops == "PC">>you were<<else>>your commander was<</if>> @@.green;able to successfully employ <<print $chosenTactic>> tactics,@@ greatly enhancing the efficiency of your army.
	<<else>>
		In the end <<if $leadingTroops == "PC">>you were<<else>>your commander was<</if>> @@.red;not able to effectively employ <<print $chosenTactic>> tactics,@@ greatly affecting the efficiency of your army.
	<</if>>
	<br>
	<br>
	<<include "unitsBattleReport">>

	<<if $SF.Toggle && $SF.Active >= 1 && ($SF.Squad.Firebase >= 7 || $SF.Squad.GunS >= 1 || $SF.Squad.Satellite.lv >= 5 || $SF.Squad.GiantRobot >= 6 || $SF.Squad.MissileSilo >= 1)>>
		/* SF upgrades effects */ <br><br>
		<<if $SF.Squad.Firebase >= 7>>
			The artillery pieces installed around $SF.Lower's firebase provided vital fire support to the troops in the field.
		<</if>>
		<<if $SF.Squad.GunS >= 1>>
			The gunship gave our troops an undeniable advantage in recon capabilities, air superiority and fire support.
		<</if>>
		<<if $SF.Squad.Satellite.lv >= 5 && $SF.Squad.Satellite.InOrbit > 0>>
			The devastating power of $SF.Lower's satellite was employed with great efficiency against the enemy.
		<</if>>
		<<if $SF.Squad.GiantRobot >= 6>>
			The giant robot of $SF.Lower proved to be a great boon to our troops, shielding many from the worst the enemy had to offer.
		<</if>>
		<<if $SF.Squad.MissileSilo >= 1>>
			The missile silo exterminated many enemy soldiers even before the battle would begin.
		<</if>>
	<</if>>

<</if>> /* closes check for surrender and bribery */

<br><br>

<<set _menialPrice = Math.trunc(($slaveCostFactor*1000)/100)*100>>
<<set _menialPrice = Math.clamp(_menialPrice, 500, 1500)>>

<<set _captives = Math.trunc(_captives)>>
<<if _captives > 0>>
	During the battle <<print _captives>> attackers were captured.
	/*
	<<if random(1,100) <= 25>>
		<<set _roll = random(1,100)>>
		<<if _roll <= 33>>
			Three of them have the potential to be sex slaves.
			<<set _candidates = 3>>

		<<elseif _roll <= 66>>
			Two of them have the potential to be sex slaves.
			<<set _candidates = 2>>
		<<else>>
			One of them have the potential to be sex slaves.
			<<set _candidates = 1>>
		<</if>>
	<</if>>
	*/
	<br>
	<span id="captOptions">
	<<link "sell them all immediately">>
		<<run cashX((_menialPrice * _captives), "menialTransfer")>>
		<<replace "#captOptions">>Captives sold<</replace>>
	<</link>>
	|
	<<link "Keep them as menial slaves">>
		<<set $menials += _captives>>
		<<replace "#captOptions">>Captives added as menial slaves<</replace>>
	<</link>>
	</span>
<</if>>

/* resets variables */
<<run delete $bribeCost>>
<<set $leaderWounded = 0>>
<<set $gainedWarfare = 0>>
<<set $slaveIncreasedPrestige = 0>>
<<set $woundType = 0>>
<<set $tacticsSuccessful = 0>>
<<set $attackType = "none">>
<<set $chosenTactic = "none">>
<<set $leadingTroops = "none">>
<<set $attackTroops = 0>>
<<set $attackEquip = 0>>
<<set $battleTerrain = "none">>
<<set $attackThisWeek = 0>>
<<set $enemyLosses = 0>>
<<set $losses = 0>>
<<set $battleTurns = 0>>
<<set $majorBattle = 0>>
<<set $SFIntervention = 0>>
<<set $secBots.isDeployed = 0>>
<<for _i = 0; _i < $militiaUnits.length; _i++>>
	<<set $militiaUnits[_i].isDeployed = 0>>
<</for>>
<<for _i = 0; _i < $slaveUnits.length; _i++>>
	<<set $slaveUnits[_i].isDeployed = 0>>
<</for>>
<<for _i = 0; _i < $mercUnits.length; _i++>>
	<<set $mercUnits[_i].isDeployed = 0>>
<</for>>
src/Mods/SecExp/attackReport.tw