From 69ad906ba13ab67bda3ea1b09f1e3d6bf2bd4fe2 Mon Sep 17 00:00:00 2001 From: Phlex Date: Sun, 7 Jul 2024 10:57:41 -0600 Subject: [PATCH] Fix swamp spider house having an invalid token. --- code/source/rnd/item_override.cpp | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/code/source/rnd/item_override.cpp b/code/source/rnd/item_override.cpp index 6596307..e500eea 100644 --- a/code/source/rnd/item_override.cpp +++ b/code/source/rnd/item_override.cpp @@ -679,13 +679,12 @@ namespace rnd { s16 incomingGetItemId) { ItemOverride override = {0}; s32 incomingNegative = incomingGetItemId < 0; - // #if defined ENABLE_DEBUG || DEBUG_PRINT - // util::Print("%s: Our actor ID is %#06x\nScene is %#04x\nIncoming item id is %#04x\n", __func__, - // fromActor->id, - // gctx->scene, incomingGetItemId); - // #endif if (fromActor != NULL && incomingGetItemId != 0) { s16 getItemId = ItemOverride_CheckNpc(fromActor->id, incomingGetItemId, incomingNegative); +// #if defined ENABLE_DEBUG || DEBUG_PRINT +// util::Print("%s: Our actor ID is %#06x\nScene is %#04x\nIncoming item id is %#04x\ngetItemId %#04x\nParams %#04x\n", __func__, fromActor->id, +// gctx->scene, incomingGetItemId, getItemId, fromActor->params); +// #endif storedActorId = fromActor->id; storedGetItemId = incomingNegative ? (GetItemID)-incomingGetItemId : (GetItemID)incomingGetItemId; override = ItemOverride_Lookup(fromActor, (u16)gctx->scene, getItemId); @@ -1046,7 +1045,7 @@ namespace rnd { } u8 ItemOverride_OverrideSkullToken(game::GlobalContext* gctx, game::act::Actor* actor) { - s16 getItemId = gctx->scene == game::SceneId::SwampSpiderHouse ? 0x52 : 0x6D; + s16 getItemId = gctx->scene == game::SceneId::SwampSpiderHouse ? 0x44 : 0x6D; ItemOverride_GetItem(gctx, actor, gctx->GetPlayerActor(), getItemId); if (rActiveItemRow != NULL) { ItemOverride_GetItemTextAndItemID(gctx->GetPlayerActor());