#textdomain wesnoth-trow
[scenario]
    id=A_Beach
    name= _ "Lizard Beach"
    map_data="{campaigns/The_Rise_Of_Wesnoth/maps/A_Beach.map}"
    {TURNS 35 32 29}

    {DEFAULT_SCHEDULE}

    next_scenario=Elf_Lords
    bonus=yes

    [music]
        name="battle.ogg"
    [/music]

    {campaigns/The_Rise_Of_Wesnoth/utils/trow-deaths.cfg}

    [story]
        [part]
            background=story/the_great_continent.png
            show_title=yes
            {DOT 315 180}
            {DOT 290 180}
            {DOT 260 195}
            {DOT 245 210}
            {CROSS 230 216}
        [/part]
    [/story]

    [side]
        type=Noble Commander
        description=Prince Haldric
        user_description= _ "Prince Haldric"
        unrenamable=yes
        side=1
        canrecruit=yes
        controller=human
        team_name=Haldric
    [/side]

    [side]
        type=Saurian Flanker
        description=Tirasch
        user_description= _ "Tirasch"
        side=2
        canrecruit=yes
        {GOLD 130 190 250}
        {INCOME 2 4 8}
        team_name=Liz
#ifdef EASY
        recruit=Naga Fighter, Saurian Skirmisher, Mudcrawler, Giant Mudcrawler,Saurian Augur
#else
        recruit=Naga Fighter, Saurian Skirmisher, Mudcrawler, Giant Mudcrawler, Saurian Ambusher, Giant Scorpion,Saurian Augur,Saurian Oracle
#endif
        [ai]
            #{NO_SCOUTS}
            recruitment_ignore_bad_movement=yes
            recruitment_pattern=scout,archer,fighter,archer,fighter,scout,healer
            passive_leader=yes
            {ATTACK_DEPTH 4 5 5}
        [/ai]
    [/side]

    {STARTING_VILLAGES 2 8}

    [side]
        type=Saurian Flanker
        description=Ssirk
        user_description= _ "Ssirk"
        side=3
        canrecruit=yes
        {GOLD 130 190 250}
        {INCOME 2 4 8}
        team_name=Liz
#ifdef EASY
        recruit=Naga Fighter, Saurian Skirmisher, Mudcrawler, Giant Mudcrawler,Saurian Augur
#else
        recruit=Naga Fighter, Saurian Skirmisher, Mudcrawler, Giant Mudcrawler, Saurian Ambusher, Giant Scorpion,Saurian Augur,Saurian Soothsayer
#endif
        [ai]
            #{NO_SCOUTS}
            recruitment_ignore_bad_movement=yes
            recruitment_pattern=scout,archer,fighter,archer,fighter,scout,healer
            passive_leader=yes
            {ATTACK_DEPTH 4 5 5}
        [/ai]
    [/side]

    {STARTING_VILLAGES 3 8}

    {campaigns/The_Rise_Of_Wesnoth/utils/trow-nlmsg.cfg}

    [event]
        name=prestart

        [recall]
            description=Lady Jessica
        [/recall]
        [recall]
            description=Burin the Lost
        [/recall]
        [recall]
            description=Sir Ruddry
        [/recall]

        [recall]
            description=Sir Ladoc
        [/recall]

        [recall]
            description=Minister Edmond
        [/recall]

        [objectives]
            side=1
            [objective]
                description= _ "Defeat all enemy leaders"
                condition=win
            [/objective]
            [objective]
                description= _ "Death of Prince Haldric"
                condition=lose
            [/objective]
            [objective]
                description= _ "Death of Lady Jessica"
                condition=lose
            [/objective]
            [objective]
                description= _ "Turns run out"
                condition=lose
            [/objective]
        [/objectives]
    [/event]

    [event]
        name=start
        [message]
            speaker=narrator
            message= _ "After a long trek Prince Haldric, and his companions find themselves on a sunny beach. While normally this would be a pleasant occurrence, they find the saurians hard at work there."
            image=wesnoth-icon.png
        [/message]

        [message]
            description=Ssirk
            message= _ "Monsters! We're being invaded by monsters."
        [/message]

        [message]
            description=Tirasch
            message= _ "We must hold the beach until we can call our naga friends."
        [/message]

        [message]
            description=Prince Haldric
            message= _ "Us, monsters? Hmph... prepare to meet our blades."
            image=portraits/haldric-mad.png
        [/message]

        [message]
            description=Lady Jessica
            message= _ "(Sigh) I bet he sees none of the irony in that."
        [/message]
    [/event]

    [event]
        name=time over
        [message]
            description=Lady Jessica
            message= _ "We were too slow... Every naga in the sea will be upon us!"
        [/message]
    [/event]

    [event]
        name=die
        first_time_only=no

        [filter]
            type=Giant Mudcrawler
        [/filter]

        {LOYAL_UNIT 2 (Mudcrawler) ($x1) ($y1) () ("") }
        {LOYAL_UNIT 3 (Mudcrawler) ($x1) ($y1) () ("") }
    [/event]

    [event]
        name=die
        [filter]
            type=Giant Mudcrawler
        [/filter]
        [message]
            description=Prince Haldric
            message= _ "Ick! When you kill them they divide."
            image=portraits/haldric-mad.png
        [/message]
    [/event]

    [event]
        name=die
        [filter]
            description=Tirasch
        [/filter]
        [gold]
            side=3
            amount=170
        [/gold]
    [/event]

    [event]
        name=die
        [filter]
            description=Ssirk
        [/filter]
        [gold]
            side=2
            amount=170
        [/gold]
    [/event]

    [event]
        name=die
        [filter]
            type=Giant Mudcrawler
        [/filter]
    [/event]

    # Humans reach the beach

    [event]
        name=moveto

        [filter]
            side=1
            x=1-11
            y=1-25
        [/filter]

        [move_unit_fake]
            type=Naga Warrior
            side=2
            x=1,2,3,4,5,6
            y=15,14,15,15,16,15
        [/move_unit_fake]

        {LOYAL_UNIT 2 (Naga Warrior) 6 15 (Riaa) ( _ "Riaa")}
        # wmllint: recognize Riaa

        [message]
            description=Riaa
            message= _ "We must protect the saurians. We need the metal!"
        [/message]

        {LOYAL_UNIT 3 (Naga Fighter) 5 15 (Liabra) ( _ "Liabra")}
        {LOYAL_UNIT 2 (Naga Fighter) 5 16 (Brissal) ( _ "Brissal")}

#ifdef NORMAL
        {LOYAL_UNIT 3 (Naga Fighter) 4 14 (Gaxmail) ( _ "Gaxmail")}
        {LOYAL_UNIT 2 (Naga Fighter) 4 16 (Griama) ( _ "Gaxmail")}
#endif
#ifdef HARD

        {LOYAL_UNIT 3 (Naga Fighter) 4 14 (Gaxmail) ( _ "Gaxmail")}
        {LOYAL_UNIT 2 (Naga Fighter) 4 16 (Griama) ( _ "Griama")}
        {LOYAL_UNIT 3 (Naga Fighter) 3 14 (Saxiala) ( _ "Saxiala")}
        {LOYAL_UNIT 2 (Naga Fighter) 3 17 (Malix) ( _ "Malix")}
#endif
    [/event]

    [event]
        name=victory
        [message]
            description=Prince Haldric
            message= _ "We've cleared the beach. Let's return to the elves."
        [/message]

        {VARIABLE_OP num_done add 1}

        [set_variable]
            name=a_beach
            value=1
        [/set_variable]

        [set_variable]
            name=last_done
            value="Beach"
        [/set_variable]
    [/event]
[/scenario]
