From 89970f2ceef1b54ebd1d5420109e9cbb46234721 Mon Sep 17 00:00:00 2001 From: Tacoman369 <90735287+Tacoman369@users.noreply.github.com> Date: Wed, 23 Jul 2025 00:17:10 -0500 Subject: [PATCH 1/5] HintsOnDoor - Adds hint text for Ocarina of Time - Adds functions to create custom message placed on the Clock Tower door that has hints for the boss remains (and ocarina if shuffled) --- source/hint_list.cpp | 8 ++++++- source/hints.cpp | 45 +++++++++++++++++++++++++++++++++++++--- source/include/hints.hpp | 1 + source/playthrough.cpp | 1 + 4 files changed, 51 insertions(+), 4 deletions(-) diff --git a/source/hint_list.cpp b/source/hint_list.cpp index 18e96bc..2414893 100644 --- a/source/hint_list.cpp +++ b/source/hint_list.cpp @@ -215,7 +215,13 @@ void HintTable_Init() { //clear Text{"Double Defense", "**FRENCH**", "**SPANISH**"} ); - // OCARINA_OF_TIME, + hintTable[OCARINA_OF_TIME] = HintText::Item({ + //obscure + Text{"a musical instrument", "**FRENCH**", "**SPANISH**"} + }, + //clear + Text{"the Ocarina of Time", "**FRENCH**", "**SPANISH**"} + ); hintTable[PICTOGRAPH_BOX] = HintText::Item({ //obscure Text{"a capture device", "**FRENCH**", "**SPANISH**"} diff --git a/source/hints.cpp b/source/hints.cpp index 03b98c6..a2e7683 100644 --- a/source/hints.cpp +++ b/source/hints.cpp @@ -484,13 +484,52 @@ void CreateTingleHintText() { } } //Find the location which has the given itemKey and create the generic altar text for the reward -/* -static Text BuildDungeonRewardText(ItemID itemID, const ItemKey itemKey) { + +/*static Text BuildDungeonRewardText(ItemID itemID, const ItemKey itemKey) { LocationKey location = FilterFromPool(allLocations, [itemKey](const LocationKey loc){return Location(loc)->GetPlacedItemKey() == itemKey;})[0]; //Calling ITEM_OBTAINED draws the passed in itemID to the left side of the textbox return Text()+ITEM_OBTAINED(itemID)+"#"+GetHintRegion(Location(location)->GetParentRegionKey())->GetHint().GetText()+"#...^"; +}*/ + +static std::string BuildDoorText(const ItemKey itemKey) { + LocationKey location = FilterFromPool(allLocations, [itemKey](const LocationKey loc){return Location(loc)->GetPlacedItemKey() == itemKey;})[0]; + return "#"+GetHintRegion(Location(location)->GetParentRegionKey())->GetHint().GetText().GetEnglish()+"#...^"; } -*/ + +void CreateClockTowerDoorHints() { + // Create Ocarina Hint + // LocationKey ocalocation = FilterFromPool(allLocations, [](const LocationKey loc){return Location(loc)->GetPlacedItemKey() == OCARINA_OF_TIME;})[0]; + std::string ocarinaText = ItemTable(OCARINA_OF_TIME).GetHint().GetText().GetEnglish(); // Location(ocalocation)->GetPlacedItem().GetHint().GetText().GetEnglish(); + std::string ocarinaHint = Hint(PREFIX).GetText().GetEnglish()+"#"+ocarinaText+"# "+Hint(CAN_BE_FOUND_AT).GetText().GetEnglish()+" "+BuildDoorText(OCARINA_OF_TIME); + // Create Odolwa Hint Hint(PREFIX).GetText()+"#"+itemText+"# "+Hint(CAN_BE_FOUND_AT).GetText()+" #"+locationText+"#."; + std::string odolwaText = ItemTable(ODOLWAS_REMAINS).GetHint().GetText().GetEnglish(); + std::string odolwaHint = Hint(PREFIX).GetText().GetEnglish()+"#"+odolwaText+"# "+Hint(CAN_BE_FOUND_AT).GetText().GetEnglish()+" "+BuildDoorText(ODOLWAS_REMAINS); + // Create Goht Hint + std::string gohtText = ItemTable(GOHTS_REMAINS).GetHint().GetText().GetEnglish(); + std::string gohtHint = Hint(PREFIX).GetText().GetEnglish()+"#"+gohtText+"# "+Hint(CAN_BE_FOUND_AT).GetText().GetEnglish()+" "+BuildDoorText(GOHTS_REMAINS); + // Create Gyorg Hint + std::string gyorgText = ItemTable(GYORGS_REMAINS).GetHint().GetText().GetEnglish(); + std::string gyorgHint = Hint(PREFIX).GetText().GetEnglish()+"#"+gyorgText+"# "+Hint(CAN_BE_FOUND_AT).GetText().GetEnglish()+" "+BuildDoorText(GYORGS_REMAINS); + // Create Twinmold Hint + std::string twinmoldText = ItemTable(TWINMOLDS_REMAINS).GetHint().GetText().GetEnglish(); + std::string twinmoldHint = Hint(PREFIX).GetText().GetEnglish()+"#"+twinmoldText+"# "+Hint(CAN_BE_FOUND_AT).GetText().GetEnglish()+" "+BuildDoorText(TWINMOLDS_REMAINS); + + // Combine them all for the final text + // If starting without ocarina final hint should include its location + if(StartingOcarina.Value() == 0) { + std::string finalHint = ocarinaHint + odolwaHint + gohtHint + gyorgHint + twinmoldHint; + CustomMessages::CreateMessage(0x0630, 0xFFFF, 0x3fffffff, 0xFF0211, + finalHint.c_str(), + {QM_BLUE, QM_RED, QM_GREEN, QM_RED, QM_MAGENTA, QM_RED, QM_CYAN, QM_RED, QM_YELLOW, QM_RED}, {}, {}, 0x0, false, false); + } + else { + std::string finalHint = odolwaHint + gohtHint + gyorgHint + twinmoldHint; + CustomMessages::CreateMessage(0x0630, 0xFFFF, 0x3fffffff, 0xFF0211, + finalHint.c_str(), + {QM_GREEN, QM_RED, QM_MAGENTA, QM_RED, QM_CYAN, QM_RED, QM_YELLOW, QM_RED}, {}, {}, 0x0, false, false); + } +} + //insert the required number into the hint and set the singular/plural form /* static Text BuildCountReq(const HintKey req, const Option& count) { diff --git a/source/include/hints.hpp b/source/include/hints.hpp index fe2a0cf..594ace6 100644 --- a/source/include/hints.hpp +++ b/source/include/hints.hpp @@ -166,3 +166,4 @@ class HintText { extern void CreateAllHints(); extern void CreateTingleHintText(); +extern void CreateClockTowerDoorHints(); \ No newline at end of file diff --git a/source/playthrough.cpp b/source/playthrough.cpp index 2db9c7e..c3d3b42 100644 --- a/source/playthrough.cpp +++ b/source/playthrough.cpp @@ -78,6 +78,7 @@ namespace Playthrough { PlacementLog_Clear(); } CreateTingleHintText(); + CreateClockTowerDoorHints(); playthroughLocations.clear(); wothLocations.clear(); From 3fcc856656ae99467cd1f6097d70b19057e6b591 Mon Sep 17 00:00:00 2001 From: Nessy Date: Sat, 26 Jul 2025 15:50:59 +0100 Subject: [PATCH 2/5] Clock Tower Door Hints (#132) - Added item icons - Fixed message formatting incorrectly - Adjusted hints to be more lore appropriate --- source/hints.cpp | 55 ++++++++++++++++++++---------------------------- 1 file changed, 23 insertions(+), 32 deletions(-) diff --git a/source/hints.cpp b/source/hints.cpp index a2e7683..dfdfc91 100644 --- a/source/hints.cpp +++ b/source/hints.cpp @@ -493,41 +493,32 @@ void CreateTingleHintText() { static std::string BuildDoorText(const ItemKey itemKey) { LocationKey location = FilterFromPool(allLocations, [itemKey](const LocationKey loc){return Location(loc)->GetPlacedItemKey() == itemKey;})[0]; - return "#"+GetHintRegion(Location(location)->GetParentRegionKey())->GetHint().GetText().GetEnglish()+"#...^"; + return "#"+GetHintRegion(Location(location)->GetParentRegionKey())->GetHint().GetText().GetEnglish()+"#."; } void CreateClockTowerDoorHints() { - // Create Ocarina Hint - // LocationKey ocalocation = FilterFromPool(allLocations, [](const LocationKey loc){return Location(loc)->GetPlacedItemKey() == OCARINA_OF_TIME;})[0]; - std::string ocarinaText = ItemTable(OCARINA_OF_TIME).GetHint().GetText().GetEnglish(); // Location(ocalocation)->GetPlacedItem().GetHint().GetText().GetEnglish(); - std::string ocarinaHint = Hint(PREFIX).GetText().GetEnglish()+"#"+ocarinaText+"# "+Hint(CAN_BE_FOUND_AT).GetText().GetEnglish()+" "+BuildDoorText(OCARINA_OF_TIME); - // Create Odolwa Hint Hint(PREFIX).GetText()+"#"+itemText+"# "+Hint(CAN_BE_FOUND_AT).GetText()+" #"+locationText+"#."; - std::string odolwaText = ItemTable(ODOLWAS_REMAINS).GetHint().GetText().GetEnglish(); - std::string odolwaHint = Hint(PREFIX).GetText().GetEnglish()+"#"+odolwaText+"# "+Hint(CAN_BE_FOUND_AT).GetText().GetEnglish()+" "+BuildDoorText(ODOLWAS_REMAINS); - // Create Goht Hint - std::string gohtText = ItemTable(GOHTS_REMAINS).GetHint().GetText().GetEnglish(); - std::string gohtHint = Hint(PREFIX).GetText().GetEnglish()+"#"+gohtText+"# "+Hint(CAN_BE_FOUND_AT).GetText().GetEnglish()+" "+BuildDoorText(GOHTS_REMAINS); - // Create Gyorg Hint - std::string gyorgText = ItemTable(GYORGS_REMAINS).GetHint().GetText().GetEnglish(); - std::string gyorgHint = Hint(PREFIX).GetText().GetEnglish()+"#"+gyorgText+"# "+Hint(CAN_BE_FOUND_AT).GetText().GetEnglish()+" "+BuildDoorText(GYORGS_REMAINS); - // Create Twinmold Hint - std::string twinmoldText = ItemTable(TWINMOLDS_REMAINS).GetHint().GetText().GetEnglish(); - std::string twinmoldHint = Hint(PREFIX).GetText().GetEnglish()+"#"+twinmoldText+"# "+Hint(CAN_BE_FOUND_AT).GetText().GetEnglish()+" "+BuildDoorText(TWINMOLDS_REMAINS); - - // Combine them all for the final text - // If starting without ocarina final hint should include its location - if(StartingOcarina.Value() == 0) { - std::string finalHint = ocarinaHint + odolwaHint + gohtHint + gyorgHint + twinmoldHint; - CustomMessages::CreateMessage(0x0630, 0xFFFF, 0x3fffffff, 0xFF0211, - finalHint.c_str(), - {QM_BLUE, QM_RED, QM_GREEN, QM_RED, QM_MAGENTA, QM_RED, QM_CYAN, QM_RED, QM_YELLOW, QM_RED}, {}, {}, 0x0, false, false); - } - else { - std::string finalHint = odolwaHint + gohtHint + gyorgHint + twinmoldHint; - CustomMessages::CreateMessage(0x0630, 0xFFFF, 0x3fffffff, 0xFF0211, - finalHint.c_str(), - {QM_GREEN, QM_RED, QM_MAGENTA, QM_RED, QM_CYAN, QM_RED, QM_YELLOW, QM_RED}, {}, {}, 0x0, false, false); - } + // Create hint text + std::string ocarinaHint = "Hey, didn't you have some sort of #musical instrument#?&If I know skullkid, I bet he hid it at "+BuildDoorText(OCARINA_OF_TIME); + std::string odolwaHint = "There's one with a #crown# and #jewellery# said to be found at "+BuildDoorText(ODOLWAS_REMAINS); + std::string gohtHint = "Another #extremely sturdy# one with #huge horns# at "+BuildDoorText(GOHTS_REMAINS); + std::string gyorgHint = "One with #giant fins# and #razor sharp teeth# at "+BuildDoorText(GYORGS_REMAINS); + std::string twinmoldHint = "And one with #three eyes# and #enormous mandibles# at "+BuildDoorText(TWINMOLDS_REMAINS); + + CustomMessages::CreateMessage(0x0630, (StartingOcarina.Value() == 0) ? 0x8000 : 0x8002, 0x3FFFFFFF, 0x0FF0211, + "Rooftop access strictly prohibited!&(Enforceable until #midnight# on the&#eve# of the carnival.)^" + "#Notice of carnival activities:#&Musical Performance Contest&Unique Mask Contest&#Prizes available!#", + {QM_RED, QM_RED, QM_RED, QM_MAGENTA}, {}, {}, 0x0, false, false); + CustomMessages::CreateMessage(0x8000, 0x8001, 0x3FFFFFFF, 0x1000000, ocarinaHint.c_str(), {QM_BLUE, QM_RED}, {}, {}, 0x037C, false, false); + CustomMessages::CreateMessage(0x8001, 0x8003, 0x3FFFFFFF, 0x1FF0000, + "Also, that #mask competition# sounds interesting! I've heard rumours of some pretty #rare masks# around here, truly one of a kind stuff!", + {QM_RED, QM_RED}, {}, {}, 0x0, false, false); + CustomMessages::CreateMessage(0x8002, 0x8003, 0x3FFFFFFF, 0x1FF0000, + "Hey, that #mask competition# sounds interesting! I've heard rumours of some pretty #rare masks# around here, truly one of a kind stuff!", + {QM_RED, QM_RED}, {}, {}, 0x037C, false, false); + CustomMessages::CreateMessage(0x8003, 0x8004, 0x3FFFFFFF, 0x15D0000, odolwaHint.c_str(), {QM_GREEN, QM_GREEN, QM_RED}, {}, {}, 0x0, false, false); + CustomMessages::CreateMessage(0x8004, 0x8005, 0x3FFFFFFF, 0x15E0000, gohtHint.c_str(), {QM_MAGENTA, QM_MAGENTA, QM_RED}, {}, {}, 0x0, false, false); + CustomMessages::CreateMessage(0x8005, 0x8006, 0x3FFFFFFF, 0x15F0000, gyorgHint.c_str(), {QM_CYAN, QM_CYAN, QM_RED}, {}, {}, 0x0, false, false); + CustomMessages::CreateMessage(0x8006, 0xFFFF, 0x3FFFFFFF, 0x0600000, twinmoldHint.c_str(), {QM_YELLOW, QM_YELLOW, QM_RED}, {}, {}, 0x0, false, false); } //insert the required number into the hint and set the singular/plural form From 7852d4d49ce922c26bd9eef3cb153985b9662204 Mon Sep 17 00:00:00 2001 From: Nessy Date: Mon, 28 Jul 2025 19:47:33 +0100 Subject: [PATCH 3/5] Minor hint improvements (#135) - Fixed ocarina hint to say "the Skull Kid" instead of "skullkid" - Fixed inconsequential bug in hint region propagation algorithm --- source/hints.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/hints.cpp b/source/hints.cpp index dfdfc91..c57af30 100644 --- a/source/hints.cpp +++ b/source/hints.cpp @@ -123,9 +123,9 @@ static Area* GetHintRegion(const AreaKey area) { } //add unchecked exits to spot queue - bool checked = false; - for (auto& exit : AreaTable(region)->exits) { + bool checked = false; + for (AreaKey checkedExit : alreadyChecked) { if (exit.GetAreaKey() == checkedExit) { checked = true; @@ -498,7 +498,7 @@ static std::string BuildDoorText(const ItemKey itemKey) { void CreateClockTowerDoorHints() { // Create hint text - std::string ocarinaHint = "Hey, didn't you have some sort of #musical instrument#?&If I know skullkid, I bet he hid it at "+BuildDoorText(OCARINA_OF_TIME); + std::string ocarinaHint = "Hey, didn't you have some sort of #musical instrument#?&If I know the Skull Kid, I bet he hid it at "+BuildDoorText(OCARINA_OF_TIME); std::string odolwaHint = "There's one with a #crown# and #jewellery# said to be found at "+BuildDoorText(ODOLWAS_REMAINS); std::string gohtHint = "Another #extremely sturdy# one with #huge horns# at "+BuildDoorText(GOHTS_REMAINS); std::string gyorgHint = "One with #giant fins# and #razor sharp teeth# at "+BuildDoorText(GYORGS_REMAINS); From 06c008079143cb6e055e684d50f33a57c0b36e68 Mon Sep 17 00:00:00 2001 From: Tacoman369 <90735287+Tacoman369@users.noreply.github.com> Date: Fri, 1 Aug 2025 18:10:30 -0500 Subject: [PATCH 4/5] Hint Fixes - Adds Links Pocket as a dummy location used for clock door boss remains hint text - Adds missing exit to TERMINA_FIELD_GRASS_GROTTO so it links to its parent region properly --- source/hint_list.cpp | 1 + source/hints.cpp | 5 ++++- source/location_access.cpp | 6 ++++++ 3 files changed, 11 insertions(+), 1 deletion(-) diff --git a/source/hint_list.cpp b/source/hint_list.cpp index 2414893..bd179e7 100644 --- a/source/hint_list.cpp +++ b/source/hint_list.cpp @@ -2018,6 +2018,7 @@ void HintTable_Init() { /*---------------------- | REGTION HINT TEXT | ----------------------*/ + hintTable[LINKS_POCKET] = HintText::Region({ Text{"Your Pocket", "**FRENCH**", "**SPANISH**"}}); hintTable[N_CLOCK_TOWN] = HintText::Region({ Text{"N Clock Town", "**FRENCH**", "**SPANISH**"}}); hintTable[CLOCK_TOWN_FAIRY_FOUNTAIN] = HintText::Region({Text{"Clock Town Fairy Fountain", "**FRENCH**", "**SPANISH**"}}); hintTable[CLOCK_TOWN_DEKU_PLAYGROUND] = HintText::Region({Text{"Deku Playground", "**FRENCH**", "**SPANISH**"}}); diff --git a/source/hints.cpp b/source/hints.cpp index c57af30..c9fb925 100644 --- a/source/hints.cpp +++ b/source/hints.cpp @@ -493,6 +493,9 @@ void CreateTingleHintText() { static std::string BuildDoorText(const ItemKey itemKey) { LocationKey location = FilterFromPool(allLocations, [itemKey](const LocationKey loc){return Location(loc)->GetPlacedItemKey() == itemKey;})[0]; + if (Location(location)->GetParentRegionKey() == NONE) { + Location(location)->SetParentRegion(LINKS_POCKET); + } return "#"+GetHintRegion(Location(location)->GetParentRegionKey())->GetHint().GetText().GetEnglish()+"#."; } @@ -629,4 +632,4 @@ void CreateAllHints() { GetAccessibleLocations({}); -} +} \ No newline at end of file diff --git a/source/location_access.cpp b/source/location_access.cpp index 34e853e..e866fa4 100644 --- a/source/location_access.cpp +++ b/source/location_access.cpp @@ -212,6 +212,11 @@ void AreaTable_Init() { Entrance(S_CLOCK_TOWN, {[]{return true;}}), }); + areaTable[LINKS_POCKET] = Area("Links Pocket", "Links Pocket", LINKS_POCKET, {}, {}, { + //Exits + Entrance(S_CLOCK_TOWN, {[]{return true;}}), + }); + /*-------------------------- | OVERWORLD | ---------------------------*/ @@ -750,6 +755,7 @@ void AreaTable_Init() { }, { //Exits + Entrance(TERMINA_FIELD, {[]{return true;}}), }); areaTable[TERMINA_FIELD_BUSINESS_SCRUB_GROTTO] = Area("Termina Field Business Scrub Grotto","Termina Field Business Scrub Grotto", NONE, { //Events From 81dd075281f21bacec874262d816b45d86e5ec7f Mon Sep 17 00:00:00 2001 From: Tacoman369 <90735287+Tacoman369@users.noreply.github.com> Date: Fri, 1 Aug 2025 19:09:13 -0500 Subject: [PATCH 5/5] Update hints.cpp Adjust hint text for remains if its in your inventory to make sense --- source/hints.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/source/hints.cpp b/source/hints.cpp index c9fb925..ed01f21 100644 --- a/source/hints.cpp +++ b/source/hints.cpp @@ -506,6 +506,18 @@ void CreateClockTowerDoorHints() { std::string gohtHint = "Another #extremely sturdy# one with #huge horns# at "+BuildDoorText(GOHTS_REMAINS); std::string gyorgHint = "One with #giant fins# and #razor sharp teeth# at "+BuildDoorText(GYORGS_REMAINS); std::string twinmoldHint = "And one with #three eyes# and #enormous mandibles# at "+BuildDoorText(TWINMOLDS_REMAINS); + if (StartingOdolwaRemains.Value() == 1) { + odolwaHint = "There's one with a #crown# and #jewellery# said to be found in "+BuildDoorText(ODOLWAS_REMAINS); + } + if (StartingGohtRemains.Value() == 1) { + gohtHint = "Another #extremely sturdy# one with #huge horns# in "+BuildDoorText(GOHTS_REMAINS); + } + if (StartingGyorgRemains.Value() == 1) { + gyorgHint = "One with #giant fins# and #razor sharp teeth# in "+BuildDoorText(GYORGS_REMAINS); + } + if (StartingTwinmoldRemains.Value() == 1){ + twinmoldHint = "And one with #three eyes# and #enormous mandibles# in "+BuildDoorText(TWINMOLDS_REMAINS); + } CustomMessages::CreateMessage(0x0630, (StartingOcarina.Value() == 0) ? 0x8000 : 0x8002, 0x3FFFFFFF, 0x0FF0211, "Rooftop access strictly prohibited!&(Enforceable until #midnight# on the&#eve# of the carnival.)^"