Fixes ice traps again.

This commit is contained in:
Christopher Leggett 2022-08-19 21:42:59 -04:00
parent cec1c7dc07
commit 2c410a5857
No known key found for this signature in database
GPG Key ID: 7093AE5FF7037D79
2 changed files with 3 additions and 3 deletions

View File

@ -1608,7 +1608,7 @@ extern "C" CustomMessageEntry Randomizer_GetHintFromCheck(RandomizerCheck check)
}
extern "C" GetItemEntry ItemTable_Retrieve(int16_t getItemID) {
GetItemEntry giEntry = ItemTableManager::Instance->RetrieveItemEntry(OTRGlobals::Instance->getItemModIndex, getItemID);
GetItemEntry giEntry = ItemTableManager::Instance->RetrieveItemEntry(MOD_NONE, getItemID);
return giEntry;
}

View File

@ -4528,7 +4528,7 @@ void func_8083A434(GlobalContext* globalCtx, Player* this) {
if (this->getItemId == GI_HEART_CONTAINER_2) {
this->unk_850 = 20;
}
else if (this->getItemId >= 0 || this->getItemEntry.getItemId >= 0) {
else if (this->getItemId >= 0 || (this->getItemEntry.objectId != OBJECT_INVALID && this->getItemEntry.getItemId >= 0)) {
this->unk_850 = 1;
}
else {
@ -6165,7 +6165,7 @@ s32 func_8083E5A8(Player* this, GlobalContext* globalCtx) {
}
} else if (CHECK_BTN_ALL(sControlInput->press.button, BTN_A) && !(this->stateFlags1 & PLAYER_STATE1_11) &&
!(this->stateFlags2 & PLAYER_STATE2_10)) {
if (this->getItemId != GI_NONE && this->getItemEntry.objectId != OBJECT_INVALID) {
if (this->getItemId != GI_NONE || this->getItemEntry.objectId != OBJECT_INVALID) {
GetItemEntry giEntry;
if (this->getItemEntry.objectId == OBJECT_INVALID) {
giEntry = ItemTable_Retrieve(-this->getItemId);