#textdomain wesnoth-httt
[scenario]
    id=19c_Cliffs_of_Thoria
    name= _ "The Cliffs of Thoria"
    map_data="{campaigns/Heir_To_The_Throne/maps/19c_Cliffs_of_Thoria.map}"

    {SCENARIO_MUSIC "battle.ogg"}
    {VICTORY_AND_DEFEAT_MUSIC}
    {TURNS 55 45 35}

    next_scenario="20b_Underground_Channels"
    victory_when_enemies_defeated=no

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

    {BIGMAP_CLIFFS_OF_THORIA}

    {PLACE_IMAGE items/gohere.png 55 3}
    {PLACE_IMAGE scenery/shipwreck-1.png 43 5}
    {PLACE_IMAGE scenery/wreck.png 46 13}
    {PLACE_IMAGE scenery/shipwreck-1.png 5 8}
    {PLACE_IMAGE scenery/wreck.png 10 17}
    {PLACE_IMAGE scenery/shipwreck-1.png 44 17}
    {PLACE_IMAGE scenery/shipwreck-1.png 52 18}
    {PLACE_IMAGE scenery/shipwreck-1.png 21 12}
    {PLACE_IMAGE scenery/wreck.png 25 5}
    {PLACE_IMAGE scenery/wreck.png 3 4}
    {PLACE_IMAGE scenery/shipwreck-1.png 8 13}
    {PLACE_IMAGE scenery/wreck.png 17 8}
    {PLACE_IMAGE scenery/wreck.png 12 8}
    {PLACE_IMAGE scenery/shipwreck-1.png 14 12}
    {PLACE_IMAGE scenery/wreck.png 48 6}
    {PLACE_IMAGE scenery/shipwreck-1.png 51 4}
    {PLACE_IMAGE scenery/wreck.png 48 19}
    {PLACE_IMAGE scenery/wreck.png 48 6}
    {PLACE_IMAGE scenery/shipwreck-1.png 21 6}
    {PLACE_IMAGE scenery/shipwreck-1.png 13 3}
    {PLACE_IMAGE scenery/wreck.png 18 13}
    {PLACE_IMAGE scenery/shipwreck-1.png 39 2}
    {PLACE_IMAGE scenery/shipwreck-1.png 40 16}
    {PLACE_IMAGE scenery/wreck.png 39 13}
    {PLACE_IMAGE scenery/shipwreck-1.png 32 2}
    {PLACE_IMAGE scenery/shipwreck-1.png 42 10}
    {PLACE_IMAGE scenery/wreck.png 33 14}
    {PLACE_IMAGE scenery/shipwreck-1.png 26 8}
    {PLACE_IMAGE scenery/wreck.png 33 14}
    {PLACE_IMAGE scenery/wreck.png 40 7}
    {PLACE_IMAGE scenery/wreck.png 29 10}
    {PLACE_IMAGE scenery/wreck.png 32 6}
    {PLACE_IMAGE scenery/shipwreck-1.png 24 15}
    {PLACE_IMAGE scenery/shipwreck-1.png 35 9}

    {WATERFALL_MASK 55 1}
    {WATERFALL_MASK 55 2}
    {WATERFALL_MASK 55 3}
    {WATERFALL_MASK 55 4}
    {WATERFALL_MASK 55 5}
    {WATERFALL_MASK 54 1}
    {WATERFALL_MASK 54 2}
    {WATERFALL_MASK 54 3}
    {WATERFALL_MASK 54 4}
    {WATERFALL_MASK 54 5}

    [event]
        name=prestart
        [objectives]
            side=1
            [objective]
                description= _ "Make it to the end of the river"
                condition=win
            [/objective]
            [objective]
                description= _ "Death of Konrad"
                condition=lose
            [/objective]
            [objective]
                description= _ "Death of Delfador"
                condition=lose
            [/objective]
            [objective]
                description= _ "Death of Li'sar"
                condition=lose
            [/objective]
            [objective]
                description= _ "Death of Kalenz"
                condition=lose
            [/objective]
            [objective]
                description= _ "Turns run out"
                condition=lose
            [/objective]
        [/objectives]
    [/event]

    {campaigns/Heir_To_The_Throne/utils/deaths.cfg}

    [side]
        type=Commander
        description=Konrad
        user_description= _ "Konrad"
        unrenamable=yes
        side=1
        canrecruit=yes
        controller=human
        team_name=elves
        gold=250
        fog=yes
        shroud=no
        share_maps=no
        share_view=no
    [/side]

    [side]
        side=2
        no_leader=yes
        controller=ai
        canrecruit=no
        [ai]
            {ATTACK_DEPTH 5 5 6}
            [avoid]
                x=1-40,14-19,44-55,41-43
                y=15-22,13-14,11-22,14-22
            [/avoid]
            passive_leader=yes
        [/ai]
        team_name=drakes
    [/side]

    [side]
        side=3
        no_leader=yes
        controller=ai
        canrecruit=no
        [ai]
            {ATTACK_DEPTH 5 5 6}
            [avoid]
                x=1-55,40-55
                y=1-14,16-22
            [/avoid]
        [/ai]
        team_name=undead
    [/side]

    [side]
        side=4
        no_leader=yes
        controller=ai
        canrecruit=no
        [ai]
            {ATTACK_DEPTH 5 5 6}
            [avoid]
                x=1-55,1-44,1-41
                y=1-11,12-13,14-22
            [/avoid]
        [/ai]
        team_name=monsters
    [/side]

    [side]
        side=5
        no_leader=yes
        controller=ai
        canrecruit=no
        team_name=elves
    [/side]

    [event]
        name=start
        #For Home of the Northern Elves: where do we come from?
        #the position where we are - upassable muntains,swamp, looking for a way out
        #the sunk loyalist fleet with the flag of wesnoth
        #the converstion with the drakes
        [set_variable]
            name=A_Choice_Was_Made
            value=c
        [/set_variable]
        [role]
            role=merman-advisor
            type=Merman Triton,Merman Hoplite,Mermaid Diviner,Siren,Merman Javelineer,Merman Entangler,Merman Warrior,Mermaid Priestess,Mermaid Enchantress,Merman Spearman,Merman Netcaster,Merman Fighter,Mermaid Initiate,Merman Hunter
        [/role]
        [recall]
            role=merman-advisor
        [/recall]
        [recall]
            description=Delfador
        [/recall]
        [recall]
            description=Kalenz
        [/recall]
        [recall]
            description="Li'sar"
        [/recall]

        {VARIABLE dwelling_1 active}
        {VARIABLE dwelling_2 active}
        {VARIABLE dwelling_3 active}
        {VARIABLE dwelling_4 active}
        {VARIABLE dwelling_5 active}
        {VARIABLE dwelling_6 active}
        {VARIABLE dwelling_7 active}
        {VARIABLE dwelling_8 active}
        {VARIABLE dwelling_9 active}
        {VARIABLE dwelling_10 active}
        {VARIABLE dwelling_11 active}
        {VARIABLE dwelling_12 active}
        {VARIABLE waterfall_sighted no}
        {VARIABLE undead_killed no}
        {OBJ_TRIDENT_STORM 17 11 cot_stormtrident}
        {PLACE_IMAGE items/gohere.png 55 3}

        {PLACE_IMAGE scenery/tent-fancy-red.png 10 1}
        {PLACE_IMAGE scenery/tent-fancy-red.png 12 10}
        {PLACE_IMAGE scenery/tent-fancy-red.png 16 6}
        {PLACE_IMAGE scenery/tent-fancy-red.png 22 7}
        {PLACE_IMAGE scenery/tent-fancy-red.png 23 13}
        {PLACE_IMAGE scenery/tent-fancy-red.png 28 9}
        {PLACE_IMAGE scenery/tent-fancy-red.png 31 5}
        {PLACE_IMAGE scenery/tent-fancy-red.png 34 12}
        {PLACE_IMAGE scenery/tent-fancy-red.png 38 7}
        {PLACE_IMAGE scenery/tent-fancy-red.png 41 12}
        {PLACE_IMAGE scenery/tent-fancy-red.png 46 9}
        {PLACE_IMAGE scenery/tent-fancy-red.png 53 7}

        {UNDEAD_GUARDIAN Draug 2 17}
        {UNDEAD_GUARDIAN Draug 4 17}
        {UNDEAD_GUARDIAN Draug 6 17}
        {UNDEAD_GUARDIAN Draug 8 17}
        {UNDEAD_GUARDIAN Draug 10 17}
        {UNDEAD_GUARDIAN Draug 12 16}
        {UNDEAD_GUARDIAN Draug 14 16}
        {UNDEAD_GUARDIAN Draug 16 15}
        {UNDEAD_GUARDIAN Draug 18 16}
        {UNDEAD_GUARDIAN Draug 20 16}
        {UNDEAD_GUARDIAN Draug 22 17}
        {UNDEAD_GUARDIAN Draug 24 17}
        {UNDEAD_GUARDIAN Draug 26 17}
        {UNDEAD_GUARDIAN Draug 28 17}
        {UNDEAD_GUARDIAN Draug 30 17}
        {UNDEAD_GUARDIAN Draug 32 17}
        {UNDEAD_GUARDIAN Draug 34 17}
        {UNDEAD_GUARDIAN Draug 36 17}
        {UNDEAD_GUARDIAN Draug 38 17}

        {MODIFY_UNIT side=3 movement_costs.deep_water 99}
        {MODIFY_UNIT side=3 movement_costs.shallow_water 99}
        {MODIFY_UNIT side=3 movement_costs.swamp_water 99}
    [/event]

    [event]
        name=start
        [unit]
            type=Injured Sergeant
            side=5
            x=45
            y=16
            description=Warven
            user_description= _ "Warven"
            hitpoints=1
            [modifications]
                {TRAIT_LOYAL}
                {TRAIT_FEARLESS}
            [/modifications]
            [status]
                poisoned=on
            [/status]
        [/unit]
        [message]
            speaker=narrator
            image=wesnoth-icon.png
            message= _ "The party traveled up the river for days, sometimes walking through the shallow watter, sometimes swimming, helped by the Merfolk."
        [/message]
        [message]
            speaker=narrator
            image=wesnoth-icon.png
            message= _ "One day they saw a gruesome sight - a fleet of ships sunk or shattered among the river islands. Konrad sent some of the mermen to investigate."
        [/message]
        [message]
            role=merman-advisor
            message= _ "It seems like the ships were sunk in battle, not by a storm. Those that were not capsized have been burned. The battle must have taken place not long ago, perhaps only a few weeks past. We've found no survivors. One more thing...all the sunk ships fly the banner of the Crown of Wesnoth."
        [/message]
        [message]
            description=Delfador
            message= _ "Haven't you found any enemy ships, ones the Wesnothians were fighting against?"
        [/message]
        [message]
            role=merman-advisor
            message= _ "No we have not. If there were any, they are long gone."
        [/message]
        [message]
            description="Li'sar"
            message= _ "Perhaps the monsters Lord Kalenz alluded to sunk the ships."
        [/message]
        [message]
            description=Kalenz
            message= _ "That is possible..."
        [/message]
        [message]
            description=Konrad
            message= _ "What do we do next? How much more of the river do we still have to travel?"
        [/message]
        [message]
            description=Delfador
            message= _ "The mountains north of the river are impassable. Perhaps we should try moving south, to the swamps."
        [/message]
        [message]
            description=Kalenz
            message= _ "I don't recommend it. Long ago, a lich who was at war with my people appointed some of his most powerful minions to guard the swamps. We must not go that way!"
        [/message]
        [message]
            description="Li'sar"
            message= _ "Then we have only two choices: to proceed up the river or to go back where we came from and fight our way through the Orcs or the Undead."
        [/message]
        [message]
            description=Delfador
            message= _ "We certainly have no time to go back! We must hurry to the home of the North Elves, to meet with our Elven allies."
        [/message]
        [message]
            description=Konrad
            message= _ "Delfador is right. We must go on!"
        [/message]
        [delay]
            time=5000
        [/delay]
        [move_unit_fake]
            type=Armageddon Drake
            x=28,4
            y=9,9
            side=2
        [/move_unit_fake]
        [unit]
            type=Armageddon Drake
            facing=sw
            side=2
            x=4
            y=9
            canrecruit=yes
            description=Keh Ohn
            user_description= _ "Keh Ohn"
            ai_special=guardian
            [modifications]
                {TRAIT_RESILIENT}
                {TRAIT_DEXTROUS}
            [/modifications]
        [/unit]
        [message]
            description=Konrad
            message= _ "Oh my! A monster!"
        [/message]
        [message]
            description="Li'sar"
            message= _ "A dragon! A big one!"
        [/message]
        [message]
            description=Keh Ohn
            message= _ "I am Keh Ohn, leader of the Drakes who have settled upon these cliffs. Who are you?"
        [/message]
        [message]
            description=Konrad
            message= _ "A talking dragon?"
        [/message]
        [message]
            description="Li'sar"
            message= _ "I am beginning to understand why you were talking about monsters on our way here, Lord Kalenz."
        [/message]
        [message]
            role=merman-advisor
            message= _ "With all due respect, Your Highnesses, you are both wrong. This is not a dragon. This is a drake."
        [/message]
        [message]
            description=Delfador
            message= _ "Here? But, Drakes have never been seen in Wesnoth before... Are you certain of this?"
        [/message]
        [message]
            role=merman-advisor
            message= _ "I was born in the Bay of Pearls and spent my entire life on the Eastern Shore. But I have spoken with those who have traveled the Western Ocean and met drakes on their journeys. Therefore, I am certain beyond doubt that the creature flying in front of us is a drake, Delfador. Concerning the drakes having never been seen in Wesnoth, must I remind you that we are not in Wesnoth anymore? There are many unthinkable things and creatures which can be found outside of Wesnoth."
        [/message]
        [message]
            description=Keh Ohn
            message= _ "GRROAR!! Will you self-oriented creatures finally show some manners and pay some attention to me?"
        [/message]
        [message]
            description=Konrad
            message= _ "Eh... well of course, Sir Drake. Let me introduce myself - I am Prince Konrad, leader of the group and heir to the throne of Wesnoth."
        [/message]
        [message]
            description="Li'sar"
            message= _ "And I am Princess Li'sar, the only daughter of the late King Garard II and Queen Asheviere. I too am an heir to the throne of Wesnoth!"
        [/message]
        [message]
            description=Keh Ohn
            message= _ "(releasing a torrent of fire towards Konrad and Li'sar)
