diff options
author | GriffinR <griffin.g.richards@gmail.com> | 2020-08-28 16:17:11 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-08-28 16:17:11 -0400 |
commit | 0cfc279af54aa1f21f08acd4043cf82be771c8a4 (patch) | |
tree | 464418e98106f5a4ac5a7db31415d8393e40aced /src/battle_gfx_sfx_util.c | |
parent | 38d4fc9c17467bfbb206116e4bef4648cedfe3d4 (diff) | |
parent | 09cfed64b5a10a51ca246ce7a4f57b95cf4b4456 (diff) |
Merge branch 'master' into doc-rayscene
Diffstat (limited to 'src/battle_gfx_sfx_util.c')
-rw-r--r-- | src/battle_gfx_sfx_util.c | 21 |
1 files changed, 9 insertions, 12 deletions
diff --git a/src/battle_gfx_sfx_util.c b/src/battle_gfx_sfx_util.c index 50a5f8ad5..b1bb61aaf 100644 --- a/src/battle_gfx_sfx_util.c +++ b/src/battle_gfx_sfx_util.c @@ -1014,15 +1014,12 @@ void BattleLoadSubstituteOrMonSpriteGfx(u8 battlerId, bool8 loadMonSprite) palOffset = (battlerId * 16) + 0x100; LoadCompressedPalette(gSubstituteDollPal, palOffset, 32); } - else + else if (!IsContest()) { - if (!IsContest()) - { - if (GetBattlerSide(battlerId) != B_SIDE_PLAYER) - BattleLoadOpponentMonSpriteGfx(&gEnemyParty[gBattlerPartyIndexes[battlerId]], battlerId); - else - BattleLoadPlayerMonSpriteGfx(&gPlayerParty[gBattlerPartyIndexes[battlerId]], battlerId); - } + if (GetBattlerSide(battlerId) != B_SIDE_PLAYER) + BattleLoadOpponentMonSpriteGfx(&gEnemyParty[gBattlerPartyIndexes[battlerId]], battlerId); + else + BattleLoadPlayerMonSpriteGfx(&gPlayerParty[gBattlerPartyIndexes[battlerId]], battlerId); } } @@ -1058,7 +1055,7 @@ void HandleLowHpMusicChange(struct Pokemon *mon, u8 battlerId) if (!gBattleSpritesDataPtr->battlerData[battlerId].lowHpSong) { if (!gBattleSpritesDataPtr->battlerData[battlerId ^ BIT_FLANK].lowHpSong) - PlaySE(SE_HINSI); + PlaySE(SE_LOW_HEALTH); gBattleSpritesDataPtr->battlerData[battlerId].lowHpSong = 1; } } @@ -1067,12 +1064,12 @@ void HandleLowHpMusicChange(struct Pokemon *mon, u8 battlerId) gBattleSpritesDataPtr->battlerData[battlerId].lowHpSong = 0; if (!IsDoubleBattle()) { - m4aSongNumStop(SE_HINSI); + m4aSongNumStop(SE_LOW_HEALTH); return; } if (IsDoubleBattle() && !gBattleSpritesDataPtr->battlerData[battlerId ^ BIT_FLANK].lowHpSong) { - m4aSongNumStop(SE_HINSI); + m4aSongNumStop(SE_LOW_HEALTH); return; } } @@ -1086,7 +1083,7 @@ void BattleStopLowHpSound(void) if (IsDoubleBattle()) gBattleSpritesDataPtr->battlerData[playerBattler ^ BIT_FLANK].lowHpSong = 0; - m4aSongNumStop(SE_HINSI); + m4aSongNumStop(SE_LOW_HEALTH); } u8 GetMonHPBarLevel(struct Pokemon *mon) |