From ac45e70e5c7310ca7fd270452d158dea04bd3d99 Mon Sep 17 00:00:00 2001 From: Tubular Bells <60239773+MSpiller7@users.noreply.github.com> Date: Wed, 21 Sep 2022 18:29:00 -0500 Subject: [PATCH] Restored exit course sound effect functionality independent of vanilla level check. (#475) May be worth revisiting in the future to address the fact the exit course warp node will always trigger this sound effect, even when shared with other warps. Would potentially also be nice to add an option for using this sound effect with 0xF3 floor warps. --- src/game/level_update.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/game/level_update.c b/src/game/level_update.c index e0b17652..713b2a8f 100644 --- a/src/game/level_update.c +++ b/src/game/level_update.c @@ -410,7 +410,7 @@ void init_mario_after_warp(void) { } if (sWarpDest.levelNum == LEVEL_CASTLE && sWarpDest.areaIdx == 1 - && (sWarpDest.nodeId == 31 || sWarpDest.nodeId == 32) + && (sWarpDest.nodeId == 32) ) { play_sound(SOUND_MENU_MARIO_CASTLE_WARP, gGlobalSoundSource); } @@ -420,6 +420,13 @@ void init_mario_after_warp(void) { || sWarpDest.nodeId == 30)) { play_sound(SOUND_MENU_MARIO_CASTLE_WARP, gGlobalSoundSource); } +#endif +#ifndef DISABLE_EXIT_COURSE + if (sWarpDest.levelNum == EXIT_COURSE_LEVEL && sWarpDest.areaIdx == EXIT_COURSE_AREA + && sWarpDest.nodeId == EXIT_COURSE_NODE + ) { + play_sound(SOUND_MENU_MARIO_CASTLE_WARP, gGlobalSoundSource); + } #endif } }