[scenario]
#textdomain wesnoth-tb
id=1_Rooting_Out_A_Mage
name=_ "Rooting Out A Mage"
map_data="{campaigns/Two_Brothers/maps/1_Rooting_Out_A_Mage}"
turns=18
next_scenario=2_The_Chase

	[music]
		name=main_menu.ogg
		ms_before=500
	[/music]
	[music]
		name=underground.ogg
		ms_before=500
		append=yes
	[/music]
	[music]
		name=gameplay01.ogg
		ms_before=500
		append=yes
         [/music]
        [music]
                name=gameplay03.ogg
                ms_before=500
                append=yes
         [/music]

	{DUSK}
	{FIRST_WATCH}
	{SECOND_WATCH}
	{DAWN}
	{MORNING}
	{AFTERNOON}

	[event]
	name=prestart
		[objectives]
		side=1
			[objective]
			description= _ "Slay the Black Mage"
			condition=win
			[/objective]
			[objective]
			description= _ "Death of Arne"
			condition=lose
			[/objective]
			[objective]
			description= _ "Turns run out"
			condition=lose
			[/objective]
		[/objectives]
	[/event]

	[side]
		#ifdef EASY
			gold=65
		#endif
		#ifdef HARD
			gold=40
		#endif
		type=Knight
		description=Arne
		user_description= _ "Arne"
		unrenamable=yes
		{IS_HERO}
		side=1
		canrecruit=1
		controller=human
		recruit=Horseman,Bowman,Spearman,Footpad
		[unit]
			description=Bjarn
			user_description= _ "Bjarn"
			type=Red Mage
			side=1
			{IS_HERO}
			x=31
			y=21
		[/unit]

		#the armed villagers, beware them
		[unit]
			description=Peasant
			user_description= _ "Peasant"
			type=Spearman
			side=1
			x=30
			y=22
			[modifications]
				{TRAIT_QUICK}
				{TRAIT_LOYAL}
			[/modifications]
		[/unit]
		[unit]
			description=Peasant
			user_description= _ "Peasant"
			type=Spearman
			side=1
			x=30
			y=21
			[modifications]
				{TRAIT_STRONG}
				{TRAIT_LOYAL}
			[/modifications]
		[/unit]
		[unit]
			description=Peasant
			user_description= _ "Peasant"
			type=Spearman
			side=1
			x=31
			y=22
			[modifications]
				{TRAIT_INTELLIGENT}
				{TRAIT_LOYAL}
			[/modifications]
		[/unit]
		[unit]
			description=Villager
			user_description= _ "Villager"
			type=Bowman
			side=1
			x=32
			y=19
			[modifications]
				{TRAIT_STRONG}
				{TRAIT_LOYAL}
			[/modifications]
		[/unit]
		[unit]
			description=Villager
			user_description= _ "Villager"
			type=Bowman
			side=1
			x=33
			y=19
			[modifications]
				{TRAIT_QUICK}
				{TRAIT_LOYAL}
			[/modifications]
		[/unit]
		[unit]
			description=Villager
			user_description= _ "Villager"
			type=Footpad
			side=1
			x=32
			y=18
			[modifications]
				{TRAIT_RESILIENT}
				{TRAIT_LOYAL}
			[/modifications]
		[/unit]

		#Arne's mercenary band
		[unit]
			description=Erik
			user_description= _ "Erik"
			type=Horseman
			side=1
			x=33
			y=21
			[modifications]
				{TRAIT_QUICK}
				{TRAIT_LOYAL}
			[/modifications]
		[/unit]
		[unit]
			description=Heine
			user_description= _ "Heine"
			type=Horseman
			side=1
			x=32
			y=21
			[modifications]
				{TRAIT_STRONG}
				{TRAIT_LOYAL}
			[/modifications]
		[/unit]
		[unit]
			description=Magnus
			user_description= _ "Magnus"
			type=Horseman
			side=1
			x=33
			y=20
			[modifications]
				{TRAIT_RESILIENT}
				{TRAIT_LOYAL}
			[/modifications]
		[/unit]

		team_name=good
	[/side]

	[side]
		#ifdef HARD
			gold=180
		#else
			gold=100
		#endif
		type=Dark Sorcerer
		description=The Black Mage
		user_description= _ "The Black Mage"
		side=2
		canrecruit=1
		#ifdef HARD
			recruit=Skeleton,Skeleton Archer,Walking Corpse,Vampire Bat,Ghost,Dark Adept
		#else
			recruit=Skeleton,Skeleton Archer,Walking Corpse,Vampire Bat,Dark Adept
		#endif
		[ai]
			recruitment_ignore_bad_movement=yes
			grouping=no
		[/ai]
		team_name=evil
	[/side]