Soooo... It is you who sent your subordinates to attack us. Now when we've destroyed them, you come to do the job yourselves."
        [/message]
        [message]
            description=Konrad
            message= _ "No...There is an ongoing civil war amongst us humans. The ships were sent by our enemies, not by us, even if they were Wesnothian ships."
        [/message]
        [message]
            description=Kalenz
            message= _ "The Prince speaks the truth."
        [/message]
        [message]
            description=Keh Ohn
            message= _ "I don't know. Maybe you are telling the truth, maybe not. We Drakes don't trust you. Many of our warriors died in the battle and many more are still healing their wounds, but we still have claws. Go back now and leave us in peace. If you go further we'll be forced to show them."
        [/message]
        [message]
            description=Delfador
            message= _ "But we can not go back. We are on an important mission."
        [/message]
        [message]
            description=Keh Ohn
            message= _ "If you defy my warning - prepare for battle."
        [/message]
        [message]
            description=Konrad
            message= _ "So be it. We have to go up the river; we have no choice. We'll fight our way through if necessary."
        [/message]
        [message]
            description=Keh Ohn
            message= _ "You will regret challenging us. Drakes, to arms!"
        [/message]
        [delay]
            time=500
        [/delay]
        [kill]
            x=4
            y=9
            animate=no
        [/kill]
        [move_unit_fake]
            type=Armageddon Drake
            x=4,28
            y=9,9
            side=2
        [/move_unit_fake]
        [unit]
            type=Armageddon Drake
            side=2
            x=28
            y=9
            canrecruit=yes
            description=Keh Ohn
            user_description= _ "Keh Ohn"
            ai_special=guardian
            [modifications]
                {TRAIT_RESILIENT}
                {TRAIT_DEXTROUS}
            [/modifications]
        [/unit]
    [/event]

    [event]
        name=start
        [store_locations]
            terrain=*^V*	# wmllint: ignore
            [and]
                x=14
                y=9
                radius=10
            [/and]
            variable=temp_starting_villages_area
        [/store_locations]

        {FOREACH temp_starting_villages_area i}
        [capture_village]
            side=2
            x,y=$temp_starting_villages_area[$i].x,$temp_starting_villages_area[$i].y
        [/capture_village]
        {NEXT i}

        {CLEAR_VARIABLE temp_starting_villages_area}
    [/event]

    [event]
        name=start
        [store_locations]
            terrain=*^V*	# wmllint: ignore
            [and]
                x=34
                y=7
                radius=10
            [/and]
            variable=temp_starting_villages_area
        [/store_locations]

        {FOREACH temp_starting_villages_area i}
        [capture_village]
            side=2
            x,y=$temp_starting_villages_area[$i].x,$temp_starting_villages_area[$i].y
        [/capture_village]
        {NEXT i}

        {CLEAR_VARIABLE temp_starting_villages_area}
    [/event]

    [event]
        name=die
        first_time_only=no
        [filter]
            side=3
        [/filter]
        [kill]
            x=$x1
            y=$y1
            animate=yes
        [/kill]

        {UNDEAD_GUARDIAN Draug $x1 $y1}

        {MODIFY_UNIT side=3 movement_costs.shallow_water 99}
        {MODIFY_UNIT side=3 movement_costs.deep_water 99}
        {MODIFY_UNIT side=3 movement_costs.swamp_water 99}
        {MODIFY_UNIT side=3 movement_costs.forest 99}

        [if]
            {CHECK_VARIABLE undead_killed no}

            [then]
                [message]
                    speaker=second_unit
                    message= _ "I slew the undead monster but somehow it has revived! Dark magic is stirring around us!"
                [/message]
                [message]
                    description=Kalenz
                    message= _ "Those are some of the monsters I warned about. Such undead guardians are indestructable. We must find another way to go."
                [/message]

                {VARIABLE undead_killed yes}
            [/then]
        [/if]
    [/event]

    [event]
        name=moveto
        [filter]
            x=12
            y=10
            side=1
        [/filter]

        {VARIABLE dwelling_1 destroyed}

        {RANDOM 10..50}

        [gold]
            side=1
            amount=+$random
        [/gold]
        [message]
            speaker=unit
            message= _ "We've found $random gold in the Drake base."
            image=items/gold-coins-medium.png
        [/message]

        {REMOVE_IMAGE 12 10}

        {PLACE_IMAGE scenery/village-human-burned4.png 12 10}

        {CLEAR_VARIABLE random}
    [/event]

    [event]
        name=moveto
        [filter]
            x=16
            y=6
            side=1
        [/filter]

        {VARIABLE dwelling_2 destroyed}

        {RANDOM 10..50}

        [gold]
            side=1
            amount=+$random
        [/gold]
        [message]
            speaker=unit
            message= _ "We've found $random gold in the Drake base."
            image=items/gold-coins-medium.png
        [/message]

        {REMOVE_IMAGE 16 6}

        {PLACE_IMAGE scenery/village-human-burned4.png 16 6}

        {CLEAR_VARIABLE random}
    [/event]

    [event]
        name=moveto
        [filter]
            x=22
            y=7
            side=1
        [/filter]

        {VARIABLE dwelling_3 destroyed}

        {RANDOM 10..50}

        [gold]
            side=1
            amount=+$random
        [/gold]
        [message]
            speaker=unit
            message= _ "We've found $random gold in the Drake base."
            image=items/gold-coins-medium.png
        [/message]

        {REMOVE_IMAGE 22 7}

        {PLACE_IMAGE scenery/village-human-burned4.png 22 7}

        {CLEAR_VARIABLE random}
    [/event]

    [event]
        name=moveto
        [filter]
            x=23
            y=13
            side=1
        [/filter]

        {VARIABLE dwelling_4 destroyed}

        {RANDOM 10..50}

        [gold]
            side=1
            amount=+$random
        [/gold]
        [message]
            speaker=unit
            message= _ "We've found $random gold in the Drake base."
            image=items/gold-coins-medium.png
        [/message]

        {REMOVE_IMAGE 23 13}

        {PLACE_IMAGE scenery/village-human-burned4.png 23 13}

        {CLEAR_VARIABLE random}
    [/event]

    [event]
        name=moveto
        [filter]
            x=31
            y=5
            side=1
        [/filter]

        {VARIABLE dwelling_5 destroyed}

        {RANDOM 10..50}

        [gold]
            side=1
            amount=+$random
        [/gold]
        [message]
            speaker=unit
            message= _ "We've found $random gold in the Drake base."
            image=items/gold-coins-medium.png
        [/message]

        {REMOVE_IMAGE 31 5}

        {PLACE_IMAGE scenery/village-human-burned4.png 31 5}

        {CLEAR_VARIABLE random}
    [/event]

    [event]
        name=moveto
        [filter]
            x=28
            y=9
            side=1
        [/filter]

        {VARIABLE dwelling_6 destroyed}

        {RANDOM 10..50}

        [gold]
            side=1
            amount=+$random
        [/gold]
        [message]
            speaker=unit
            message= _ "We've found $random gold in the Drake base."
            image=items/gold-coins-medium.png
        [/message]

        {REMOVE_IMAGE 28 9}

        {PLACE_IMAGE scenery/village-human-burned4.png 28 9}

        {CLEAR_VARIABLE random}
    [/event]

    [event]
        name=moveto
        [filter]
            x=34
            y=12
            side=1
        [/filter]

        {VARIABLE dwelling_7 destroyed}

        {RANDOM 10..50}

        [gold]
            side=1
            amount=+$random
        [/gold]
        [message]
            speaker=unit
            message= _ "We've found $random gold in the Drake base."
            image=items/gold-coins-medium.png
        [/message]

        {REMOVE_IMAGE 34 12}

        {PLACE_IMAGE scenery/village-human-burned4.png 34 12}

        {CLEAR_VARIABLE random}
    [/event]

    [event]
        name=moveto
        [filter]
            x=38
            y=7
            side=1
        [/filter]

        {VARIABLE dwelling_8 destroyed}

        {RANDOM 10..50}

        [gold]
            side=1
            amount=+$random
        [/gold]
        [message]
            speaker=unit
            message= _ "We've found $random gold in the Drake base."
            image=items/gold-coins-medium.png
        [/message]

        {REMOVE_IMAGE 38 7}

        {PLACE_IMAGE scenery/village-human-burned4.png 38 7}

        {CLEAR_VARIABLE random}
    [/event]

    [event]
        name=moveto
        [filter]
            x=41
            y=12
            side=1
        [/filter]

        {VARIABLE dwelling_9 destroyed}

        {RANDOM 10..50}

        [gold]
            side=1
            amount=+$random
        [/gold]
        [message]
            speaker=unit
            message= _ "We've found $random gold in the Drake base."
            image=items/gold-coins-medium.png
        [/message]

        {REMOVE_IMAGE 41 12}

        {PLACE_IMAGE scenery/village-human-burned4.png 41 12}

        {CLEAR_VARIABLE random}
    [/event]

    [event]
        name=moveto
        [filter]
            x=46
            y=9
            side=1
        [/filter]

        {VARIABLE dwelling_10 destroyed}

        {RANDOM 10..50}

        [gold]
            side=1
            amount=+$random
        [/gold]
        [message]
            speaker=unit
            message= _ "We've found $random gold in the Drake base."
            image=items/gold-coins-medium.png
        [/message]

        {REMOVE_IMAGE 46 9}

        {PLACE_IMAGE scenery/village-human-burned4.png 46 9}

        {CLEAR_VARIABLE random}
    [/event]

    [event]
        name=moveto
        [filter]
            x=10
            y=1
            side=1
        [/filter]

        {VARIABLE dwelling_11 destroyed}

        {RANDOM 10..50}

        [gold]
            side=1
            amount=+$random
        [/gold]
        [message]
            speaker=unit
            message= _ "We've found $random gold in the Drake base."
            image=items/gold-coins-medium.png
        [/message]

        {REMOVE_IMAGE 10 1}

        {PLACE_IMAGE scenery/village-human-burned4.png 10 1}

        {CLEAR_VARIABLE random}
    [/event]

    [event]
        name=moveto
        [filter]
            x=53
            y=7
            side=1
        [/filter]

        {VARIABLE dwelling_12 destroyed}

        {RANDOM 10..50}

        [gold]
            side=1
            amount=+$random
        [/gold]
        [message]
            speaker=unit
            message= _ "We've found $random gold in the Drake base."
            image=items/gold-coins-medium.png
        [/message]

        {REMOVE_IMAGE 53 7}

        {PLACE_IMAGE scenery/village-human-burned4.png 53 7}

        {CLEAR_VARIABLE random}
    [/event]

    [event]
        name=die
        [filter]
            description=Keh Ohn
        [/filter]
        [message]
            description=Keh Ohn
            message= _ "GRRROOOOAAAAR"
        [/message]
        [message]
            speaker=second_unit
            message= _ "Hurrah! We've killed their leader"
        [/message]
        [message]
            side=2
            canrecruit=no
            message= _ "Our leader is dead, but it matters not! Time enough to appoint a new leader after the battle is won! Fight on to the last, comrades!"
        [/message]
        [message]
            description=Konrad
            image=portraits/konrad-angry.png
            message= _ "Keep on going up the river. While we're at it, let us force as many drakes as possible to pay with their lives. They have defied us, and now they will meet the same fate as their leader!"
        [/message]
        [message]
            side=1
            canrecruit=no
            message= _ "We hear and obey, My Lord."
        [/message]
    [/event]

    [event]
        name=side turn
        first_time_only=no
        [if]
            {CHECK_VARIABLE side_number 2}

            [and]
                {CHECK_VARIABLE dwelling_1 active}
            [/and]
            [then]
                {RANDOM_DRAKE 12 10}
            [/then]
        [/if]
    [/event]

    [event]
        name=side turn
        first_time_only=no
        [if]
            {CHECK_VARIABLE side_number 2}

            [and]
                {CHECK_VARIABLE dwelling_2 active}
            [/and]
            [then]
                {RANDOM_DRAKE 16 6}
            [/then]
        [/if]
    [/event]

    [event]
        name=side turn
        first_time_only=no
        [if]
            {CHECK_VARIABLE side_number 2}

            [and]
                {CHECK_VARIABLE dwelling_3 active}
            [/and]
            [then]
                {RANDOM_DRAKE 22 7}
            [/then]
        [/if]
    [/event]

    [event]
        name=side turn
        first_time_only=no
        [if]
            {CHECK_VARIABLE side_number 2}

            [and]
                {CHECK_VARIABLE dwelling_4 active}
            [/and]
            [then]
                {RANDOM_DRAKE 23 13}
            [/then]
        [/if]
    [/event]

    [event]
        name=side turn
        first_time_only=no
        [if]
            {CHECK_VARIABLE side_number 2}

            [and]
                {CHECK_VARIABLE dwelling_5 active}
            [/and]
            [then]
                {RANDOM_DRAKE 31 5}
            [/then]
        [/if]
    [/event]

    [event]
        name=side turn
        first_time_only=no
        [if]
            {CHECK_VARIABLE side_number 2}

            [and]
                {CHECK_VARIABLE dwelling_6 active}
            [/and]
            [then]
                {RANDOM_DRAKE 28 9}
            [/then]
        [/if]
    [/event]

    [event]
        name=side turn
        first_time_only=no
        [if]
            {CHECK_VARIABLE side_number 2}

            [and]
                {CHECK_VARIABLE dwelling_7 active}
            [/and]
            [then]
                {RANDOM_DRAKE 34 12}
            [/then]
        [/if]
    [/event]

    [event]
        name=side turn
        first_time_only=no
        [if]
            {CHECK_VARIABLE side_number 2}

            [and]
                {CHECK_VARIABLE dwelling_8 active}
            [/and]
            [then]
                {RANDOM_DRAKE 38 7}
            [/then]
        [/if]
    [/event]

    [event]
        name=side turn
        first_time_only=no
        [if]
            {CHECK_VARIABLE side_number 2}

            [and]
                {CHECK_VARIABLE dwelling_9 active}
            [/and]
            [then]
                {RANDOM_DRAKE 41 12}
            [/then]
        [/if]
    [/event]

    [event]
        name=side turn
        first_time_only=no
        [if]
            {CHECK_VARIABLE side_number 2}

            [and]
                {CHECK_VARIABLE dwelling_10 active}
            [/and]
            [then]
                {RANDOM_DRAKE 46 9}
            [/then]
        [/if]
    [/event]

    [event]
        name=side turn
        first_time_only=no
        [if]
            {CHECK_VARIABLE side_number 2}

            [and]
                {CHECK_VARIABLE dwelling_11 active}
            [/and]
            [then]
                {RANDOM_DRAKE 10 1}
            [/then]
        [/if]
    [/event]

    [event]
        name=side turn
        first_time_only=no
        [if]
            {CHECK_VARIABLE side_number 2}

            [and]
                {CHECK_VARIABLE dwelling_12 active}
            [/and]
            [then]
                {RANDOM_DRAKE 53 7}
            [/then]
        [/if]
    [/event]

    [event]
        name=moveto
        [filter]
            side=1
            x=40-50
            y=11-20
        [/filter]
        [message]
            speaker=unit
            message= _ "I see someone at the top of the furthermost cliff!"
        [/message]
        [remove_shroud]
            side=1
            x=43-47
            y=14-17
        [/remove_shroud]
        [scroll_to]
            x=45
            y=16
        [/scroll_to]
        [message]
            speaker=unit
            message= _ "It is a young human sergeant, barely more than a boy. He appears badly hurt but still alive."
        [/message]
        [message]
            speaker=unit
            message= _ "I wonder why the Drakes haven't finished him by now? It is strange that there are not any Drakes or Undead in that area."
        [/message]
        [unit]
            type=Sea Serpent
            side=4
            x=48
            y=13
        [/unit]
        [unit]
            type=Sea Serpent
            side=4
            x=45
            y=12
        [/unit]
        [unit]
            type=Sea Serpent
            side=4
            x=50
            y=16
        [/unit]
        [unit]
            type=Sea Serpent
            side=4
            x=48
            y=18
        [/unit]
        [unit]
            type=Sea Serpent
            side=4
            x=45
            y=19
        [/unit]
        [message]
            type=Sea Serpent
            message= _ "Grrroar"
        [/message]
        [scroll_to_unit]
            description=unit
        [/scroll_to_unit]
        [message]
            speaker=unit
            message= _ "Well... that answers the question."
        [/message]
        [message]
            description="Li'sar"
            message= _ "We should try to help the injured soldier."
        [/message]
        [message]
            description=Kalenz
            message= _ "Must I remind you that he, like all the others who died, was sent to kill us!?"
        [/message]
        [message]
            description="Li'sar"
            message= _ "Perhaps he was sent after you, but not after me. I am sure that he is still loyal to his princess - the heiress to the throne of Wesnoth!"
        [/message]
        [message]
            description=Delfador
            message= _ "Princess Li'sar, do I have to remind you again that it is Konrad, not you, who is the rightful heir?"
        [/message]
        [message]
            description="Li'sar"
            message= _ "Whatever.... I still think we should make an effort to rescue him from the unfortunate position he is in. If you help him, I'll do my best to convince him that you are not his enemies but his friends..."
        [/message]
        [message]
            description=Konrad
            message= _ "Our main goal remains to survive ourselves, but if we can spare the troops, we might try to rescue the sergeant stranded on the cliff. However, I make no promises."
        [/message]
        [message]
            description=Kalenz
            message= _ "Fair enough!"
        [/message]
        [message]
            description="Li'sar"
            message= _ "Fair enough."
        [/message]
        [message]
            description=Delfador
            message= _ "Fair enough..."
        [/message]
        [objectives]
            side=1
            [objective]
                description= _ "Make it to the end of the river"
                condition=win
            [/objective]
            [objective]
                description= _ "<0,0,255>Rescue the sergeant ( Optional objective )"
                condition=win
            [/objective]
            [objective]
                description= _ "Death of Konrad"
                condition=lose
            [/objective]
            [objective]
                description= _ "Death of Delfador"
                condition=lose
            [/objective]
            [objective]
                description= _ "Death of Li'sar"
                condition=lose
            [/objective]
            [objective]
                description= _ "Death of Kalenz"
                condition=lose
            [/objective]
            [objective]
                description= _ "Turns run out"
                condition=lose
            [/objective]
        [/objectives]
    [/event]

    [event]
        name=moveto
        [filter]
            side=1
            x=44,44,45,45,46,46
            y=15,16,15,17,15,16
        [/filter]

        {MODIFY_UNIT description=Warven side 1}
        {MODIFY_UNIT description=Warven type Sergeant}

        {VARIABLE have_warven yes}

        [message]
            description=Warven
            message= _ "Who...who are you? A friend or a foe?"
        [/message]
        [message]
            speaker=unit
            message= _ "We are friends. Don't worry about it and don't try to fight us - you are in no condition to fight."
        [/message]
        [message]
            description="Li'sar"
            message= _ "I am Princess Li'sar, and we are friends. Join us and wait for the healers to help you, young sergeant."
        [/message]
        [message]
            description=Warven
            message= _ "Princess Li'sar - here ? Your Highness, I am yours to command!"
        [/message]
        [message]
            description=Konrad
            message= _ "Follow us when you think you are capable and beware of monsters. We have fought many already, and there are sure to be more ahead."
        [/message]
    [/event]

    [event]
        name=moveto
        [filter]
            x=53-55
            y=1-5
        [/filter]

        {VARIABLE waterfall_sighted yes}

        [message]
            speaker=unit
            message= _ "There is a waterfall ahead. It is so high I can barely see the top of it! Neither the Mermen, even less the land dwellers can swim up the waterfall. Even Gryphons might have trouble flying up so far! I am afraid, Your Highness, that we are stuck."
        [/message]

        {REMOVE_IMAGE 55 3}

        {WATERFALL_MASK 55 3}

        [message]
            description=Konrad
            message= _ "What about the tributary which flows into the river from inside the mountain? There seems to be a cave..."
        [/message]
        [message]
            description=Kalenz
            message= _ "Legend says that that little river comes from the land of the North Elves. It is said that it is an outflow of Everlore, which flows in the land of my home and that there is a cave system in that area with several cave entrances and springs which flow into the ground. I can say no more about it, except that it is swarming with undead and other creatures which find power in the darkness of the caves. We elves prefer not to venture into the caves; instead we put guards near the entrances to kill any foul creature foolish enough to wander outside. No elves have been inside for centuries and that area is unknown to us. Truly, I don't recommend entering the cave if we have any other options."
        [/message]
        [message]
            description=Konrad
            message= _ "Unfortunately, we have no other options. Onward into the cave!"
        [/message]

        {PLACE_IMAGE items/gohere.png 37 1}
    [/event]

    [event]
        name=moveto
        [filter]
            x=37
            y=1
            description=Konrad
        [/filter]
        [if]
            {CHECK_VARIABLE waterfall_sighted yes}

            [then]
                [message]
                    description=Konrad
                    message= _ "I've reached the cave entrance. There seems to be a system of channels running through the mountains. Follow me, and let us hope we somehow manage to get out alive."
                [/message]
                [message]
                    description="Li'sar"
                    message= _ "That is so very encouraging...."
                [/message]
                [message]
                    description=Delfador
                    message= _ "I wonder what kind of monsters await us inside."
                [/message]
                [message]
                    description=Kalenz
                    message= _ "We are soon going to find out."
                [/message]
                [message]
                    description="Li'sar"
                    message= _ "Well, there is no point in delaying any further. Let us go and find out."
                [/message]
                [message]
                    description=Warven
                    side=1
                    message= _ "Yes, my lady!"
                [/message]
                [message]
                    description=Konrad
                    message= _ "Everybody inside..."
                [/message]
                [endlevel]
                    result=victory
                [/endlevel]
            [/then]
        [/if]
    [/event]
[/scenario]
