summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEblo <7004497+Eblo@users.noreply.github.com>2026-07-26 22:19:18 -0400
committerGitHub <noreply@github.com>2026-07-26 21:19:18 -0500
commitd66aafc3779f2aab5b69125c2b0bba24e52c6821 (patch)
treeb19e33de455381d0ac55f0a4017b7172c868f1c9
parentd89ecccee0b729372697ae35c8ade872ee8013f8 (diff)
Fix SkipBottleCatch turning chests into ocarinas (#1816)
-rw-r--r--mm/2s2h/Enhancements/Dialogue/SkipBottleCatch.cpp34
1 files changed, 18 insertions, 16 deletions
diff --git a/mm/2s2h/Enhancements/Dialogue/SkipBottleCatch.cpp b/mm/2s2h/Enhancements/Dialogue/SkipBottleCatch.cpp
index fdd4163c4..375e5cec5 100644
--- a/mm/2s2h/Enhancements/Dialogue/SkipBottleCatch.cpp
+++ b/mm/2s2h/Enhancements/Dialogue/SkipBottleCatch.cpp
@@ -8,26 +8,28 @@
void RegisterSkipBottleCatchCutscene() {
COND_VB_SHOULD(VB_PLAY_BOTTLE_CATCH_TEXT, CVAR, {
- Player* player = va_arg(args, Player*);
- Actor* interactRangeActor = va_arg(args, Actor*);
- ItemId itemId = (ItemId)va_arg(args, int);
- PlayerItemAction itemAction = (PlayerItemAction)va_arg(args, int);
+ if (*should) {
+ Player* player = va_arg(args, Player*);
+ Actor* interactRangeActor = va_arg(args, Actor*);
+ ItemId itemId = (ItemId)va_arg(args, int);
+ PlayerItemAction itemAction = (PlayerItemAction)va_arg(args, int);
- interactRangeActor->parent = &player->actor;
- Player_UpdateBottleHeld(gPlayState, player, itemId, itemAction);
- Audio_PlayFanfare(NA_BGM_GET_ITEM);
+ interactRangeActor->parent = &player->actor;
+ Player_UpdateBottleHeld(gPlayState, player, itemId, itemAction);
+ Audio_PlayFanfare(NA_BGM_GET_ITEM);
- if (itemAction == PLAYER_IA_BOTTLE_DEKU_PRINCESS) {
- // Kill Deku Princess actor immediately upon capture
- Actor_Kill(interactRangeActor);
- }
+ if (itemAction == PLAYER_IA_BOTTLE_DEKU_PRINCESS) {
+ // Kill Deku Princess actor immediately upon capture
+ Actor_Kill(interactRangeActor);
+ }
- Notification::Emit({
- .itemIcon = (const char*)gItemIcons[itemId],
- .message = "Caught!",
- });
+ Notification::Emit({
+ .itemIcon = (const char*)gItemIcons[itemId],
+ .message = "Caught!",
+ });
- *should = false;
+ *should = false;
+ }
});
}