From 14a6bc1f85c2bec1a8aaff6afb7a6dcc01838dbf Mon Sep 17 00:00:00 2001 From: aMannus Date: Sat, 10 Jan 2026 13:59:32 +0100 Subject: Add Roc's Feather (custom item) to Rando Item Pool (#6035) This adds Roc's as a fully implemented item into the randomizer pool. When both Roc's and Nayru's is found, you can swap between them on the pause menu Many people have contributed to this over time, so huge shoutout to: - kentonm, this item is directly inspired by their Roc's Feather from their romhack Indigo. Also provided me with their GI model, icon texture and animation to use. - PurpleHato, for providing the images for the item name shown on the kaleidoscope. - Dana The Elf, providing another custom animation for the item. - Reppan, for helping to tweak the animation and exporting the GI model for me. --- soh/src/code/z_inventory.c | 30 ++++++++++++++++++++++++++++++ soh/src/code/z_parameter.c | 6 ++++++ soh/src/code/z_play.c | 4 ++++ 3 files changed, 40 insertions(+) (limited to 'soh/src/code') diff --git a/soh/src/code/z_inventory.c b/soh/src/code/z_inventory.c index 4141ffe1f..5f317672d 100644 --- a/soh/src/code/z_inventory.c +++ b/soh/src/code/z_inventory.c @@ -3,6 +3,7 @@ #include "textures/icon_item_static/icon_item_static.h" #include "textures/icon_item_24_static/icon_item_24_static.h" #include "textures/parameter_static/parameter_static.h" +#include // Bit Flag array in which gBitFlags[n] is literally (1 << n) u32 gBitFlags[] = { @@ -168,6 +169,35 @@ void* gItemIcons[] = { gOcarinaBtnIconCLeftTex, gOcarinaBtnIconCRightTex, gOcarinaBtnIconATex, + // Push down array to reach newly added item IDs + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + "", + // Start custom items + gRocsFeatherTex, }; // Used to map item IDs to inventory slots diff --git a/soh/src/code/z_parameter.c b/soh/src/code/z_parameter.c index a9dfdd01f..86a72456f 100644 --- a/soh/src/code/z_parameter.c +++ b/soh/src/code/z_parameter.c @@ -2463,6 +2463,12 @@ u8 Item_Give(PlayState* play, u8 item) { } } + return Return_Item(item, MOD_NONE, ITEM_NONE); + } else if (item == ITEM_NAYRUS_LOVE && Randomizer_GetSettingValue(RSK_ROCS_FEATHER)) { + Flags_SetRandomizerInf(RAND_INF_OBTAINED_NAYRUS_LOVE); + if (INV_CONTENT(ITEM_NAYRUS_LOVE) == ITEM_NONE) { + INV_CONTENT(ITEM_NAYRUS_LOVE) = ITEM_NAYRUS_LOVE; + } return Return_Item(item, MOD_NONE, ITEM_NONE); } returnItem = gSaveContext.inventory.items[slot]; diff --git a/soh/src/code/z_play.c b/soh/src/code/z_play.c index 4890fa2a4..aa51915c1 100644 --- a/soh/src/code/z_play.c +++ b/soh/src/code/z_play.c @@ -594,6 +594,10 @@ void Play_Init(GameState* thisx) { gSlotAgeReqs[SLOT_TRADE_CHILD] = AGE_REQ_CHILD; } + // Handle Rocs Feather requiement + gItemAgeReqs[ITEM_ROCS_FEATHER] = AGE_REQ_NONE; + gSlotAgeReqs[SLOT_NAYRUS_LOVE] = AGE_REQ_NONE; + func_800304DC(play, &play->actorCtx, play->linkActorEntry); while (!func_800973FC(play, &play->roomCtx)) { -- cgit v1.2.3