#textdomain wesnoth
# Music control macros, and declarations of sound resource lists.
#
# As of 1.1.3, music is parsed as follows:
#! 1. the [scenario]-level [music] tag
#! 2. the [story]-level music key
#! 3. any [event]-level [music] tags
#
# If you change the music at a lower level, the tags above it will NOT
# be re-parsed and your scenario will sound wrong.  For example, if
# you set scenario music with the normal [scenario]-level music tag
# but change the music during the [story], it is never reset back to
# normal.  Therefore, these macros are intended to catch instances
# like that.  Of course, if you want something more elaborate, code it
# manually.

# These macros do not rely on any other macros.  Please don't change this.

#define DEFAULT_MUSIC_PLAYLIST
    # A macro to define a standard playlist suitable for any level.  The
    # music is defined twice to catch instances where music is changed in
    # a story and not set back.
    [music]
        name=knolls.ogg
        ms_before=12000
    [/music]
    [music]
        name=wanderer.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=battle.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=transience.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=the_king_is_dead.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=knalgan_theme.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=the_city_falls.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=nunc_dimittis.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=revelation.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=loyalists.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=breaking_the_chains.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=elvish-theme.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=legends_of_the_north.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=traveling_minstrels.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=underground.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=vengeful.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=frantic.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=the_dangerous_symphony.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=heroes_rite.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=suspense.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=the_deep_path.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=siege_of_laurelmor.ogg
        ms_before=12000
        append=yes
    [/music]
    [music]
        name=casualties_of_war.ogg
        ms_before=12000
        append=yes
    [/music]
    [event]
        name=prestart
        [music]
            name=knolls.ogg
            ms_before=12000
        [/music]
        [music]
            name=wanderer.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=battle.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=transience.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=revelation.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=loyalists.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=the_king_is_dead.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=knalgan_theme.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=the_city_falls.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=nunc_dimittis.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=breaking_the_chains.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=elvish-theme.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=legends_of_the_north.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=traveling_minstrels.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=underground.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=vengeful.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=frantic.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=the_dangerous_symphony.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=heroes_rite.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=suspense.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=the_deep_path.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=siege_of_laurelmor.ogg
            ms_before=12000
            append=yes
        [/music]
        [music]
            name=casualties_of_war.ogg
            ms_before=12000
            append=yes
        [/music]
    [/event]
#enddef

#define SCENARIO_MUSIC MUSIC
    # This music macro ensures that the correct music is selected
    # for a scenario just in case it is changed by [story].
    # It should be positioned at the top of the scenario file
    # so it can be overridden by other prestart or start events.
    #
    # It also allows for the convenient use of standardized
    # intra-scenario music, should we decide to use one.
    [music]
        name="revelation.ogg"
    [/music]
    [event]
        name=prestart
        [music]
            name={MUSIC}
            immediate=yes
        [/music]
    [/event]
#enddef

#define EXTRA_SCENARIO_MUSIC MUSIC
    # Use this immediately after the above SCENARIO_MUSIC macro to append extra
    # tracks to the playlist.
    #
    # Example:
    #! {SCENARIO_MUSIC battle.ogg}
    #! {EXTRA_SCENARIO_MUSIC knolls.ogg}
    #! {EXTRA_SCENARIO_MUSIC frantic.ogg}
    [+event]
        [music]
            name={MUSIC}
            append=yes
        [/music]
    [/event]
#enddef

#define INTRO_AND_SCENARIO_MUSIC INTRO_MUSIC SCENARIO_MUSIC
    # This works as SCENARIO_MUSIC does, except that it allows you to specify
    # the music used for the story screen (if any) as well.
    [music]
        name={INTRO_MUSIC}
    [/music]
    [event]
        name=prestart
        [music]
            name={SCENARIO_MUSIC}
            append=no
        [/music]
    [/event]
#enddef

#define INCIDENTAL_MUSIC MUSIC
    # To be played immediately to mark an incident,
    # but not appended to the scenario playlist.
    # The playlist will be resumed afterwards.
    [music]
        name={MUSIC}
        play_once=yes
    [/music]
#enddef

#define APPEND_MUSIC MUSIC
    # Append to playlist.  Meant to be used after INCIDENTAL_MUSIC
    [music]
        name={MUSIC}
        append=yes
    [/music]
