diff --git a/soh/soh/Enhancements/game-interactor/GameInteractor.h b/soh/soh/Enhancements/game-interactor/GameInteractor.h index 844e91c37..44d0ef1fc 100644 --- a/soh/soh/Enhancements/game-interactor/GameInteractor.h +++ b/soh/soh/Enhancements/game-interactor/GameInteractor.h @@ -127,6 +127,7 @@ typedef enum { */ VB_BE_ELIGIBLE_FOR_NOCTURNE_OF_SHADOW, // Opt: *EnGo2 + VB_GORON_LINK_BE_SCARED, // Vanilla condition: CUR_CAPACITY(UPG_BOMB_BAG) >= 20 && this->waypoint > 7 && this->waypoint < 12 VB_BE_ELIGIBLE_FOR_CHILD_ROLLING_GORON_REWARD, // Vanilla condition: !CHECK_OWNED_EQUIP_ALT(EQUIP_TYPE_SWORD, EQUIP_INV_SWORD_BIGGORON) diff --git a/soh/soh/Enhancements/timesaver_hook_handlers.cpp b/soh/soh/Enhancements/timesaver_hook_handlers.cpp index dbfca709c..2e097f538 100644 --- a/soh/soh/Enhancements/timesaver_hook_handlers.cpp +++ b/soh/soh/Enhancements/timesaver_hook_handlers.cpp @@ -39,6 +39,8 @@ extern int32_t D_8011D3AC; extern void BgSpot03Taki_HandleWaterfallState(BgSpot03Taki* bgSpot03Taki, PlayState* play); extern void BgSpot03Taki_ApplyOpeningAlpha(BgSpot03Taki* bgSpot03Taki, s32 bufferIndex); +extern void EnGo2_CurledUp(EnGo2* enGo2, PlayState* play); + extern void EnRu2_SetEncounterSwitchFlag(EnRu2* enRu2, PlayState* play); } @@ -359,6 +361,18 @@ void TimeSaverOnVanillaBehaviorHandler(GIVanillaBehavior id, bool* should, va_li } break; } + case VB_GORON_LINK_BE_SCARED: { + if (ForcedDialogIsDisabled(FORCED_DIALOG_SKIP_NPC)) { + EnGo2* goronLink = va_arg(args, EnGo2*); + goronLink->trackingMode = NPC_TRACKING_NONE; + goronLink->unk_211 = false; + goronLink->isAwake = false; + goronLink->actionFunc = EnGo2_CurledUp; + Flags_SetInfTable(INFTABLE_STOPPED_GORON_LINKS_ROLLING); + *should = false; + } + break; + } case VB_NOT_BE_GREETED_BY_SARIA: if (CVarGetInteger(CVAR_ENHANCEMENT("TimeSavers.SkipCutscene.Entrances"), IS_RANDO) && !Flags_GetInfTable(INFTABLE_GREETED_BY_SARIA)) { Flags_SetInfTable(INFTABLE_GREETED_BY_SARIA); diff --git a/soh/src/overlays/actors/ovl_En_Go2/z_en_go2.c b/soh/src/overlays/actors/ovl_En_Go2/z_en_go2.c index 547524eda..950a62964 100644 --- a/soh/src/overlays/actors/ovl_En_Go2/z_en_go2.c +++ b/soh/src/overlays/actors/ovl_En_Go2/z_en_go2.c @@ -1768,8 +1768,10 @@ void EnGo2_GroundRolling(EnGo2* this, PlayState* play) { if (this->unk_59C == 0) { switch (this->actor.params & 0x1F) { case GORON_CITY_LINK: - this->goronState = 0; - this->actionFunc = EnGo2_GoronLinkStopRolling; + if (GameInteractor_Should(VB_GORON_LINK_BE_SCARED, true, this)) { + this->goronState = 0; + this->actionFunc = EnGo2_GoronLinkStopRolling; + } break; case GORON_CITY_ROLLING_BIG: EnGo2_WakeUp(this, play);