#textdomain wesnoth-did

[scenario]
    id=06_Return_to_Parthyn
    name= _ "Return to Parthyn"
    map_file=06_Return_to_Parthyn.map
    {TURNS 19 18 17}
    victory_when_enemies_defeated=no
    next_scenario=07a_A_Small_Favor

    {DEFAULT_SCHEDULE}

    {SCENARIO_MUSIC       the_city_falls.ogg}
    {EXTRA_SCENARIO_MUSIC knolls.ogg}
    {EXTRA_SCENARIO_MUSIC weight_of_revenge.ogg}

    [story]
        [part]
            music=northerners.ogg
            story= _ "Two days’ travel south of the previous battle, Malin picks up the trail of the regrouped orcish warriors. He follows them down the western bank of the river Listra, past the Whitefang Mountains. He wonders why they continue rushing toward the Great River instead of calling for reinforcements, but after a bit of thought, he realizes where the orcs are headed. It is, after all, the season when they usually raid human towns."
            {STORYTXT_BACKGROUND travel.webp}
        [/part]
        [part]
            story= _ "<i>‘This chieftain has no intention of warning the rest of his clan about me. I suppose he must think that I intend to attack the rest of the Whitefangs rather than pursue him this far; with his brethren occupied against me, he will be able to raid more human towns undisturbed. Selfish creature. Exactly what one would expect from an orc.’</i> Malin thinks carefully and quickly realizes what he should do."
            {STORYTXT_BACKGROUND travel.webp}
        [/part]
        [part]
            story= _ "He tramps through the woods tirelessly, forsaking several days’ sleep as he and his servants draw closer to the Great River, hoping to cut off the orcs before they reach Parthyn. Soon, Malin recognizes some familiar surroundings..."
            {STORYTXT_BACKGROUND parthyn.webp}
        [/part]
    [/story]

    {DID_TRACK {JOURNEY_06_NEW}}

    # wmllint: validate-off
    [side]
        side=1
        controller=human
        recruit=Walking Corpse,Vampire Bat,Ghost,Ghoul,Skeleton Archer,Skeleton
        {GOLD 100 90 80}
        village_support=2
        team_name=good
        user_team_name= _ "Malin Keshar"
        {FLAG_VARIANT undead}
        color=darkblue

        # wmllint: recognize Malin Keshar
        {CHARACTER_STATS_MALIN_KESHAR}

        facing=sw
    [/side]
    # wmllint: validate-on

    # A fallback leader is defined for side 2 here just in case the stored unit
    # doesn't exist for some reason, like if the player has used debug mode to
    # jump to this scenario.
    [side]
        side=2
        controller=ai
#ifdef EASY
        recruit=Wolf Rider,Orcish Archer,Orcish Grunt,Troll Whelp
#else
        recruit=Wolf Rider,Goblin Knight,Orcish Archer,Orcish Crossbowman,Orcish Grunt,Troll Whelp
