Added ECM, mag bolt hit, and power down sounds.

This commit is contained in:
Steve 2016-02-20 14:19:59 +00:00
parent 480192efe1
commit da71c1d647
7 changed files with 12 additions and 0 deletions

Binary file not shown.

Binary file not shown.

View File

@ -220,6 +220,8 @@ void doFighter(void)
if ((self->flags & EF_DISABLED) == 0)
{
playBattleSound(SND_POWER_DOWN, self->x, self->y);
self->flags |= EF_DISABLED;
battle.stats[STAT_ENEMIES_DISABLED]++;
@ -390,6 +392,8 @@ void damageFighter(Entity *e, int amount, long flags)
if (flags & BF_SYSTEM_DAMAGE)
{
playBattleSound(SND_MAG_HIT, e->x, e->y);
e->systemPower = MAX(0, e->systemPower - amount);
e->systemHit = 255;

View File

@ -172,6 +172,8 @@ static void handleKeyboard(void)
{
if (battle.ecmTimer == ECM_RECHARGE_TIME)
{
playSound(SND_ECM);
activateECM();
}
else

View File

@ -196,6 +196,9 @@ enum
SND_MISSILE,
SND_INCOMING,
SND_JUMP,
SND_ECM,
SND_MAG_HIT,
SND_POWER_DOWN,
SND_BOOST,
SND_RADIO,
SND_GUI_CLICK,

View File

@ -108,6 +108,9 @@ static void loadSounds(void)
sounds[SND_EXPLOSION_3] = Mix_LoadWAV(getFileLocation("sound/254071__tb0y298__firework-explosion.ogg"));
sounds[SND_EXPLOSION_4] = Mix_LoadWAV(getFileLocation("sound/47252__nthompson__bad-explosion.ogg"));
sounds[SND_JUMP] = Mix_LoadWAV(getFileLocation("sound/276912__pauldihor__transform.ogg"));
sounds[SND_ECM] = Mix_LoadWAV(getFileLocation("sound/251431__onlytheghosts__fusion-gun-flash0-by-onlytheghosts.ogg"));
sounds[SND_MAG_HIT] = Mix_LoadWAV(getFileLocation("sound/172591__timbre__zapitydooda.ogg"));
sounds[SND_POWER_DOWN] = Mix_LoadWAV(getFileLocation("sound/39030__wildweasel__d1clsstf.ogg"));
sounds[SND_GUI_CLICK] = Mix_LoadWAV(getFileLocation("sound/257786__xtrgamr__mouse-click.ogg"));
sounds[SND_GUI_SELECT] = Mix_LoadWAV(getFileLocation("sound/321104__nsstudios__blip2.ogg"));