summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoraMannus <mannusmenting@gmail.com>2023-03-28 15:00:11 +0200
committeraMannus <mannusmenting@gmail.com>2023-03-28 15:00:11 +0200
commit8fc9fc18ece793b98ad555338ef45864e2a0bcb6 (patch)
tree12e278f606561bc26448f9280ed1180829bc3ed4
parentf2a975872ef0406af3c75e95179a7f43fd661ac3 (diff)
Rig treasure chest minigame
-rw-r--r--soh/src/overlays/actors/ovl_En_Changer/z_en_changer.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/soh/src/overlays/actors/ovl_En_Changer/z_en_changer.c b/soh/src/overlays/actors/ovl_En_Changer/z_en_changer.c
index 76bd9ef0f..1f7282a53 100644
--- a/soh/src/overlays/actors/ovl_En_Changer/z_en_changer.c
+++ b/soh/src/overlays/actors/ovl_En_Changer/z_en_changer.c
@@ -136,7 +136,11 @@ void EnChanger_Init(Actor* thisx, PlayState* play2) {
this->rightChestGetItemId = GI_DOOR_KEY;
rightChestItem = ITEM_ETC_KEY_SMALL_CHEST_GAME;
- if (Rand_ZeroFloat(1.99f) < 1.0f) {
+ uint8_t roomNum = play->roomCtx.curRoom.num;
+ uint8_t leftSideKey = roomNum == 1 || roomNum == 2 || roomNum == 5;
+ // Solution: LLRRL
+
+ if (leftSideKey) {
rightChestParams = (sLoserGetItemIds[play->roomCtx.curRoom.num] << 5) | 0x4000;
this->rightChestNum = new_var;
this->rightChestGetItemId = sLoserGetItemIds[play->roomCtx.curRoom.num];