#textdomain wesnoth-trow

#I'm putting TROW's common Macros in here.
#This should make my WML a little more sane
#So Far:
#LOOT
#GUARD_UNIT
#HERO
#UNDEAD_INTEL
#RISE_UP_RISE_UP

#define LOOT AMOUNT SIDE
    [sound]
        name=gold.ogg
    [/sound]

    {VARIABLE amount_gold {AMOUNT}}

    [message]
        speaker=narrator
        message= _ "You retrieve $amount_gold pieces of gold."
        image=wesnoth-icon.png
    [/message]

    {CLEAR_VARIABLE amount_gold}

    [gold]
        side={SIDE}
        amount={AMOUNT}
    [/gold]
#enddef

#define HERO TYPE DESCRIPTION USER_DESCRIPTION SIDE X Y PROFILE
    [unit]
        type={TYPE}
        description={DESCRIPTION}
        user_description={USER_DESCRIPTION}
        profile={PROFILE}
        side={SIDE}
        x={X}
        y={Y}
        {IS_HERO}
        unrenamable=yes
        random_traits=no
        [modifications]
            {TRAIT_LOYAL}
        [/modifications]
    [/unit]
#enddef

#define GUARD_UNIT TYPE DESCRIPTION USER_DESCRIPTION SIDE X Y
    [unit]
        type={TYPE}
        description={DESCRIPTION}
        user_description={USER_DESCRIPTION}
        side={SIDE}
        x={X}
        y={Y}

        ai_special=guardian

        [modifications]
            {TRAIT_LOYAL}
        [/modifications]
    [/unit]
#enddef

#define UNDEAD_INTEL TYPE DESCRIPTION USER_DESCRIPTION VALUE SIDE X Y
    [unit]
        type={TYPE}
        description={DESCRIPTION}
        user_description={USER_DESCRIPTION}
        profile={VALUE}
        side={SIDE}
        x={X}
        y={Y}
        [modifications]
            {TRAIT_UNDEAD}
            {TRAIT_LOYAL}
        [/modifications]
    [/unit]
#enddef

#define RISE_UP_RISE_UP X Y
    [filter]
        side=1
    [/filter]
    [filter_second]
        [not]
            #Basically not any type that has plague
            type=Walking Corpse,Soulless
        [/not]
    [/filter_second]

    [store_unit]
        variable=dead_store
        kill=yes
        [filter]
            x={X}
            y={Y}
        [/filter]
    [/store_unit]

#ifdef EASY
    [unit]
        description=A Former Friend
        user_description= _ "A Former Friend"
        type=Walking Corpse
        side=2
        x={X}
        y={Y}
        moves=0
        [modifications]
            {TRAIT_UNDEAD}
            {TRAIT_LOYAL}
        [/modifications]
    [/unit]
#endif
#ifdef NORMAL
    [unit]
        description=A Former Friend
        user_description= _ "A Former Friend"
        type=Soulless
        side=2
        x={X}
        y={Y}
        moves=0
        [modifications]
            {TRAIT_UNDEAD}
            {TRAIT_LOYAL}
        [/modifications]
    [/unit]
#endif
#ifdef HARD
    [unit]
        description=A Former Friend
        user_description= _ "A Former Friend"
        type=Ghoul
        side=2
        x={X}
        y={Y}
        moves=0
        [modifications]
            {TRAIT_UNDEAD}
            {TRAIT_LOYAL}
        [/modifications]
    [/unit]

    {CLEAR_VARIABLE dead_store}
#endif
#enddef

#define TROW_GREEN_ISLE_LABELS
    [image]
        x=253
        y=111
        file=story/tgi-thegreenisle.png
    [/image]
    [image]
        x=635
        y=282
        file=story/tgi-blackmore.png
    [/image]
    [image]
        x=566
        y=388
        file=story/tgi-clearwater.png
    [/image]
    [image]
        x=398
        y=190
        file=story/tgi-jevyan.png
    [/image]
    [image]
        x=394
        y=476
        file=story/tgi-southbay.png
    [/image]
    [image]
        x=322
        y=314
        file=story/tgi-stormvale.png
    [/image]
#enddef

#define TROW_GREEN_ISLE_LABELS_NO_TITLE
    [image]
        x=635
        y=282
        file=story/tgi-blackmore.png
    [/image]
    [image]
        x=566
        y=388
        file=story/tgi-clearwater.png
    [/image]
    [image]
        x=398
        y=190
        file=story/tgi-jevyan.png
    [/image]
    [image]
        x=394
        y=476
        file=story/tgi-southbay.png
    [/image]
    [image]
        x=322
        y=314
        file=story/tgi-stormvale.png
    [/image]
#enddef