#endif
        {GOLD 60 85 110}
        {INCOME 3 5 7}
        team_name=orcs
        user_team_name= _ "Orcs"
        {FLAG_VARIANT6 ragged}
        color=white

        type=Orcish Warlord
        id=Borth
        name= _ "Borth"
        profile=portraits/orcs/warlord.webp
        canrecruit=yes

        facing=se

        [ai]
            aggression=0.8
            villages_per_scout=8
            village_value=0.5
        [/ai]
    [/side]

    [side]
        side=3
        controller=ai
        recruit=
        gold=0
        village_gold=0
        team_name=guardsmen
        user_team_name= _ "Guardsmen"
        {FLAG_VARIANT loyalist}
        color=green

        type=Lieutenant
        id=Drogan
        name= _ "Drogan"
        profile=portraits/drogan.webp
        canrecruit=yes

        facing=nw

        # Drogan has some guards at the river fort
        {NAMED_LOYAL_UNIT 3 (Spearman) 22 18 () ( _ "River fort guard")} {GUARDIAN}
        {NAMED_LOYAL_UNIT 3 (Bowman)   23 19 () ( _ "River fort guard")} {GUARDIAN}
        {NAMED_LOYAL_UNIT 3 (Spearman) 28 17 () ( _ "River fort guard")} {GUARDIAN}

        [ai]
            aggression=0.1
            caution=0.9
        [/ai]
    [/side]

    # wmllint: validate-off
    [side]
        side=4
        controller=ai
        recruit=Spearman,Bowman,Swordsman,Pikeman,Longbowman,Thug,Poacher,Footpad
        gold=15
        {INCOME 6 9 12}
        team_name=guardsmen
        user_team_name= _ "Defenders"
        {FLAG_VARIANT loyalist}
        color=green

        # wmllint: recognize Dela Keshar
        {CHARACTER_STATS_DELA_KESHAR}

        facing=ne

        [ai]
            [goal]
                name=protect_unit
                [criteria]
                    id=Drogan
                [/criteria]
                value=2
            [/goal]
            [goal]
                name=target
                [criteria]
                    id=Malin Keshar
                [/criteria]
                value=2
            [/goal]
        [/ai]
    [/side]
    # wmllint: validate-on

    {STARTING_VILLAGES 1 7}
    {STARTING_VILLAGES 3 6}
    {STARTING_VILLAGES 4 15}

    # Signpost
    {PLACE_IMAGE scenery/signpost.png 17 22}
    {PLACE_IMAGE scenery/monolith2.png 14 9}
    {PLACE_IMAGE items/book2.png 29 25}
    {PLACE_IMAGE scenery/wreck.png 31 15}

#define DID_RTP_HAS_ORC_LEADER
    [have_unit]
        side=2
        canrecruit=yes
    [/have_unit]
#enddef

#define DID_RTP_HAS_DROGAN
    [have_unit]
        id=Drogan
    [/have_unit]
#enddef

#define DID_RTP_OBJECTIVE_KILL_ORCS
    [objective]
        condition=win
        {ALTERNATIVE_OBJECTIVE_CAPTION}
        description= _ "Kill the orcish leader"
        [show_if]
            {DID_RTP_HAS_ORC_LEADER}
        [/show_if]
    [/objective]
