#textdomain wesnoth-utbs

[unit_type]
    id=Desert Hunter
    name= _ "Desert Hunter"
    race=elf
    gender=male,female
    image=units/elves-desert/hunter.png
    {MAGENTA_IS_THE_TEAM_COLOR}
    hitpoints=30
    movement_type=woodland
    #desert elves move fast across the sands, but are not used to forests
    #they are also a bit faster in caves
    [movement_costs]
        sand=1
        forest=2
        cave=2
        frozen=3
    [/movement_costs]
    [defense]
        sand=40
        forest=50
    [/defense]
    movement=6
    experience=42
    level=1
    alignment=lawful
    advances_to=Desert Sentinel
    cost=20
    usage=mixed fighter
    description= _ "Desert Hunters are trained to scour the sands for prey and enemies. They can quickly entangle others with their bolas and then finish them off with their swords."+{SPECIAL_NOTES}+{SPECIAL_NOTES_SLOW}
    die_sound={SOUND_LIST:ELF_HIT}
    {DEFENSE_ANIM_RANGE "units/elves-desert/hunter-sword-defend.png" units/elves-desert/hunter.png {SOUND_LIST:ELF_HIT} melee}
    {DEFENSE_ANIM_RANGE "units/elves-desert/hunter-ranged-defend.png" units/elves-desert/hunter.png {SOUND_LIST:ELF_HIT} ranged}
    [attack]
        name=sword
        description= _"sword"
        type=blade
        range=melee
        damage=5
        number=4
        icon=attacks/sword-elven.png
    [/attack]
    [attack]
        name=bolas
        description= _"bolas"
        type=impact
        range=ranged
        damage=4
        number=2
        [specials]
            {WEAPON_SPECIAL_SLOW}
        [/specials]
    [/attack]
    [attack_anim]
        [filter_attack]
            name=bolas
        [/filter_attack]
        [missile_frame]
            begin=-150
            end=0
            image=projectiles/bolas-n.png
            image_diagonal=projectiles/bolas-ne.png
        [/missile_frame]
        [frame]
            begin=-500
            end=-375
            image="units/elves-desert/hunter-ranged-1.png"
        [/frame]
        [if]
            hits=yes
            [frame]
                begin=-375
                end=-250
                image="units/elves-desert/hunter-ranged-2.png"
                sound=hatchet.wav
            [/frame]
        [/if]
        [else]
            hits=no
            [frame]
                begin=-375
                end=-250
                image="units/elves-desert/hunter-ranged-2.png"
                sound=hatchet-miss.wav
            [/frame]
        [/else]
        [frame]
            begin=-250
            end=-125
            image="units/elves-desert/hunter-ranged-3.png"
        [/frame]
        [frame]
            begin=-125
            end=-100
            image="units/elves-desert/hunter-ranged-4.png"
        [/frame]
        [frame]
            begin=-100
            end=0
            image="units/elves-desert/hunter-ranged-4.png"
        [/frame]
        {SOUND:SLOW}
    [/attack_anim]
    [attack_anim]
        [filter_attack]
            name=sword
        [/filter_attack]
        [frame]
            begin=-200
            end=-175
            image="units/elves-desert/hunter.png"
        [/frame]
        [frame]
            begin=-175
            end=-75
            image="units/elves-desert/hunter-sword-1.png"
        [/frame]
        [if]
            hits=no
            [frame]
                begin=-75
                end=75
                image="units/elves-desert/hunter-sword-2.png"
                sound={SOUND_LIST:MISS}
            [/frame]
        [/if]
        [else]
            hits=yes
            [frame]
                begin=-75
                end=75
                image="units/elves-desert/hunter-sword-2.png"
                sound={SOUND_LIST:SWORD_SWISH}
            [/frame]
        [/else]
        [frame]
            begin=75
            end=125
            image="units/elves-desert/hunter-sword-3.png"
        [/frame]
        [frame]
            begin=125
            end=175
            image="units/elves-desert/hunter-sword-4.png"
        [/frame]
        [frame]
            begin=175
            end=200
            image="units/elves-desert/hunter.png"
        [/frame]
    [/attack_anim]
    [female]
        name= _ "female^Desert Hunter"
        gender=female
        image="units/elves-desert/hunter+female.png"
        die_sound={SOUND_LIST:ELF_FEMALE_HIT}
        {DEFENSE_ANIM_RANGE "units/elves-desert/hunter+female-sword-defend.png" "units/elves-desert/hunter+female.png" {SOUND_LIST:ELF_FEMALE_HIT} melee}
        {DEFENSE_ANIM_RANGE "units/elves-desert/hunter+female-ranged-defend.png" "units/elves-desert/hunter+female.png" {SOUND_LIST:ELF_FEMALE_HIT} ranged}
        [attack_anim]
            [filter_attack]
                name=bolas
            [/filter_attack]
            [missile_frame]
                begin=-150
                end=0
                image=projectiles/bolas-n.png
                image_diagonal=projectiles/bolas-ne.png
            [/missile_frame]
            [frame]
                image="units/elves-desert/hunter+female-ranged-1.png"
            [/frame]
            [if]
                [frame]
                    image="units/elves-desert/hunter+female-ranged-2.png"
                [/frame]
            [/if]
            [else]
                [frame]
                    image="units/elves-desert/hunter+female-ranged-2.png"
                [/frame]
            [/else]
            [frame]
                image="units/elves-desert/hunter+female-ranged-3.png"
            [/frame]
            [frame]
                image="units/elves-desert/hunter+female-ranged-4.png"
            [/frame]
            [frame]
                image="units/elves-desert/hunter+female-ranged-4.png"
            [/frame]
        [/attack_anim]
        [attack_anim]
            [filter_attack]
                name=sword
            [/filter_attack]
            [frame]
                image="units/elves-desert/hunter+female.png"
            [/frame]
            [frame]
                image="units/elves-desert/hunter+female-sword-1.png"
            [/frame]
            [if]
                [frame]
                    image="units/elves-desert/hunter+female-sword-2.png"
                [/frame]
            [/if]
            [else]
                [frame]
                    image="units/elves-desert/hunter+female-sword-2.png"
                [/frame]
            [/else]
            [frame]
                image="units/elves-desert/hunter+female-sword-3.png"
            [/frame]
            [frame]
                image="units/elves-desert/hunter+female-sword-4.png"
            [/frame]
            [frame]
                image="units/elves-desert/hunter+female.png"
            [/frame]
        [/attack_anim]
    [/female]
[/unit_type]

#define DESERT_HUNTER_VARIANT SUFFIX_NUMBER COST
    [unit_type]
        id=Desert Hunter{SUFFIX_NUMBER}
        [base_unit]
            id=Desert Hunter
        [/base_unit]
        hide_help=true
        do_not_list=true
        cost={COST}
    [/unit_type]
#enddef

{DESERT_HUNTER_VARIANT  1 21}
{DESERT_HUNTER_VARIANT  2 22}
{DESERT_HUNTER_VARIANT  3 23}
{DESERT_HUNTER_VARIANT  4 24}
{DESERT_HUNTER_VARIANT  5 25}
{DESERT_HUNTER_VARIANT  6 26}
{DESERT_HUNTER_VARIANT  7 27}
{DESERT_HUNTER_VARIANT  8 28}
{DESERT_HUNTER_VARIANT  9 29}
{DESERT_HUNTER_VARIANT 10 30}

#undef DESERT_HUNTER_VARIANT
