#textdomain wesnoth-nr
[scenario]
	id=slave_of_undead
	name= _ "Slave of the Undead"


	[story]

	[part]
	story= _ "Having completed his mission, Tallin reported back to his master."
	[/part]

	[part]
	story= _ "Well done, my loyal slave. I see you have successfully completed your mission."
	background=portraits/Malifor.jpg
	[/part]

	[part]
	story= _ "Yes, master."
	background=portraits/Tallin-Evil.jpg
	[/part]

	[part]
	story= _ "Very well. Now, I have a new mission for you. Your old friends are becoming a bit of an annoyance. Instead of just giving up as they should, they keep foolishly attempting to attack me time and again. This time they have attacked and seized one of the northern entrances. Although I can easily defeat them as I have done several times when you were in training, this time I want you to take care of them in a more...final way. Consider it a test of your loyalty."
	background=portraits/Malifor.jpg
	[/part]

	[part]
	story= _ "...as you command ...Master."
	background=portraits/Tallin-Evil.jpg
	[/part]

	[part]
	story= _ "Good boy. Now, I am giving you the power to raise more powerful types of undead. In addition, I will put under you command a few disembodied spirits as well as some of my more promising adepts. Use them wisely. Now, go and destroy those vermin!"
	background=portraits/Malifor.jpg
	[/part]

	[part]
	story= _ "Upon hearing the order of his master to kill his friends, something that had been dormant inside Tallin these last few months revolted. But the magical control that Malifor had over him was so great that he had no choice but to obey his master. Thus, with his own will madly struggling to break free of the lich, Talliln made his way to the northern entrance."
	[/part]
	[/story]

	map_data="{campaigns/Northern_Rebirth/maps/slave_of_the_undead.map}"

	{TURNS4 45 41 38 35}
	{UNDERGROUND}

	next_scenario=protecting_the_master

	[event]
		name=prestart
		[objectives]
		side=1
			[objective]
			condition=win
			description=_ "Destroy the Invaders"
			[/objective]
			[objective]
			condition=lose
			description=_ "Death of Tallin"
			[/objective]
			[objective]
			condition=lose
			description=_ "Turns run out"
			[/objective]
		[/objectives]
	[/event]


	[side]
		type=Peasant
		description=Tallin
		canrecruit=1
		side=1
		controller=human
		gold=100
		recruit=Walking Corpse,Skeleton,Skeleton Archer
		team_name=mob
		[/side]

		[side]
		type=Swordsman
		description=Friend
		canrecruit=1
		side=2
		{GOLD4 100 150 200 250}
		recruit=Thug,Poacher,Peasant,Footpad
		[ai]
		recruitment_pattern=fighter,fighter,fighter,archer
		[/ai]

		[village]
		x=11
		y=2
		[/village]

		[village]
		x=19
		y=2
		[/village]

		[village]
		x=10
		y=8
		[/village]

		[village]
		x=20
		y=8
		[/village]
		[/side]


	[event]
		name=start
		[kill]
		description=Friend
		[/kill]

		[unit]
		type=$betrayed_friend.type
		side=2
		x=15
		y=3
		description=Betrayed Friend
		user_description=$betrayed_friend.user_description
		canrecruit=1
		experience=$betrayed_friend.experience
		hitpoints=$betrayed_friend.hitpoints
		[/unit]


		[unit]
		type=Dwarvish Stalwart
		x=15
		y=10
		side=2
		ai_special=guardian
		[/unit]

		[unit]
		type=Bandit
		x=12
		y=7
		side=2
		ai_special=guardian
		[/unit]

		[unit]
		type=Bandit
		x=18
		y=7
		side=2
		ai_special=guardian
		[/unit]

		[unit]
		type=Poacher
		x=13
		y=7
		side=2
		ai_special=guardian
		[/unit]

		[unit]
		type=Thug
		x=11
		y=7
		side=2
		ai_special=guardian
		[/unit]

		[unit]
		type=Poacher
		x=17
		y=7
		side=2
		ai_special=guardian
		[/unit]

		[unit]
		type=Thug
		x=19
		y=7
		side=2
		ai_special=guardian
		[/unit]

		[unit]
		type=Dwarvish Fighter
		x=14
		y=9
		side=2
		ai_special=guardian
		[/unit]

		[unit]
		type=Dwarvish Thunderer
		x=15
		y=9
		side=2
		ai_special=guardian
		[/unit]

		[unit]
		type=Dwarvish Fighter
		x=16
		y=9
		side=2
		ai_special=guardian
		[/unit]

		[unit]
		type=Dwarvish Steelclad
		x=16
		y=4
		side=2
		[/unit]

		[unit]
		type=Bandit
		x=14
		y=4
		side=2
		[/unit]

		[unit]
		type=Trapper
		x=15
		y=4
		side=2
		[/unit]

		[unit]
		type=Swordsman
		x=16
		y=3
		side=2
		[/unit]

		[unit]
		type=Ghost
		x=14
		y=25
		side=1
		[/unit]

		[unit]
		type=Ghost
		x=16
		y=25
		side=1
		[/unit]

		[unit]
		type=Ghost
		x=15
		y=26
		side=1
		[/unit]

		[unit]
		type=Dark Adept
		description=James
		x=14
		y=26
		side=1
		[/unit]

		[unit]
		type=Dark Adept
		description=Aledor
		x=16
		y=26
		side=1
		[/unit]

		[message]
		description=Betrayed Friend
		message= _ "My God! Tallin is that you?"
		[/message]

		[message]
		description=Tallin
		image=portraits/Tallin-Evil.jpg
		message= _ " $betrayed_friend.user_description, I..."
		[/message]

		[message]
		description=Betrayed Friend
		message= _ "Come on Tallin, talk to me!"
		[/message]

		[message]
		description=Tallin
	image=portraits/Tallin-Evil.jpg
		message= _ ".........."
		[/message]

		[message]
		description=Betrayed Friend
		message= _ "Tallin, break free! Don't let that lich control you!"
		[/message]

		[message]
		description=Tallin
	image=portraits/Tallin-Evil.jpg
		message= _ "... KILL THE RABBLE!"
		[/message]

		[message]
		description=Betrayed Friend
		message= _ "No, Tallin! Stop!"
		[/message]

		[message]
		speaker=narrator
		message= _ "Deaf to the calls of his friend, Tallin commenced the attack."
		[/message]

	[/event]


	[event]
		name=die
		[filter]
		description=Tallin
		[/filter]

		[message]
		description=Tallin
	image=portraits/Tallin-Evil.jpg
		message= _ "Argh! I have failed my master."
		[/message]

		[endlevel]
		result=defeat
		[/endlevel]
	[/event]

	[event]
		name=victory
		{CLEAR_VARIABLE betrayed_friend}
		[message]
		description=Tallin
	image=portraits/Tallin-Evil.jpg
		message= _ "What have I done..."
		[/message]
	[/event]

	[event]
		name=time over

		[move_unit_fake]
		type=Ancient Lich
		x=20,20,20,19,18
		y=30,29,28,28,27
		[/move_unit_fake]

		[unit]
		type=Ancient Lich
		description=Malifor
		x=18
		y=27
		side=2
		[/unit]

		[message]
		description=Malifor
		message= _ "You fool! You have spared the humans and betrayed me! But I am not concerned, I had already foreseen that possibility."
		[/message]

			[scroll]
				x=5
				y=0
			[/scroll]
			[delay]
				time=10
			[/delay]
			[scroll]
				x=-10
				y=0
			[/scroll]
			[delay]
				time=10
			[/delay]
			[scroll]
				x=0
				y=5
			[/scroll]
			[delay]
				time=10
			[/delay]
			[scroll]
				x=0
				y=-10
			[/scroll]

		[message]
		description=Betrayed Friend
		message= _ "What the... everybody get out! The roof of the cave is collapsing!"
		[/message]

		[message]
		description=Malifor
		message= _ "HAHAHAHAHA!"
		[/message]

		[kill]
		description=Malifor
		[/kill]

		[move_unit_fake]
		type=Ancient Lich
		x=18,19,20,20,20
		y=27,28,28,29,30
		[/move_unit_fake]


		[terrain]
		x=2-29
		y=2-29
		letter=Xu
		[/terrain]
	[/event]

	[event]
		name=defeat
		[message]
		description=Tallin
	image=portraits/Tallin-Evil.jpg
		message= _ "Ahhhh!"
		[/message]

		[kill]
		side=1
		animate=yes
		[/kill]
	[/event]
[/scenario]