#enddef

    [event]
        name=prestart

        {CLEAR_CORPSE_HORDE}

        {COLOR_ADJUST -14 -14 -14}

        [objectives]
            side=1
            [objective]
                condition=win
                description= _ "Remove the traitor Drogan"
            [/objective]

            {DID_RTP_OBJECTIVE_KILL_ORCS}

            [objective]
                condition=lose
                description= _ "Kill any people from Parthyn but Drogan"
            [/objective]
            [objective]
                condition=lose
                description= _ "Death of Malin Keshar"
            [/objective]

            {TURNS_RUN_OUT}

            [gold_carryover]
                bonus=yes
                carryover_percentage=40
            [/gold_carryover]
        [/objectives]

        [store_unit]
            [filter]
                id=Borth
            [/filter]
            variable=fallback_orc_leader
            kill=yes
        [/store_unit]

        {CREATE_ADVISOR}
        [move_unit]
            role=advisor
            to_x,to_y=20,9
        [/move_unit]
    [/event]

    [event]
        name=start

        [message]
            speaker=Malin Keshar
            message= _ "I bring word from the north, Drogan! Orcs march on Parthyn, no more than a few hours’ journey away. They mean to raid the village tonight!"
        [/message]

        [if]
            [variable]
                name=malin_used_necromancy
                boolean_equals=yes
            [/variable]
            [then]
                [message]
                    speaker=Drogan
                    message= _ "I hoped I’d never see ya again, Malin. You’re obviously not taking yer banishment seriously, so I’ll tell ya one last time — no matter why you’ve come back, we’re not welcomin’ ya here. Take one step closer to Parthyn and I’ll order tha guards to attack ya."
                [/message]

                [message]
                    speaker=Malin Keshar
                    message= _ "Banishment or not, I’m here to help defend my home against the orcs!"
                [/message]

                [message]
                    speaker=Drogan
                    message= _ "Orcs or not, ya gots ta leave!"
                [/message]

                [message]
                    speaker=Malin Keshar
                    message= _ "Dela, help me! You, at least, must see reason!"
                [/message]

                [message]
                    speaker=Drogan
                    message= _ "Ya know there’s no way she’s sidin’ with ya."
                [/message]

                [message]
                    speaker=Dela Keshar
                    message= _ "That... I don’t really..."
                [/message]

                [message]
                    speaker=Drogan
                    message= _ "See? If ya keep bein’ stubborn, we’ll attack ya. Leave."
                [/message]

                [message]
                    role=advisor
                    message=_ "Master, do not listen to them! He, too, has a choice, but he foolishly chooses to spurn your aid! He jeopardizes the safety of Parthyn!"
                [/message]
            [/then]
            [else]
                [message]
                    speaker=Drogan
                    # po: ’side is short for beside
                    message= _ "I didn’t think I’d ever see ya again, Malin. But what’s this awful thing that stands ’side ya?"
                [/message]

                [message]
                    speaker=Malin Keshar
                    message= _ "It is of little concern to you. It is merely the byproduct of the new magical arts that I have learned."
                [/message]

                [message]
                    speaker=Drogan
                    message= _ "It don’t take a trained mage ta see that yer ‘magical arts’ refers to necromancy! That creature stinks o’ death!"
                [/message]

                [message]
                    speaker=Malin Keshar
                    message= _ "And why should you care about such things? Orcs march on Parthyn! We must defend the town!"
                [/message]

                [message]
                    speaker=Drogan
                    # po: the third sentence is "your father would be turning in his grave if he could see what you've become" with intentionally incorrect grammar because Drogan is not well educated
                    message= _ "Better ta face them orcs alone than ta use dark magic! I warned ya about this before, but obviously ya ignored me. Yer father’d be turnin’ in his grave if he be seein’ what you’ve become."
                [/message]

                [message]
                    speaker=Malin Keshar
                    message= _ "You dare bring my father into this! I’ve fought with every fiber of my being against these orcs, and I’ve done it all to protect my country and kinsmen. Is this how you repay me? With scorn and disdain?"
                [/message]

                [message]
                    role=advisor
                    message=_ "Master, do not listen to him! He is clearly blinded by his own prejudice! He jeopardizes the safety of Parthyn!"
                [/message]
            [/else]
        [/if]

        [message]
            speaker=Malin Keshar
            message= _ "Silence from you."
        [/message]

        [message]
            speaker=Malin Keshar
            message= _ "Drogan! With my newfound powers, I have already eliminated several orcish chieftains! If you will allow me to help, I will crush the one who comes here as well!"
        [/message]

        [message]
            speaker=Drogan
            # po: ’n means and
            message= _ "Fine story ye be tellin’ me. I find it likelier that ya brought yer pet orcs here ta help ya take revenge on us. If I let ya through, yer undead will kill us where we stand ’n sack the whole city. Watchin’ ya grow up, I never could’ve thought you’d turn into such a traitor."
        [/message]

        [message]
            speaker=Malin Keshar
            message= _ "And what of the rest of you? Dela, at least you don’t believe that, do you?"
        [/message]

        [message]
            speaker=Dela Keshar
            message= _ "I..."
        [/message]

        [message]
            speaker=Drogan
            message= _ "Stop lookin’ ta her, Malin. Tha fact that even Dela be rejectin’ ya should tell ya how much o’ a traitor ye are."
        [/message]

        [message]
            role=advisor
            message= _ "Master, he threatens the safety of the city by standing in your way."
        [/message]

        [message]
            speaker=Malin Keshar
            message= _ "You’re the traitor, Drogan! This is twice now that you’ve tried to prevent me from protecting Parthyn. I’ll defend my home no matter the cost, even if it means I must cut you down first."
        [/message]

        # Malin cools down briefly
        [message]
            speaker=Malin Keshar
            message= _ "<i>If I want the people of Parthyn to accept me back, I must be cautious. I musn’t kill any of them besides Drogan or they’ll oust me for good.</i>"
        [/message]
    [/event]

    # activate side 4 a tiny bit late or they rush the player a bit quickly
    [event]
        name=turn 3

        [gold]
            side=4
            {QUANTITY amount 20 30 40}
        [/gold]
    [/event]
    [event]
        name=turn 5

        [gold]
            side=4
            {QUANTITY amount 50 70 90}
        [/gold]
    [/event]

    # Placing the orc leader

    [event]
        name=turn 5

        [scroll_to]
            x,y=29,1
        [/scroll_to]

        [move_unit_fake]
            type="Orcish Warlord"
            side=2
            x=29,29,28,28,29,30
            y=1,2,2,3,4,4
        [/move_unit_fake]

        # Replace the fallback orcish leader with the stored one from the
        # previous scenario
        [lua]
            code = <<
                local saved_orc_leader = wml.variables.orc_leader_store
                local fallback_orc_leader = wml.variables.fallback_orc_leader

                if saved_orc_leader ~= nil then
                    saved_orc_leader.side = 2
                    saved_orc_leader.facing = "se"

                    local loc = wesnoth.sides[2].starting_location
                    wesnoth.units.to_map(saved_orc_leader, loc[1], loc[2])

                    wml.variables.orc_leader_store = nil
                else
                    local loc = wesnoth.sides[1].starting_location
                    wesnoth.units.to_map(fallback_orc_leader, loc[1], loc[2])
                end
            >>
        [/lua]

        [terrain]
            x,y=30,4
            terrain=Ke
        [/terrain]
        [terrain]
            x=30,30,29,29
            y=3,5,4,5
            terrain=Ce
        [/terrain]
        [redraw][/redraw]

        [message]
            side=2
            canrecruit=yes
            message= _ "Grunts! Prepare the camp! We attack the city tonight— wait. You! Necromancer, you followed us all the way here?!"
        [/message]

        [if]
            {DID_RTP_HAS_DROGAN}
            [then]
                [message]
                    speaker=Malin Keshar
                    message= _ "Did you really think you could outrun the dead, who need neither rest nor sleep? Prepare to meet your makers, orc. Drogan, I will show you what my new powers are capable of. You will see how foolish you are to oppose me."
                [/message]
            [/then]
            [else]
                [message]
                    speaker=Malin Keshar
                    message= _ "Did you really think you could outrun the dead, who need no rest nor sleep? Prepare to meet your makers, orc."
                [/message]
            [/else]
        [/if]

        [show_objectives][/show_objectives]
    [/event]

    # In-scenario Events

    [event]
        name=moveto
        [filter]
            id=Malin Keshar
            x,y=14,9
        [/filter]
        [filter_condition]
            [have_unit]
                id=Drogan
            [/have_unit]
        [/filter_condition]

        [message]
            speaker=narrator
            message= _ "A monolith of grey stone, appearing solid, but crumbling within."
        [/message]

