Skip to content

Commit

Permalink
A bit of VB cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
JordanLongstaff committed Dec 13, 2024
1 parent 93cffd9 commit 55b4181
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
5 changes: 2 additions & 3 deletions soh/soh/Enhancements/game-interactor/GameInteractor.h
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,7 @@ typedef enum {
/*** Play Cutscenes ***/

VB_PLAY_TRANSITION_CS,
VB_PLAY_GORON_FREE_CS,
VB_PLAY_FIRE_ARROW_CS,
// Vanilla condition: INV_CONTENT(ITEM_ARROW_FIRE) == ITEM_NONE
VB_SPAWN_FIRE_ARROW,
Expand Down Expand Up @@ -332,8 +333,6 @@ typedef enum {
VB_PLAY_BOLERO_OF_FIRE_CS,
VB_PLAY_SERENADE_OF_WATER_CS,
VB_PLAY_EYEDROPS_CS,
// Opt: *EnGo2
VB_PLAY_GORON_FREE_CS,
// Opt: *EnOkarinaTag
VB_PLAY_DRAIN_WELL_CS,
// Opt: *EnOkarinaTag
Expand Down Expand Up @@ -374,6 +373,7 @@ typedef enum {

/*** Give Items ***/

VB_FREEZE_ON_SKULL_TOKEN,
// Opt: *EnBox
VB_GIVE_ITEM_FROM_CHEST,
// Opt: ItemID
Expand All @@ -382,7 +382,6 @@ typedef enum {
VB_GIVE_ITEM_FROM_ITEM_00,
// Opt: *EnSi
VB_GIVE_ITEM_SKULL_TOKEN,
VB_FREEZE_ON_SKULL_TOKEN,
// Opt: *EnCow
VB_GIVE_ITEM_FROM_COW,
// Opt: *EnDns
Expand Down
6 changes: 3 additions & 3 deletions soh/src/overlays/actors/ovl_En_Si/z_en_si.c
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ void func_80AFB768(EnSi* this, PlayState* play) {
this->collider.base.ocFlags2 &= ~OC2_HIT_PLAYER;
if (GameInteractor_Should(VB_GIVE_ITEM_SKULL_TOKEN, true, this)) {
Item_Give(play, ITEM_SKULL_TOKEN);
if (GameInteractor_Should(VB_FREEZE_ON_SKULL_TOKEN, true, this)) {
if (GameInteractor_Should(VB_FREEZE_ON_SKULL_TOKEN, true)) {
player->actor.freezeTimer = 10;
}
Message_StartTextbox(play, TEXT_GS_NO_FREEZE, NULL);
Expand All @@ -124,7 +124,7 @@ void func_80AFB89C(EnSi* this, PlayState* play) {
if (!CHECK_FLAG_ALL(this->actor.flags, ACTOR_FLAG_HOOKSHOT_ATTACHED)) {
if (GameInteractor_Should(VB_GIVE_ITEM_SKULL_TOKEN, true, this)) {
Item_Give(play, ITEM_SKULL_TOKEN);
if (GameInteractor_Should(VB_FREEZE_ON_SKULL_TOKEN, true, this)) {
if (GameInteractor_Should(VB_FREEZE_ON_SKULL_TOKEN, true)) {
player->actor.freezeTimer = 10;
}
Message_StartTextbox(play, TEXT_GS_NO_FREEZE, NULL);
Expand All @@ -137,7 +137,7 @@ void func_80AFB89C(EnSi* this, PlayState* play) {
void func_80AFB950(EnSi* this, PlayState* play) {
Player* player = GET_PLAYER(play);

if (Message_GetState(&play->msgCtx) != TEXT_STATE_CLOSING && GameInteractor_Should(VB_FREEZE_ON_SKULL_TOKEN, true, this)) {
if (Message_GetState(&play->msgCtx) != TEXT_STATE_CLOSING && GameInteractor_Should(VB_FREEZE_ON_SKULL_TOKEN, true)) {
player->actor.freezeTimer = 10;
} else {
SET_GS_FLAGS((this->actor.params & 0x1F00) >> 8, this->actor.params & 0xFF);
Expand Down

0 comments on commit 55b4181

Please sign in to comment.