diff --git a/soh/soh/Enhancements/randomizer/draw.h b/soh/soh/Enhancements/randomizer/draw.h index ea56e6e32..ec390c002 100644 --- a/soh/soh/Enhancements/randomizer/draw.h +++ b/soh/soh/Enhancements/randomizer/draw.h @@ -24,7 +24,7 @@ void Randomizer_DrawFishingPoleGI(PlayState* play, GetItemEntry* getItemEntry); void Randomizer_DrawMysteryItem(PlayState* play, GetItemEntry getItemEntry); #define GET_ITEM_MYSTERY \ - { ITEM_NONE, 0, 0, 0, 0, 0, 0, 0, 0, false, ITEM_FROM_NPC, ITEM_CATEGORY_JUNK, Randomizer_DrawMysteryItem } + { ITEM_NONE_FE, 0, 0, 0, 0, 0, 0, ITEM_NONE_FE, 0, false, ITEM_FROM_NPC, ITEM_CATEGORY_JUNK, NULL, MOD_RANDOMIZER, (CustomDrawFunc)Randomizer_DrawMysteryItem } #ifdef __cplusplus }; #endif diff --git a/soh/soh/Enhancements/randomizer/hook_handlers.cpp b/soh/soh/Enhancements/randomizer/hook_handlers.cpp index db388ae1c..c3669af56 100644 --- a/soh/soh/Enhancements/randomizer/hook_handlers.cpp +++ b/soh/soh/Enhancements/randomizer/hook_handlers.cpp @@ -33,6 +33,8 @@ extern "C" { #include "src/overlays/actors/ovl_En_Bom_Bowl_Pit/z_en_bom_bowl_pit.h" #include "src/overlays/actors/ovl_En_Ge1/z_en_ge1.h" #include "adult_trade_shuffle.h" +#include "draw.h" + extern SaveContext gSaveContext; extern PlayState* gPlayState; } @@ -357,13 +359,21 @@ void EnExItem_WaitForObjectRandomized(EnExItem* enExItem, PlayState* play) { void EnItem00_DrawRandomizedItem(EnItem00* enItem00, PlayState* play) { f32 mtxScale = CVarGetFloat(CVAR_ENHANCEMENT("TimeSavers.SkipGetItemAnimationScale"), 10.0f); Matrix_Scale(mtxScale, mtxScale, mtxScale, MTXMODE_APPLY); - EnItem00_CustomItemsParticles(&enItem00->actor, play, enItem00->itemEntry); - GetItemEntry_Draw(play, enItem00->itemEntry); + GetItemEntry randoItem = enItem00->itemEntry; + if (CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0)) { + randoItem = GET_ITEM_MYSTERY; + } + EnItem00_CustomItemsParticles(&enItem00->actor, play, randoItem); + GetItemEntry_Draw(play, randoItem); } void ItemBHeart_DrawRandomizedItem(ItemBHeart* itemBHeart, PlayState* play) { - EnItem00_CustomItemsParticles(&itemBHeart->actor, play, itemBHeart->sohItemEntry); - GetItemEntry_Draw(play, itemBHeart->sohItemEntry); + GetItemEntry randoItem = itemBHeart->sohItemEntry; + if (CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0)) { + randoItem = GET_ITEM_MYSTERY; + } + EnItem00_CustomItemsParticles(&itemBHeart->actor, play, randoItem); + GetItemEntry_Draw(play, randoItem); } void ItemBHeart_UpdateRandomizedItem(Actor* actor, PlayState* play) { @@ -378,14 +388,18 @@ void ItemBHeart_UpdateRandomizedItem(Actor* actor, PlayState* play) { } void ItemEtcetera_DrawRandomizedItem(ItemEtcetera* itemEtcetera, PlayState* play) { - EnItem00_CustomItemsParticles(&itemEtcetera->actor, play, itemEtcetera->sohItemEntry); + GetItemEntry randoItem = itemEtcetera->sohItemEntry; + if (CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0)) { + randoItem = GET_ITEM_MYSTERY; + } + EnItem00_CustomItemsParticles(&itemEtcetera->actor, play, randoItem); func_8002EBCC(&itemEtcetera->actor, play, 0); func_8002ED80(&itemEtcetera->actor, play, 0); - GetItemEntry_Draw(play, itemEtcetera->sohItemEntry); + GetItemEntry_Draw(play, randoItem); } void ItemEtcetera_DrawRandomizedItemThroughLens(ItemEtcetera* itemEtcetera, PlayState* play) { - if (play->actorCtx.lensActive) { + if (play->actorCtx.lensActive) { // todo [Rando] mysterious shuffle for chest minigame key shuffle ItemEtcetera_DrawRandomizedItem(itemEtcetera, play); } } @@ -1160,10 +1174,14 @@ void RandomizerOnSceneInitHandler(int16_t sceneNum) { } void EnSi_DrawRandomizedItem(EnSi* enSi, PlayState* play) { + GetItemEntry randoItem = enSi->sohGetItemEntry; + if (CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0)) { + randoItem = GET_ITEM_MYSTERY; + } func_8002ED80(&enSi->actor, play, 0); func_8002EBCC(&enSi->actor, play, 0); - EnItem00_CustomItemsParticles(&enSi->actor, play, enSi->sohGetItemEntry); - GetItemEntry_Draw(play, enSi->sohGetItemEntry); + EnItem00_CustomItemsParticles(&enSi->actor, play, randoItem); + GetItemEntry_Draw(play, randoItem); } u32 EnDns_RandomizerPurchaseableCheck(EnDns* enDns) { diff --git a/soh/soh/Enhancements/randomizer/randomizer.h b/soh/soh/Enhancements/randomizer/randomizer.h index acbc3ad7f..3e6df6213 100644 --- a/soh/soh/Enhancements/randomizer/randomizer.h +++ b/soh/soh/Enhancements/randomizer/randomizer.h @@ -11,7 +11,7 @@ #include #include "soh/Enhancements/randomizer/randomizer_check_objects.h" #include "soh/Enhancements/randomizer/randomizer_check_tracker.h" -#include "soh/Enhancements/randomizer/randomizer_tricks.h" +#include "soh/Enhancements/randomizer/tricks.h" #include #include "soh/Enhancements/item-tables/ItemTableTypes.h" #include "../custom-message/CustomMessageTypes.h" diff --git a/soh/soh/Enhancements/randomizer/randomizer_check_tracker.cpp b/soh/soh/Enhancements/randomizer/randomizer_check_tracker.cpp index ace7781be..36263197a 100644 --- a/soh/soh/Enhancements/randomizer/randomizer_check_tracker.cpp +++ b/soh/soh/Enhancements/randomizer/randomizer_check_tracker.cpp @@ -1092,12 +1092,12 @@ bool ShouldHideArea(RandomizerCheckArea rcArea) { return true; } -bool ShouldShowCheck(RandomizerCheckObject check) { +bool ShouldShowCheck(RandomizerCheck check) { return ( IsVisibleInCheckTracker(check) && (checkSearch.Filters.Size == 0 || checkSearch.PassFilter(RandomizerCheckObjects::GetRCAreaName(Rando::StaticData::GetLocation(check)->GetArea()).c_str()) || - checkSearch.PassFilter(Rando::StaticData::GetLocation(check)->GetShortName().c_str()) + checkSearch.PassFilter(Rando::StaticData::GetLocation(check)->GetShortName().c_str())) ); } @@ -1244,7 +1244,7 @@ void LoadSettings() { fishsanityAgeSplit = OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_FISHSANITY_AGE_SPLIT); } -bool IsCheckShuffled(RandomizerCheckObject rcObj) { +bool IsCheckShuffled(RandomizerCheck rc) { Rando::Location* loc = Rando::StaticData::GetLocation(rc); if (IS_RANDO && OTRGlobals::Instance->gRandomizer->GetRandoSettingValue(RSK_LOGIC_RULES) != RO_LOGIC_VANILLA) { return @@ -1307,8 +1307,10 @@ bool IsCheckShuffled(RandomizerCheckObject rcObj) { return false; } -bool IsVisibleInCheckTracker(RandomizerCheckObject rcObj) { - return IsCheckShuffled(rcObj) || (rcObj.rcType == RCTYPE_SKULL_TOKEN && alwaysShowGS) || (rcObj.rcType == RCTYPE_SHOP && (showShops && (!hideShopRightChecks))); +bool IsVisibleInCheckTracker(RandomizerCheck rc) { + auto loc = Rando::StaticData::GetLocation(rc); + return IsCheckShuffled(rc) || (loc->GetRCType() == RCTYPE_SKULL_TOKEN && alwaysShowGS) || + (loc->GetRCType() == RCTYPE_SHOP && (showShops && (!hideShopRightChecks))); } void UpdateInventoryChecks() { @@ -1501,7 +1503,7 @@ void DrawLocation(RandomizerCheck rc) { //Draw the extra info txt = ""; - bool mystery = CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0) && OTRGlobals::Instance->gRandomizer->merchantPrices.contains(rcObj.rc); + bool mystery = CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0) && itemLoc->IsAddedToPool(); if (checkData.hintItem != 0) { // TODO hints @@ -1534,7 +1536,7 @@ void DrawLocation(RandomizerCheck rc) { } else if (!mystery) { txt = itemLoc->GetPlacedItem().GetName().GetForLanguage(gSaveContext.language); } - if (!IsVisibleInCheckTracker(rcObj) && status == RCSHOW_IDENTIFIED && !mystery) { + if (!IsVisibleInCheckTracker(rc) && status == RCSHOW_IDENTIFIED && !mystery) { txt += fmt::format(" - {}", gSaveContext.checkTrackerData[rc].price); } } else { diff --git a/soh/soh/Enhancements/randomizer/randomizer_check_tracker.h b/soh/soh/Enhancements/randomizer/randomizer_check_tracker.h index 576a09cc7..c8915a8ec 100644 --- a/soh/soh/Enhancements/randomizer/randomizer_check_tracker.h +++ b/soh/soh/Enhancements/randomizer/randomizer_check_tracker.h @@ -47,7 +47,7 @@ void DefaultCheckData(RandomizerCheck rc); void Teardown(); void UpdateAllOrdering(); bool IsVisibleInCheckTracker(RandomizerCheck rc); -bool IsCheckShuffled(RandomizerCheck check); +bool IsCheckShuffled(RandomizerCheck rc); void InitTrackerData(bool isDebug); RandomizerCheckArea GetCheckArea(); void UpdateCheck(uint32_t, RandomizerCheckTrackerData); diff --git a/soh/soh/OTRGlobals.cpp b/soh/soh/OTRGlobals.cpp index bf248d0e0..42ba48e61 100644 --- a/soh/soh/OTRGlobals.cpp +++ b/soh/soh/OTRGlobals.cpp @@ -2445,8 +2445,8 @@ extern "C" ItemObtainability Randomizer_GetItemObtainabilityFromRandomizerCheck( return OTRGlobals::Instance->gRandomizer->GetItemObtainabilityFromRandomizerCheck(randomizerCheck); } -extern "C" bool Randomizer_IsCheckShuffled(RandomizerCheck randomizerCheck) { - return CheckTracker::IsCheckShuffled(RandomizerCheckObjects::GetAllRCObjects().find(randomizerCheck)->second); +extern "C" bool Randomizer_IsCheckShuffled(RandomizerCheck rc) { + return CheckTracker::IsCheckShuffled(rc); } extern "C" GetItemEntry GetItemMystery() { diff --git a/soh/src/code/z_en_item00.c b/soh/src/code/z_en_item00.c index f286830e6..8e30f462a 100644 --- a/soh/src/code/z_en_item00.c +++ b/soh/src/code/z_en_item00.c @@ -1361,23 +1361,7 @@ static const Vtx customDropVtx[] = { * Draw Function used for most collectible types of En_Item00 (ammo, bombs, sticks, nuts, magic...). */ void EnItem00_DrawCollectible(EnItem00* this, PlayState* play) { - if (IS_RANDO && (this->getItemId != GI_NONE || this->actor.params == ITEM00_SMALL_KEY)) { - RandomizerCheck randoCheck = - Randomizer_GetCheckFromActor(this->actor.id, play->sceneNum, this->ogParams); - GetItemEntry giEntry = this->randoGiEntry; - - if (randoCheck != RC_UNKNOWN_CHECK) { - this->randoGiEntry = Randomizer_GetItemFromKnownCheck(randoCheck, GI_NONE); - giEntry = (CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0) && Randomizer_IsCheckShuffled(randoCheck)) - ? GetItemMystery() : this->randoGiEntry; - giEntry.getItemFrom = ITEM_FROM_FREESTANDING; - } - - f32 mtxScale = 16.0f; - Matrix_Scale(mtxScale, mtxScale, mtxScale, MTXMODE_APPLY); - EnItem00_CustomItemsParticles(&this->actor, play, giEntry); - GetItemEntry_Draw(play, giEntry); - } else if (this->actor.params == ITEM00_BOMBCHU) { + if (this->actor.params == ITEM00_BOMBCHU) { OPEN_DISPS(play->state.gfxCtx); Matrix_ReplaceRotation(&play->billboardMtxF); @@ -1457,24 +1441,7 @@ void EnItem00_DrawHeartContainer(EnItem00* this, PlayState* play) { * Draw Function used for the Piece of Heart type of En_Item00. */ void EnItem00_DrawHeartPiece(EnItem00* this, PlayState* play) { - if (IS_RANDO) { - RandomizerCheck randoCheck = - Randomizer_GetCheckFromActor(this->actor.id, play->sceneNum, this->ogParams); - GetItemEntry giEntry = this->randoGiEntry; - - if (randoCheck != RC_UNKNOWN_CHECK) { - this->randoGiEntry = Randomizer_GetItemFromKnownCheck(randoCheck, GI_NONE); - giEntry = (CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0) && Randomizer_IsCheckShuffled(randoCheck)) - ? GetItemMystery() : this->randoGiEntry; - giEntry.getItemFrom = ITEM_FROM_FREESTANDING; - } - - f32 mtxScale = 16.0f; - Matrix_Scale(mtxScale, mtxScale, mtxScale, MTXMODE_APPLY); - EnItem00_CustomItemsParticles(&this->actor, play, giEntry); - GetItemEntry_Draw(play, giEntry); - } else { - s32 pad; + s32 pad; OPEN_DISPS(play->state.gfxCtx); diff --git a/soh/src/overlays/actors/ovl_Demo_Effect/z_demo_effect.c b/soh/src/overlays/actors/ovl_Demo_Effect/z_demo_effect.c index 2e06e8975..5984e7eee 100644 --- a/soh/src/overlays/actors/ovl_Demo_Effect/z_demo_effect.c +++ b/soh/src/overlays/actors/ovl_Demo_Effect/z_demo_effect.c @@ -2089,42 +2089,56 @@ void DemoEffect_DrawGetItem(Actor* thisx, PlayState* play) { } if (IS_RANDO && (play->sceneNum != SCENE_TEMPLE_OF_TIME || this->actor.params == DEMO_EFFECT_LIGHTARROW)) { GetItemEntry getItemEntry = GET_ITEM_NONE; - if (CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0) && Randomizer_IsCheckShuffled(RC_BARINADE)) - getItemEntry = GetItemMystery(); + RandomizerCheck rc = RC_MAX; + RandomizerGet rg = RG_NONE; switch (this->actor.params) { case DEMO_EFFECT_JEWEL_KOKIRI: - getItemEntry = Randomizer_GetItemFromKnownCheck(RC_QUEEN_GOHMA, RG_KOKIRI_EMERALD); + rc = RC_QUEEN_GOHMA; + rg = RG_KOKIRI_EMERALD; break; case DEMO_EFFECT_JEWEL_GORON: - getItemEntry = Randomizer_GetItemFromKnownCheck(RC_KING_DODONGO, RG_GORON_RUBY); + rc = RC_KING_DODONGO; + rg = RG_GORON_RUBY; break; case DEMO_EFFECT_JEWEL_ZORA: - getItemEntry = Randomizer_GetItemFromKnownCheck(RC_BARINADE, RG_ZORA_SAPPHIRE); + rc = RC_BARINADE; + rg = RG_ZORA_SAPPHIRE; break; case DEMO_EFFECT_MEDAL_FOREST: - getItemEntry = Randomizer_GetItemFromKnownCheck(RC_PHANTOM_GANON, RG_FOREST_MEDALLION); + rc = RC_PHANTOM_GANON; + rg = RG_FOREST_MEDALLION; break; case DEMO_EFFECT_MEDAL_FIRE: - getItemEntry = Randomizer_GetItemFromKnownCheck(RC_VOLVAGIA, RG_FIRE_MEDALLION); + rc = RC_VOLVAGIA; + rg = RG_FIRE_MEDALLION; break; case DEMO_EFFECT_MEDAL_WATER: - getItemEntry = Randomizer_GetItemFromKnownCheck(RC_MORPHA, RG_WATER_MEDALLION); + rc = RC_MORPHA; + rg = RG_WATER_MEDALLION; break; case DEMO_EFFECT_MEDAL_SPIRIT: - getItemEntry = Randomizer_GetItemFromKnownCheck(RC_TWINROVA, RG_SPIRIT_MEDALLION); + rc = RC_TWINROVA; + rg = RG_SPIRIT_MEDALLION; break; case DEMO_EFFECT_MEDAL_SHADOW: - getItemEntry = Randomizer_GetItemFromKnownCheck(RC_BONGO_BONGO, RG_SHADOW_MEDALLION); + rc = RC_BONGO_BONGO; + rg = RG_SHADOW_MEDALLION; break; case DEMO_EFFECT_MEDAL_LIGHT: - getItemEntry = Randomizer_GetItemFromKnownCheck(RC_GIFT_FROM_SAGES, RG_LIGHT_MEDALLION); + rc = RC_GIFT_FROM_SAGES; + rg = RG_LIGHT_MEDALLION; break; case DEMO_EFFECT_LIGHTARROW: - getItemEntry = Randomizer_GetItemFromKnownCheck(RC_TOT_LIGHT_ARROWS_CUTSCENE, RG_LIGHT_ARROWS); + rc = RC_TOT_LIGHT_ARROWS_CUTSCENE; + rg = RG_LIGHT_ARROWS; break; } + getItemEntry = Randomizer_GetItemFromKnownCheck(rc, rg); if (getItemEntry.getItemId != GI_NONE) { + if (CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0) && Randomizer_IsCheckShuffled(rc)) { + getItemEntry = GetItemMystery(); + } this->getItem.drawId = getItemEntry.gid; func_8002EBCC(thisx, play, 0); func_8002ED80(thisx, play, 0); diff --git a/soh/src/overlays/actors/ovl_En_Si/z_en_si.c b/soh/src/overlays/actors/ovl_En_Si/z_en_si.c index bf0e4951d..170eed16e 100644 --- a/soh/src/overlays/actors/ovl_En_Si/z_en_si.c +++ b/soh/src/overlays/actors/ovl_En_Si/z_en_si.c @@ -155,50 +155,6 @@ void EnSi_Draw(Actor* thisx, PlayState* play) { if (this->actionFunc != func_80AFB950) { func_8002ED80(&this->actor, play, 0); func_8002EBCC(&this->actor, play, 0); - if (!IS_RANDO) { - GetItem_Draw(play, GID_SKULL_TOKEN_2); - } else { - RandomizerCheck check = Randomizer_GetCheckFromActor(this->actor.id, play->sceneNum, this->actor.params); - getItem = (CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0) && Randomizer_IsCheckShuffled(check)) ? GetItemMystery() : Randomizer_GetItemFromKnownCheck(check, GI_SKULL_TOKEN); - EnItem00_CustomItemsParticles(&this->actor, play, getItem); - if (getItem.itemId != ITEM_SKULL_TOKEN) { - f32 mtxScale = 1.5f; - Matrix_Scale(mtxScale, mtxScale, mtxScale, MTXMODE_APPLY); - } - GetItemEntry_Draw(play, getItem); - } - } -} - -void EnSi_Reset() { - textId = 0xB4; - giveItemId = ITEM_SKULL_TOKEN; -} - -void Randomizer_UpdateSkullReward(EnSi* this, PlayState* play) { - Player* player = GET_PLAYER(play); - - getItem = Randomizer_GetItemFromActor(this->actor.id, play->sceneNum, this->actor.params, GI_SKULL_TOKEN); - getItemId = getItem.getItemId; - if (getItemId == RG_ICE_TRAP) { - textId = 0xF8; - } else { - textId = getItem.textId; - giveItemId = getItem.itemId; - } - player->getItemEntry = getItem; -} - -void Randomizer_GiveSkullReward(EnSi* this, PlayState* play) { - Player* player = GET_PLAYER(play); - - if (getItem.modIndex == MOD_NONE) { - // RANDOTOD: Move this into Item_Give() or some other more central location - if (getItem.getItemId == GI_SWORD_BGS) { - gSaveContext.bgsFlag = true; - } - Item_Give(play, giveItemId); - } else if (getItem.modIndex == MOD_RANDOMIZER) { - Randomizer_Item_Give(play, getItem); + GetItem_Draw(play, GID_SKULL_TOKEN_2); } } diff --git a/soh/src/overlays/actors/ovl_Item_B_Heart/z_item_b_heart.c b/soh/src/overlays/actors/ovl_Item_B_Heart/z_item_b_heart.c index 02656e119..29efb832c 100644 --- a/soh/src/overlays/actors/ovl_Item_B_Heart/z_item_b_heart.c +++ b/soh/src/overlays/actors/ovl_Item_B_Heart/z_item_b_heart.c @@ -93,23 +93,18 @@ void ItemBHeart_Draw(Actor* thisx, PlayState* play) { actorIt = actorIt->next; } - if (IS_RANDO) { - RandomizerCheck check = Randomizer_GetCheckFromActor(this->actor.id, play->sceneNum, this->actor.params); - GetItemEntry_Draw(play, (CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0) && Randomizer_IsCheckShuffled(check)) ? GetItemMystery() : Randomizer_GetItemFromKnownCheck(check, GI_HEART_CONTAINER_2)); + if (flag) { + Gfx_SetupDL_25Xlu(play->state.gfxCtx); + gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), + G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); + gSPDisplayList(POLY_XLU_DISP++, gGiHeartBorderDL); + gSPDisplayList(POLY_XLU_DISP++, gGiHeartContainerDL); } else { - if (flag) { - Gfx_SetupDL_25Xlu(play->state.gfxCtx); - gSPMatrix(POLY_XLU_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), - G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - gSPDisplayList(POLY_XLU_DISP++, gGiHeartBorderDL); - gSPDisplayList(POLY_XLU_DISP++, gGiHeartContainerDL); - } else { - Gfx_SetupDL_25Opa(play->state.gfxCtx); - gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), - G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); - gSPDisplayList(POLY_OPA_DISP++, gGiHeartBorderDL); - gSPDisplayList(POLY_OPA_DISP++, gGiHeartContainerDL); - } + Gfx_SetupDL_25Opa(play->state.gfxCtx); + gSPMatrix(POLY_OPA_DISP++, MATRIX_NEWMTX(play->state.gfxCtx), + G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); + gSPDisplayList(POLY_OPA_DISP++, gGiHeartBorderDL); + gSPDisplayList(POLY_OPA_DISP++, gGiHeartContainerDL); } CLOSE_DISPS(play->state.gfxCtx); diff --git a/soh/src/overlays/actors/ovl_Item_Etcetera/z_item_etcetera.c b/soh/src/overlays/actors/ovl_Item_Etcetera/z_item_etcetera.c index d27893c3a..cc1f31aa0 100644 --- a/soh/src/overlays/actors/ovl_Item_Etcetera/z_item_etcetera.c +++ b/soh/src/overlays/actors/ovl_Item_Etcetera/z_item_etcetera.c @@ -206,16 +206,6 @@ void ItemEtcetera_DrawThroughLens(Actor* thisx, PlayState* play) { if (play->actorCtx.lensActive) { func_8002EBCC(&this->actor, play, 0); func_8002ED80(&this->actor, play, 0); - - if(IS_RANDO && play->sceneNum == SCENE_TREASURE_BOX_SHOP) { - RandomizerCheck check = RC_MAX; - GetItemEntry randoGetItem = GetChestGameRandoGetItem(this->actor.room, this->giDrawId, play); //TODO Rando: add mysterious shuffle when chest minigame keys get shuffled - EnItem00_CustomItemsParticles(&this->actor, play, randoGetItem); - if (randoGetItem.itemId != ITEM_NONE) { - GetItemEntry_Draw(play, randoGetItem); - return; - } - } GetItem_Draw(play, this->giDrawId); } @@ -225,24 +215,6 @@ void ItemEtcetera_Draw(Actor* thisx, PlayState* play) { ItemEtcetera* this = (ItemEtcetera*)thisx; s32 type = this->actor.params & 0xFF; - if (IS_RANDO) { - GetItemEntry randoGetItem = (GetItemEntry)GET_ITEM_NONE; - if (type == ITEM_ETC_ARROW_FIRE) { - randoGetItem = (CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0) && Randomizer_IsCheckShuffled(RC_LH_SUN)) ? GetItemMystery() : Randomizer_GetItemFromKnownCheck(RC_LH_SUN, GI_ARROW_FIRE); - } else if (type == ITEM_ETC_LETTER) { - randoGetItem = (CVarGetInteger(CVAR_RANDOMIZER_ENHANCEMENT("MysteriousShuffle"), 0) && Randomizer_IsCheckShuffled(RC_LH_UNDERWATER_ITEM)) ? GetItemMystery() : Randomizer_GetItemFromKnownCheck(RC_LH_UNDERWATER_ITEM, GI_LETTER_RUTO); - } - - EnItem00_CustomItemsParticles(&this->actor, play, randoGetItem); - - if (randoGetItem.itemId != ITEM_NONE) { - func_8002EBCC(&this->actor, play, 0); - func_8002ED80(&this->actor, play, 0); - GetItemEntry_Draw(play, randoGetItem); - return; - } - } - func_8002EBCC(&this->actor, play, 0); func_8002ED80(&this->actor, play, 0); GetItem_Draw(play, this->giDrawId);