#ifdef EASY
        {GIVE_MALIN_EXPERIENCE 12}
#endif
#ifdef NORMAL
        {GIVE_MALIN_EXPERIENCE 10}
#endif
#ifdef HARD
        {GIVE_MALIN_EXPERIENCE 8}
#endif

        {VARIABLE_OP monolith add 1}
        [progress_achievement]
            content_for=descent_into_darkness
            id="did_monolith"
            amount=1
            limit=$monolith
        [/progress_achievement]
    [/event]

    [event]
        name=moveto
        [filter]
            id=Malin Keshar
            x,y=29,25
        [/filter]

        [message]
            speaker=narrator
            message= _ "Darkness is not the enemy, but believing it is so makes it so."
        [/message]

        {GIVE_MALIN_EXPERIENCE 6}
    [/event]

    [event]
        name=moveto
        [filter]
            type=Soulless
            variation=swimmer
            x,y=31,15
        [/filter]

        # see corresponding easter egg in S1
        [message]
            speaker=Malin Keshar
            message= _ "The dead fish returns home."
        [/message]

        [object]
            id=super_zombie_buff
            take_only_once=yes
            silent=yes
            duration=forever
            [filter]
                x,y=31,15
            [/filter]
            [effect]
                apply_to=new_ability
                [abilities]
                    {ABILITY_FEEDING}
                [/abilities]
            [/effect]
            [effect]
                apply_to=attack
                range=melee
                [set_specials]
                    {WEAPON_SPECIAL_POISON}
                    mode=append
                [/set_specials]
            [/effect]
            [effect]
                apply_to=hitpoints
                increase_total=32
                increase=32
                heal_full=no
            [/effect]
        [/object]

        [set_achievement]
            content_for=descent_into_darkness
            id="did_sushi"
        [/set_achievement]
    [/event]

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

        [message]
            speaker=narrator
            message= _ "Welcome to Parthyn"
            image=scenery/signpost.png
        [/message]
    [/event]

    # Dialog for the rare event you kill the orc leader before Drogan or any town guard
    [event]
        name=die
        [filter]
            side=2
            canrecruit=yes
        [/filter]

        [if]
            {DID_RTP_HAS_DROGAN}
            [then]
                [message]
                    speaker=Malin Keshar
                    message= _ "Behold, Drogan! I have slain the orcish chieftain. Do you trust me now?"
                [/message]

                [message]
                    speaker=Drogan
                    message= _ "I see that you’ve not lost all o’ yer humanity by allying yerself with tha orcs. But ya can’t come back, Malin. No necromancer will ever be welcome in Parthyn."
                [/message]

                [message]
                    speaker=Malin Keshar
                    message= _ "What?! You ungrateful cur! You’d sack tha city and let everyone die, and for what? Only to spurn something you don’t understand? You’re a fool. Parthyn will only be under greater danger with you leading it. If we are to survive, <i>you</i> are the one who must leave!"
                [/message]

                [message]
                    speaker=Dela Keshar
                    message= _ "Have ye lost yer mind, Malin? There’s no way we’re banishin’ Drogan!"
                [/message]

                [message]
                    speaker=Drogan
                    message= _ "Malin, ye were once one o’ my friends and tha pride o’ tha town. I truly don’t want ta fight ya. I’ll give ya one more chance. Leave Parthyn."
                [/message]

                [message]
                    speaker=Malin Keshar
                    message= _ "Your choice, not mine. If you refuse to leave by your own volition, then it will have to be by force. Attack him!"
                [/message]

                [show_objectives][/show_objectives]
            [/then]
            [else]
                [message]
                    speaker=narrator
                    message= _ "The orc was carrying some gold."
                [/message]

                [gold]
                    side=1
                    {QUANTITY amount 60 50 40}
                [/gold]

                [endlevel]
                    result=victory
                    bonus=no
                    {NEW_GOLD_CARRYOVER 40}
                [/endlevel]
            [/else]
        [/if]
    [/event]

    # Dela Keshar can't actually die here, she needs to reappear in
    # Alone At Last. It's not easy to get to this contingency, which
    # is why we settle for a relatively crude fallback here.
    # This is also an alternative victory condition.
    [event]
        name=last breath
        [filter]
            id=Dela Keshar
        [/filter]

        [message]
            speaker=Dela Keshar
            message= _ "I am defeated but not dead, foul thing that was once my brother. Watch your back, because I will come for you and I will kill you..."
        [/message]

        [move_unit]
            id=Dela Keshar
            to_x,to_y=1,25
        [/move_unit]

        [kill]
            id=Dela Keshar
            animate=no
        [/kill]

        [endlevel]
            result=victory
            bonus=no
            {NEW_GOLD_CARRYOVER 40}
        [/endlevel]
    [/event]

    # Defeat Conditions
    [event]
        name=die
        [filter]
            side=3,4
            [not]
                id=Drogan
            [/not]
        [/filter]
        [filter_second]
            side=1
        [/filter_second]

        [if]
            {DID_RTP_HAS_DROGAN}
            [then]
                [message]
                    speaker=Malin Keshar
                    message= _ "Now the people of Parthyn will never accept me back!"
                [/message]

                [endlevel]
                    result=defeat
                [/endlevel]
            [/then]
            [else]
                [message]
                    speaker=Malin Keshar
                    message= _ "See how you die when you spurn the help of Malin Keshar..."
                [/message]
            [/else]
        [/if]
    [/event]

    # Victory Conditions
    [event]
        name=die
        [filter]
            id=Drogan
        [/filter]

        # it's kind of subtle, but keep making everything darker
        {COLOR_ADJUST -15 -15 -15}

        {REMOVE_IMAGE 14 9}

        {INCIDENTAL_MUSIC the_dangerous_symphony.ogg}

        [message]
            speaker=Malin Keshar
            message= _ "See what your traitorous ways have won you, Drogan?"
        [/message]

        [message]
            speaker=Dela Keshar
            message= _ "Drogan, no! Malin, you monster, how could ya just murder Drogan in cold blood?"
        [/message]

        [message]
            speaker=Malin Keshar
            message= _ "He chose this fate for himself! I merely retaliated in turn!"
        [/message]

        [message]
            speaker=Dela Keshar
            message= _ "How could ye possibly think Drogan was tha traitor when you’re the one attacking Parthyn?"
        [/message]

        [message]
            speaker=Malin Keshar
            message= _ "What? I have not harmed even a single villager or guardsman besides Drogan! I am only trying to help, but none of you will listen to reason!"
        [/message]

        [message]
            speaker=Dela Keshar
            message= _ "I tried to! I wanted ta believe in ya, I really did. After Father died, you and Drogan were all I had..."
        [/message]

        [message]
            speaker=Malin Keshar
            message= _ "Then why did you listen to him instead of me? I was trying to keep us together. He was trying to tear us apart! You wouldn’t even lift a finger to help me when he threatened to attack me!"
        [/message]

        [message]
            speaker=Dela Keshar
            message= _ "Malin, that’s—"
        [/message]

        [message]
            speaker=Malin Keshar
            message= _ "You’ve always been like this. You never think for yourself. You always just follow whatever other people tell you. Not a single original thought in your head."
        [/message]

        [message]
            speaker=Dela Keshar
            message= _ "Malin—"
        [/message]

        [message]
            speaker=Malin Keshar
            message= _ "That man used necromancy? He must be evil! Never mind that he be your own brother, trying to protect his own home!"
        [/message]

        {MODIFY_UNIT (id=Dela Keshar) profile (portraits/dela-mad.webp)}

        [message]
            speaker=Dela Keshar
            message= _ "Enough! There’s nothing I can say ta someone who embraces evil so shamelessly! You’ll pay for Drogan’s death!"
        [/message]

        [message]
            speaker=Malin Keshar
            message= _ "..."
        [/message]

        [message]
            speaker=Malin Keshar
            message= _ "<i>So, no matter what, she’ll be against me? Then this is hopeless. Even if they intend to fight me, I’ve no wish to fight the townsfolk...</i>"
        [/message]

        [message]
            speaker=Malin Keshar
            message= _ "<i>I guess I should just leave and find Darken Volk.</i>"
        [/message]

        {HIGHLIGHT_IMAGE 16 1 scenery/signpost.png ()}

        [objectives]
            side=1
            [objective]
                condition=win
                description= _ "Escape to the northwest"
            [/objective]

            {DID_RTP_OBJECTIVE_KILL_ORCS}

            [objective]
                condition=lose
                description= _ "Death of Malin Keshar"
            [/objective]

            {TURNS_RUN_OUT}

            [gold_carryover]
                bonus=no
                carryover_percentage=40
            [/gold_carryover]
        [/objectives]

        {PLACE_IMAGE scenery/dark-monolith.png 19 24}
        {PLACE_IMAGE "items/bones.png" $x1 $y1}
        {VARIABLE loc.x $x1}
        {VARIABLE loc.y $y1}

        [event]
            name=moveto
            [filter]
                id=Malin Keshar
                x,y=19,24
            [/filter]
            [message]
                speaker=narrator
                message= _ "A monolith of dark stone, shadowed panes reflecting distorted images."
            [/message]