{STARTING_VILLAGES 1 12}
{STARTING_VILLAGES 2 5}

	[event]
		name=start
		[message]
			speaker=narrator
			message= _ "In a remote part of Wesnoth, people lived their lives working hard and caring for each other, but not knowing much about the world outside. One day, however, their peaceful world was shattered, as an evil mage came to the region, spreading havoc and despair."
		[/message]
		[message]
			speaker=narrator
			message= _ "Bjarn, the local mage of the village, was the man who saw best how to deal with this threat. He asked the help of his brother Arne, leader of a mercenary band of horsemen, and outfitted several of the villagers with gear from the armory."
			image="bjarn.png"
		[/message]
		[message]
			description=Arne
			message= _ "'ello there, Bjarn. So, what's the big fuss?"
			image="arne.png"
		[/message]
		[message]
			description=Bjarn
			message= _ "An evil mage, two days ride north, is posing a threat to our livelihoods. He is terrorizing our countryside. I've already called the village to arms and now it's up to you to lead them."
			image="bjarn.png"
		[/message]
		[message]
			description=Arne
			message= _ "Very well. We will go there and slay this source of evil. Charge, men!"
			image="arne.png"
		[/message]
		[message]
			speaker=narrator
			message= _ "After a short journey the small band of troops is close to the hideout of the evil mage."
		[/message]
		[message]
			description=Bjarn
			message= _ "I will attempt to sneak through the forest. If I can slay the evil one while he is off his guard, the battle will be over in one stroke!"
			image="bjarn.png"
		[/message]
		[kill]
			description=Bjarn
		[/kill]
	[/event]

	[event]
		name=turn 6
		[message]
			description=Arne
			message= _ "Bjarn should have been in position by now. I wonder if anything's happened to him?"
			image="arne.png"
		[/message]
	[/event]

	[event]
		name=turn 10
		[message]
			description=Arne
			message= _ "This is worrying. What's happened to Bjarn? I suppose we must slay the dark sorcerer ourselves."
			image="arne.png"
		[/message]
	[/event]

	[event]
		name=die
		[role]
			type=Spearman,Bowman,Horseman
			role=Reporter
		[/role]
		[filter]
			description=The Black Mage
		[/filter]
		[message]
			speaker=unit
			message= _ "Argh!"
		[/message]
		[message]
			description=Arne
			message= _ "Good work, men. Now, where is Bjarn?"
			image="arne.png"
		[/message]
		[message]
			speaker=unit
			message= _ "Worried about him, are you? E-he-he..hergh...gaargh. . ."
		[/message]
		[message]
			description=Arne
			message= _ "Nothing more to be had from him."
			image="arne.png"
		[/message]
		[message]
			role=Reporter
			message= _ "Sir, he's been kidnapped! I just saw some men running off with him. They looked like friends of this one."
		[/message]
		[message]
			description=Arne
			message= _ "Damn! I suppose we have to go after him, then."
			image="arne.png"
		[/message]
		[endlevel]
			result=victory
			bonus=yes
		[/endlevel]
	[/event]

	#you lose
	[event]
	name=time over
		[message]
			description=The Black Mage
			message= _ "Ha, so you thought to send a mage around and stab me in the back? Well, I have news for you. We've kidnapped him!"
		[/message]
		[message]
			description=Arne
			message= _ "What? Bjarn kidnapped? And the black mage still ravages the land? Noooo!"
			image="arne.png"
		[/message]
	[/event]

	#When you attack
	[event]
		name=attack
		[filter_second]
			side=2
		[/filter_second]
		[message]
			description=Arne
			message= _ "I hear these creatures are near immune to our weapons, let us see!"
			image="arne.png"
		[/message]
	[/event]

	#Arne saying some bravado
	[event]
		name=die
		[filter_second]
			description=Arne
		[/filter_second]
		[message]
			speaker=second_unit
			message= _ "That wasn't so hard!"
			image="arne.png"
		[/message]
	[/event]

	[event]
		name=die
		[filter]
			description=Arne
		[/filter]
		[message]
			description=Arne
			message= _ "Everything is lost now that I am dead..."
			image="arne.png"
		[/message]
		[endlevel]
			result=defeat
		[/endlevel]
	[/event]

[/scenario]
