#textdomain wesnoth-dw

# Give one of your leveled fighters the holy water. Those units won't
# be as useful after one more scenario unless they have special weapons.

[scenario]
    name= _ "Talking to Tyegëa"
    map_data="{campaigns/Dead_Water/maps/Talking_To_Tyegea.map}"

    id=08_Talking_to_Tyegea
    next_scenario=09_The_Mage

    [story]
        [part]
            story= _ "It had been more of an adventure than the Kai Krellis had planned, but they were finally at their destination. The small island where Tyegëa and her students lived was before them."
        [/part]

        [part]
            background=dead-water-map.png
            show_title=yes
            {OLD_BATTLE 746 673}
            {OLD_JOURNEY 729 657}
            {OLD_JOURNEY 734 635}
            {OLD_BATTLE 732 615}
            {OLD_JOURNEY 708 612}
            {OLD_JOURNEY 681 607}
            {OLD_JOURNEY 654 600}
            {OLD_JOURNEY 647 573}
            {OLD_JOURNEY 640 546}
            {OLD_BATTLE 650 522}
            {OLD_JOURNEY 637 497}
            {OLD_JOURNEY 628 473}
            {OLD_JOURNEY 610 454}
            {OLD_JOURNEY 589 437}
            {OLD_JOURNEY 576 412}
            {OLD_JOURNEY 575 388}
            {OLD_JOURNEY 552 381}
            {OLD_BATTLE 542 361}
            {OLD_JOURNEY 523 370}
            {OLD_JOURNEY 501 381}
            {OLD_JOURNEY 477 391}
            {OLD_BATTLE 455 401}
            {OLD_JOURNEY 434 414}
            {OLD_JOURNEY 414 428}
            {OLD_BATTLE 395 446}
            {NEW_JOURNEY 402 471}
            {NEW_JOURNEY 396 495}
            {NEW_JOURNEY 387 518}
            {NEW_JOURNEY 369 537}
            {NEW_JOURNEY 344 548}
            {NEW_JOURNEY 319 542}
            {NEW_JOURNEY 307 523}
            {NEW_REST 306 497}
        [/part]
    [/story]

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

    turns=-1
    victory_when_enemies_defeated=no

    # wmllint: validate-off
    [side]
        {SIDE_1}
        income=-2
        gold=20
    [/side]
    # wmllint: validate-on

    [side]
        side=2
        controller=ai
        user_team_name= _ "Tyegëa and Priestesses"
        team_name=good guys

        id=Tyegea
        # wmllint: recognize Tyegea
        name= _ "Tyegëa"
        canrecruit=yes
        type=Mermaid Diviner
        [ai]
            ai_algorithm=idle_ai
        [/ai]
    [/side]

    {STARTING_VILLAGES 2 99}

    [event]
        name=prestart

        [music]
            name=elf-land.ogg
        [/music]
        [music]
            name=elvish-theme.ogg
            append=yes
        [/music]

        {RECALL_LOYAL_UNITS}

        [objectives]
            side=1
            [objective]
                description= _ "Choose a unit to take the holy water"
                condition=win
            [/objective]
        [/objectives]

        [unit]
            type=Mermaid Priestess
            side=2
            x=4
            y=4
            generate_name=yes
        [/unit]
        [unit]
            type=Mermaid Priestess
            side=2
            x=13
            y=4
            generate_name=yes
        [/unit]
        [unit]
            type=Mermaid Priestess
            side=2
            x=12
            y=8
            generate_name=yes
        [/unit]
        [unit]
            type=Mermaid Priestess
            side=2
            x=9
            y=11
            generate_name=yes
        [/unit]
    [/event]

    # wmllint: local spelling Imirna
    [event]
        name=start
        [message]
            speaker=Cylanna
            message= _ "Krellis...choose your words carefully. Tyegëa is a bit unpredictable."
        [/message]
        [message]
            speaker=Tyegea
            message= _ "Welcome, merfolk! It has been a long time since outsiders have visited. And Cylanna! It is pleasant to see you."
        [/message]
        [message]
            speaker=Cylanna
            message= _ "The honor is ours. I present Kai Krellis of Jotha."
        [/message]
        [message]
            speaker=Tyegea
            message= _ "Indeed! So this is the one. Does he know?"
        [/message]
        [message]
            speaker=Kai Krellis
            message= _ "Know what?"
        [/message]
        [message]
            speaker=Cylanna
            message= _ "Now is not the time. We have a desperate errand, Tyegëa. Jotha has been attacked and taken."
        [/message]
        [message]
            speaker=Kai Krellis
            message= _ "We were forced to flee for our lives from legions of undead. If you help us, we can remove these spirits from our home."
        [/message]
        [message]
            speaker=Tyegea
            message= _ "And what makes you think I want to leave my comfortable home and risk death by attacking armies of undead?"
        [/message]
        [message]
            speaker=Kai Krellis
            message= _ "I had hoped..."
        [/message]
        [message]
            speaker=Tyegea
            message= _ "I am sure it was Cylanna’s idea that you come here. She has a reason. Don’t you Cylanna? Tell him what it is."
        [/message]
        [message]
            speaker=Cylanna
            message= _ "(Sigh.) I had hoped to avoid this, but it seems I cannot."
        [/message]
        [message]
            speaker=Tyegea
            message= _ "I never agreed that secrecy was necessary, but I respected Maudin’s wishes in the matter. Now Indress and Maudin are dead, and I am not. Tell the boy the truth."
        [/message]
        [message]
            speaker=Kai Krellis
            message= _ "You knew my grandparents?"
        [/message]
        [message]
            speaker=Cylanna
            message= _ "Actually, Tyegëa is your grandmother."
        [/message]
        [message]
            speaker=Kai Krellis
            message= _ "What? How is that possible?"
        [/message]
        [message]
            speaker=Cylanna
            message= _ "When your grandfather married Indress, he did not know that Tyegëa had already born him a son. When she delivered your father to Jotha, your grandmother Indress agreed to keep it secret and raise the infant as her own."
        [/message]
        [message]
            speaker=Tyegea
            message= _ "That was quite a scandal, too, but I was not cut out to be a mother."
        [/message]
        [message]
            speaker=Kai Krellis
            message= _ "I am astonished. I suppose I should be honored to have such a distinguished ancestor. Now I understand why Cylanna knew you would help us."
        [/message]
        [message]
            speaker=Tyegea
            message= _ "That remains to be seen. I find it disturbing that a Kai — and my descendant — would run here begging for help. Before I agree to save you, you have to prove that my blood flows in your veins. Prove that your are, despite appearances, courageous, and worthy of my help."
        [/message]
        [message]
            speaker=Kai Krellis
            message= _ "Well, I defeated the Drakes on your island."
        [/message]
        [message]
            speaker=Tyegea
            message= _ "Bah! Drakes only look dangerous. Soldiers carrying spears make short work of them. No, I have something else in mind. You will complete a task for the good of the merfolk. Listen."
        [/message]
        [message]
            speaker=Tyegea
            message= _ "About 200 years ago, a powerful mermaid named Imirna fell in love with a human wizard named Agnovon. Agnovon cared not for love, but he smiled falsely at Imirna, and she trusted him. When he asked her to help him enchant a sword so that it was wreathed continuously in magic flame, she devoted all her skill to fashioning the weapon. Later, Agnovon used that very sword to defeat Imirna’s own people and steal their wealth. In her grief, Imirna poisoned herself."
        [/message]
        [message]
            speaker=Tyegea
            message= _ "I have long desired to see the sword returned to the merfolk to whom it should belong. If you retrieve it, you would prove yourself to be worthy of whatever help I were to provide. I do not know precisely where to find the sword, but I know one who does. South of the Swamp of Desolation, near a ruined castle, lives a mage named Caladon. He has lusted after the sword for years, so he will know where to find the lich who keeps it."
        [/message]
        [message]
            speaker=Kai Krellis
            message= _ "A lich has it? We were fleeing liches in the first place."
        [/message]
        [message]
            speaker=Tyegea
            message= _ "There is only one of them. If you cannot defeat even one lich, you must be expecting me to get rid of all of your undead myself!"
        [/message]
        [message]
            speaker=Kai Krellis
            message= _ "My apologies. You are right, of course. We will undertake this task."
        [/message]
        [message]
            speaker=Tyegea
            message= _ "I will not send you away completely empty-handed, though. I can spare some holy water for one of your soldiers."
        [/message]

        [item]
            x=15
            y=8
            image=items/holy-water.png
        [/item]

        [message]
            speaker=narrator
            message= _ "The holy water will make melee attacks do <i>arcane</i> damage for the rest of the campaign. Choose a unit to take it. You may recruit or recall a unit if you want."
            image=wesnoth-icon.png
        [/message]

        [event]
            name=moveto

            [filter]
                x=15
                y=8
            [/filter]
            [object]
                id=holywater1
                name= _ "Holy Water"
                image=items/holy-water.png
                silent=yes
                [filter]
                    x=15
                    y=8
                [/filter]
                [then]
                    [unit_overlay]
                        x=15
                        y=8
                        image=overlays/arcane-icon.png
                    [/unit_overlay]
                    [remove_item]
                        x,y=15,8
                    [/remove_item]
                    [message]
                        speaker=Tyegea
                        message= _ "Now, go. Come back with the flaming sword, and my priestesses and I will help you take back Jotha."
                    [/message]
                    [endlevel]
                        result=victory
                        linger_mode=no
                        carryover_report=no
                        {NEW_GOLD_CARRYOVER 100}
                    [/endlevel]
                [/then]
                [effect]
                    apply_to=attack
                    range=melee
                    set_type=arcane
                [/effect]
            [/object]
        [/event]
    [/event]
[/scenario]