#enddef

#define REPLACE_SCENARIO_MUSIC MUSIC
    # To be used mid-scenario to replace the current playlist.
    [music]
        name={MUSIC}
        immediate=yes
        append=no
    [/music]
#enddef

# For some animations some units use a list of sounds, from which one is
# randomly picked every time, instead of a single sound. Here the most commonly
# used lists are wrapped inside macros.
#
# These are used in unit .cfg files, for example like this:
#
#!     [animation]
#!         hits=no
#!
#!         [frame]
#!             begin=-200
#!             end=0
#!             sound={SOUND_LIST:MISS}
#!             image="units/dwarves/warrior-attack.png"
#!         [/frame]

#define SOUND_LIST:HOLY
magic-holy-1.ogg,magic-holy-2.ogg,magic-holy-3.ogg,magic-holy-4.ogg #enddef

#define SOUND_LIST:HOLY_MISS
magic-holy-miss-1.ogg,magic-holy-miss-2.ogg,magic-holy-miss-3.ogg,magic-holy-miss-4.ogg #enddef

#define SOUND_LIST:MISS
miss-1.ogg,miss-2.ogg,miss-3.ogg #enddef

#define SOUND_LIST:THROW
throw-1.wav,throw-2.wav,throw-3.wav,throw-4.wav #enddef

#define SOUND_LIST:SWORD_SWISH
sword-1.ogg #enddef

#define SOUND_LIST:BAT_HIT
bat-hit-1.ogg,bat-hit-2.ogg,bat-hit-3.ogg,bat-hit-4.ogg #enddef

#define SOUND_LIST:DRAKE_HIT
drake-hit-1.ogg,drake-hit-2.ogg,drake-hit-3.ogg #enddef

#define SOUND_LIST:DWARF_HIT
dwarf-hit-1.ogg,dwarf-hit-2.ogg,dwarf-hit-3.ogg,dwarf-hit-4.ogg #enddef

#define SOUND_LIST:DWARF_DIE
dwarf-die-1.ogg,dwarf-die-2.ogg #enddef

#define SOUND_LIST:ELF_HIT
human-hit-1.ogg,human-hit-2.ogg,human-hit-3.ogg,human-hit-4.ogg,elf-hit-1.ogg,elf-hit-2.ogg #enddef

#define SOUND_LIST:ELF_FEMALE_HIT
human-female-hit-1.ogg,human-female-hit-2.ogg,human-female-hit-3.ogg #enddef

#define SOUND_LIST:GOBLIN_HIT
goblin-hit-1.ogg,goblin-hit-2.ogg,goblin-hit-3.ogg #enddef

#define SOUND_LIST:GOBLIN_DIE
goblin-die-1.ogg,goblin-die-2.ogg #enddef

#define SOUND_LIST:GRYPHON_HIT
gryphon-hit-1.ogg,gryphon-hit-2.ogg,gryphon-hit-3.ogg #enddef

#define SOUND_LIST:GRYPHON_DIE
gryphon-die-1.ogg,gryphon-die-2.ogg #enddef

#define SOUND_LIST:HORSE_HIT
horse-hit-1.ogg,horse-hit-2.ogg,horse-hit-3.ogg #enddef

#define SOUND_LIST:HUMAN_HIT
human-hit-1.ogg,human-hit-2.ogg,human-hit-3.ogg,human-hit-4.ogg,human-hit-5.ogg #enddef

#define SOUND_LIST:HUMAN_FEMALE_HIT
human-female-hit-1.ogg,human-female-hit-2.ogg,human-female-hit-3.ogg #enddef

#define SOUND_LIST:HUMAN_OLD_HIT
human-old-hit-1.ogg,human-old-hit-2.ogg,human-old-hit-3.ogg,human-old-hit-4.ogg #enddef

#define SOUND_LIST:HUMAN_OLD_DIE
human-old-die-1.ogg,human-old-die-2.ogg,human-old-die-3.ogg #enddef

#define SOUND_LIST:HUMAN_DIE
human-die-1.ogg,human-die-2.ogg,human-die-3.ogg #enddef

#define SOUND_LIST:HUMAN_FEMALE_DIE
human-female-die-1.ogg,human-female-die-2.ogg,human-female-die-3.ogg #enddef