#ifdef EASY
            {GIVE_MALIN_EXPERIENCE 12}
#endif
#ifdef NORMAL
            {GIVE_MALIN_EXPERIENCE 10}
#endif
#ifdef HARD
            {GIVE_MALIN_EXPERIENCE 8}
#endif

            {VARIABLE_OP monolith add 1}
            [progress_achievement]
                content_for=descent_into_darkness
                id="did_monolith"
                amount=1
                limit=$monolith
            [/progress_achievement]
        [/event]

        [event]
            name=moveto
            [filter]
                id=Malin Keshar
                x,y=16,1
            [/filter]

            [endlevel]
                result=victory
                bonus=no
                {NEW_GOLD_CARRYOVER 40}
            [/endlevel]
        [/event]

        [event]
            name=moveto
            [filter]
                id=Malin Keshar
                x,y=$loc.x,$loc.y
            [/filter]

            [animate_unit]
                [filter]
                    id=Malin Keshar
                [/filter]
                [primary_attack]
                    range=ranged
                [/primary_attack]
                flag=attack
            [/animate_unit]

            [delay]
                time=400
            [/delay]

            {REMOVE_IMAGE $loc.x $loc.y}

            [unit]
                type=Ghoul DiD
                id=DroganGhoul
                name= _ "Drogan"
                x,y=$loc.x,$loc.y
                side=1
                animate=yes
            [/unit]

            [message]
                speaker=DroganGhoul
                # po: This is just some guttural sound that a ghoul might make since it can't actually talk
                message= _ "Grahhhuralug..." # wmllint: no spellcheck
            [/message]

            [message]
                speaker=Malin Keshar
                message= _ "As ugly in death as he was in life. Darken Volk was right. It <i>is</i> fitting."
            [/message]

            [message]
                speaker=Dela Keshar
                message= _ "What have you done?! Killing Drogan wasn’t enough — ya had ta defile his body as well? How could ya turn him into such a... a hideous thing? I can’t believe how depraved you’ve become!"
            [/message]

            [message]
                speaker=Malin Keshar
                message= _ "What you see on the outside reflects the inside. The face of truth is undoubtedly an ugly one."
            [/message]

            [set_achievement]
                content_for=descent_into_darkness
                id="did_drogan"
            [/set_achievement]
        [/event]
    [/event]

    [event]
        name=time over

        [unit]
            type=Orcish Warlord
            side=2
            x,y=17,2
            id=OWarlord
            canrecruit=yes
            animate=yes
            facing=se
        [/unit]
        {GENERIC_UNIT 2 (Orcish Slurbow) 16 1} {FACING se}
        {GENERIC_UNIT 2 (Direwolf Rider) 15 2} {FACING se}
        {GENERIC_UNIT 2 (Goblin Pillager) 17 1} {FACING se}
        {GENERIC_UNIT 2 (Goblin Knight) 16 2} {FACING se}

        [message]
            speaker=OWarlord
            message= _ "Look what we have here! A human city on the verge of collapse and a necromancer with only a few paltry minions at his command. The wolves will feed well tonight!"
        [/message]
        [message]
            speaker=Malin Keshar
            message= _ "More orcs, and powerful ones at that! There’s no way I’m escaping now..."
        [/message]
    [/event]

    [event]
        name=victory

        [if]
            {DID_RTP_HAS_ORC_LEADER}
            [then]
                [message]
                    speaker=Dela Keshar
                    message= _ "Flee while you still can, Malin the Damned! When I have defeated these orcs and secured Parthyn against further raids, I will hunt you down and I will kill you. You are my brother no longer."
                [/message]
            [/then]
            [else]
                [message]
                    speaker=Dela Keshar
                    message= _ "Flee while you still can, Malin the Damned! When I have secured Parthyn against further raids, I will hunt you down and I will kill you. You are my brother no longer."
                [/message]
            [/else]
        [/if]

        [message]
            speaker=Malin Keshar
            # wmllint: local spelling Zephrin
            message= _ "O gods, how did it come to this? My own sister determined to personally see to my demise. Banished from Parthyn, my country, my home... spurned by my people, whom I have given everything for... nothing has gone right ever since I got into an argument with that fat, orc-loving toad Zephrin and tried to curse him. I was only testing my new spell on him! It was only supposed to be a simple curse! How was I supposed to know it would kill him? Blasted Academy."
        [/message]

        [message]
            speaker=Malin Keshar
            message= _ "... Now the only being who still wants to see me alive is a necromancer. I’m beginning to think that I’m the one who was cursed..."
        [/message]

        {CLEAR_VARIABLE malin_used_necromancy}
        {CLEAR_VARIABLE orc_leader_store}
        {CLEAR_VARIABLE fallback_orc_leader}
        {CLEAR_VARIABLE loc}
    [/event]

    {HERODEATH_MALIN}
[/scenario]

#undef DID_RTP_OBJECTIVE_KILL_ORCS
#undef DID_RTP_HAS_DROGAN
#undef DID_RTP_HAS_ORC_LEADER
