:: Agent Retrieve [nobr]

<<silently>>

<<for $i to 0; $i < $slaves.length; $i++>>
<<if $slaves[$i].ID == $activeArcology.leaderID>>
	<<for $j to 0; $j < $slaves.length; $j++>>
	<<if $slaves[$j].assignment == "live with your agent">>
	<<if $slaves[$j].ID == $slaves[$i].relationshipTarget>>
		<<set $slaves[$j].assignment = "rest">>
		<<set $slaves[$j].assignmentVisible = 1>>
		<<set $slaves[$j].sentence = 0>>
		<<break>>
	<</if>>
	<</if>>
	<</for>>
	<<if $slaves[$i].preg > 35>>
		<<set $slaves[$i].birthsTotal += $slaves[$i].pregType>>
		<<set $slaves[$i].preg = 0>>
		<<set $slaves[$i].pregSource = 0>>
		<<set $slaves[$i].pregType = 0>>
	<</if>>
	<<set $slaves[$i].assignment = "rest">>
	<<set $slaves[$i].assignmentVisible = 1>>
	<<set $slaves[$i].sentence = 0>>
	<<break>>
<</if>>
<</for>>

<<set $activeArcology.leaderID = 0>>
<<set $activeArcology.government = "your trustees">>

<<for _i to 0;_i < $leaders.length;_i++>>
<<if $activeArcology.leaderID == $leaders[_i].ID>>
	<<set $dump to $leaders.pluck([_i], [_i])>>
	<<break>>
<</if>>
<</for>>

<<goto "Neighbor Interact">>

<</silently>>

src/npc/agent/agentRetrieve.tw