#define SOUND_LIST:LICH_HIT
lich-hit-1.ogg,lich-hit-2.ogg #enddef

#define SOUND_LIST:NAGA_HIT
naga-hit-1.ogg,naga-hit-2.ogg,naga-hit-3.ogg #enddef

#define SOUND_LIST:OGRE_HIT
ogre-hit-1.ogg,ogre-hit-2.ogg,ogre-hit-3.ogg,ogre-hit-4.ogg #enddef

#define SOUND_LIST:OGRE_DIE
ogre-die-1.ogg,ogre-die-2.ogg,ogre-die-3.ogg #enddef

#define SOUND_LIST:ORC_HIT
orc-hit-1.ogg,orc-hit-2.ogg,orc-hit-3.ogg,orc-hit-4.ogg #enddef

#define SOUND_LIST:ORC_DIE
orc-die-1.ogg,orc-die-2.ogg,orc-die-3.ogg #enddef

#define SOUND_LIST:ORC_SMALL_HIT
orc-small-hit-1.ogg,orc-small-hit-2.ogg,orc-small-hit-3.ogg,orc-small-hit-4.ogg #enddef

#define SOUND_LIST:ORC_SMALL_DIE
orc-small-die-1.ogg,orc-small-die-2.ogg #enddef

#define SOUND_LIST:SKELETON_HIT
skeleton-hit-1.ogg,skeleton-hit-2.ogg,skeleton-hit-3.ogg #enddef

#define SOUND_LIST:SKELETON_BIG_HIT
skeleton-big-hit-1.ogg,skeleton-big-hit-2.ogg,skeleton-big-hit-3.ogg #enddef

#define SOUND_LIST:SKELETON_DIE
skeleton-die-1.ogg,skeleton-die-2.ogg #enddef

#define SOUND_LIST:TROLL_HIT
troll-hit-1.ogg,troll-hit-2.ogg,troll-hit-3.ogg,troll-hit-4.ogg #enddef

#define SOUND_LIST:TROLL_DIE
troll-die-1.ogg,troll-die-2.ogg,troll-die-3.ogg #enddef

#define SOUND_LIST:ZOMBIE_WEAK_HIT
zombie-hit-4.ogg,zombie-hit-5.ogg,zombie-hit-6.ogg #enddef

#define SOUND_LIST:ZOMBIE_HIT
zombie-hit-1.ogg,zombie-hit-2.ogg,zombie-hit-3.ogg,zombie-hit-4.ogg,zombie-hit-5.ogg,zombie-hit-6.ogg #enddef

#define SOUND:SLOW
    # A convenient way to use the standard slowing sound in an attack
    # animation. Put anywhere inside an attack animation block.
    [if]
        hits=hit
        [filter_second]
            [not]
                [filter_wml]
                    [status]
                        slowed="yes"
                    [/status]
                [/filter_wml]
            [/not]
        [/filter_second]

        slowed_sound_start_time=-100

        [slowed_sound_frame]
            duration=100
            sound=slowed.wav
        [/slowed_sound_frame]
    [/if]
#enddef

#define SOUND:POISON
    # A convenient way to use the standard poison sound in an attack
    # animation. Put anywhere inside an attack animation block.
    [if]
        hits=hit
        [filter_second]
            [not]
                [filter_wml]
                    [status]
                        poisoned="yes"
                    [/status]
                [/filter_wml]
            [/not]
        [/filter_second]

        poisoned_sound_start_time=-100

        [poisoned_sound_frame]
            duration=100
            sound=poison.ogg
        [/poisoned_sound_frame]
    [/if]
#enddef

#define SOUND:HIT_AND_MISS HITSOUND MISSSOUND TIME
    # A more convenient way of wiring in hit and miss sounds to an
    # attack animation. Just specify the sounds to use and the time
    # when they should trigger.
    [if]
        hits=yes

        attack_sound_start_time={TIME}

        [attack_sound_frame]
            sound={HITSOUND}
        [/attack_sound_frame]
    [/if]
    [else]
        hits=no

        attack_sound_start_time={TIME}

        [attack_sound_frame]
            sound={MISSSOUND}
        [/attack_sound_frame]
    [/else]
#enddef
