[scenario]
	id="Civil_War"
	#textdomain wesnoth-sotbe
	name= _ "Civil War"
	map_data="{campaigns/Son_Of_The_Black_Eye/maps/Civil_War.map}"
	
	{TURNS 38 25 22}

	victory_when_enemies_defeated="no"
	{SCENARIO_MUSIC "underground.ogg"}
	
	{MORNING}
	{AFTERNOON}
	{DUSK}
	{FIRST_WATCH}
	{SECOND_WATCH}
	{DAWN}

	next_scenario="Coward"
	
	[event]
	name=prestart
		[objectives]
		side=1
			[objective]
			condition=win
			description=_ "Defeat all rebel leaders and..."
			[/objective]
			[objective]
			condition=win
			description=_ "Move Kapou'e to the end of the signpost at the southwest"
			[/objective]
			[objective]
			condition=lose
			description=_ "Death of Kapou'e"
			[/objective]
			[objective]
				description= _ "Death of Grüü"
				condition=lose
			[/objective]
			[objective]
			condition=lose
			description=_ "Turns run out"
			[/objective]
		[/objectives]
	[/event]

	[item]
	x=6
	y=30
	image=scenery/signpost.png
	[/item]

	[side]
	type=Orcish Leader
	description=Kapou'e
	user_description= _ "Kapou'e"
	side=1
	canrecruit=1
	controller=human
	recruit= Wolf Rider, Orcish Grunt, Troll Whelp, Orcish Archer, Saurian Skirmisher
	team_name=Kapoue
	gold=100
	{BLACK_FLAG}
	[/side]

	[side]
	type=Orcish Warlord
	description=Braga
	user_description= _ "Braga"
	side=2
	canrecruit=1
	recruit=Goblin Knight, Orcish Warrior, Orcish Crossbowman
	{GOLD 200 220 240}
	team_name=rebels
	[/side]

	[side]
	type=Orcish Warlord
	description=Meato
	user_description= _ "Meato"
	side=3
	canrecruit=1
	recruit=Goblin Knight, Orcish Warrior, Orcish Crossbowman
	{GOLD 200 220 240}
	team_name=rebels
	[/side]

	[side]
	type=Orcish Warlord
	description=Ragvan
	user_description= _ "Ragvan"
	side=4
	canrecruit=1
	recruit=Goblin Knight, Orcish Warrior, Orcish Crossbowman
	{GOLD 200 220 240}
	team_name=rebels
	[/side]


	[story]
		[part]
		story= _ "Infuriated by the murder of the shamans, the orcish horde massacred the humans and their allies. In their rage, they scoured the snow for hours looking for any survivors. Only when their rage was spent did the full implications of the shamans' deaths begin to sink in."
		background=sotbe.png
		[/part]

		[part]
		story= _ "With the Council broken, there was now nothing left to hold the orcish forces together. And if the orcish forces began to fight amongst themselves as they so often did, then the humans would eradicate them with ease."
		background=sotbe.png
		[/part]

		[part]
		story= _ "Kapou'e vowed that this would not happen. Events had the smell of a treacherous plot aimed at destroying the unity of the orcs. Furthermore, if the tree-shagger was to be trusted, then Shum Taum the Smug was behind it all. What an orc expected to gain from destroying his own race was beyond Kapou'e, but he decided to march to Bitok personally and confront the traitor. Bitok being was on the far side of orcish territory, this would also give him a good chance to clobber the orcs together again - the old fashioned way."
		background=sotbe.png
		[/part]

		[part]
		story= _ "Furthermore, the troops who had been led by Kapou'e this far had grown to respect him as a wise and capable leader, and they proclaimed their loyalty to him. Delighted, Kapou'e sent detachments off in different directions to bring in the other tribes, by force if necessary. Al'Brock was sent west, along the route that Kapou'e had used to flee the human forces almost a year before. Flar'Tar was sent directly south to rally the tribes along the Mountains of Haag and the eastern Mourned Hills. Kapou'e himself made a direct southwest beeline towards Bitok. They were all to meet in Dorset that spring to repel the human attack that seemed certain to come."
		background=sotbe.png
		[/part]

		[part]
		story= _ "Having thus made his plans, Kapou'e set out for Bitok to get to the root of this treachery."
		background=sotbe.png
		[/part]

		
		
	[/story]


	[event]
	name=start
	
	{RECALL Grüü}
	{RECALL Inarix}

	[message]
	description=Kapou'e
	message= _ "If we are going to make it to Bitok, and then back to Dorset before spring we have to get a move on. Break camp as soon as possible. Destroy all opposition in your path, I want this area to be firmly under my control by the time we are through here."
	[/message]

	[/event]


	[event]
	name=die
		[filter]
		description=Kapou'e
		[/filter]
		[message]
		speaker=unit
		message= _ "Argh! I'm done. My people are doomed!"
		[/message]
		[endlevel]
		result=defeat
		[/endlevel]
	[/event]

	[event]
	name=die

		[filter]
		description=Braga
		[/filter]
	
		[set_variable]
		name=Braga_dead
		value=1
		[/set_variable]

	[message]
	speaker=second_unit
	message= _ "This rabble won't be a problem anymore."		
	[/message]

	[/event]

	[event]
	name=die

		[filter]
		description=Meato
		[/filter]
	
		[set_variable]
		name=Meato_dead
		value=1
		[/set_variable]

	[message]
	speaker=second_unit
	message= _ "Got this tribe under control."		
	[/message]

	[/event]

	[event]
	name=die

		[filter]
		description=Ragvan
		[/filter]
	
		[set_variable]
		name=Ragvan_dead
		value=1
		[/set_variable]

	[message]
	speaker=second_unit
	message= _ "This is what you get for deserting the Son of the Black-Eye."		
	[/message]

	[/event]

	[event]
	name=moveto
	first_time_only=no
	
		[filter]
		x=6
		y=30
		description=Kapou'e
		[/filter]

	[if]
	[variable]
	name=Braga_dead
	numerical_equals=1
	[/variable]

	[then]
	
	[if]
	[variable]
	name=Ragvan_dead
	numerical_equals=1
	[/variable]

	[then]
	
	[if]
	[variable]
	name=Meato_dead
	numerical_equals=1
	[/variable]

	[then]
	
	[endlevel]
	result=victory
	bonus=yes
	[/endlevel]

	{CLEAR_VARIABLE Braga_dead}
	{CLEAR_VARIABLE Meato_dead}
	{CLEAR_VARIABLE Ragvan_dead} 

	[/then]
	[/if]
	[/then]
	[/if]
	[/then]
	[/if]

	[/event]

	{@campaigns/Son_Of_The_Black_Eye/scenarios/utils/deaths.cfg}

[/scenario]
