Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: Silver Rupee Shuffle #4028

Draft
wants to merge 44 commits into
base: develop-rando
Choose a base branch
from

Conversation

leggettc18
Copy link
Contributor

@leggettc18 leggettc18 commented Mar 30, 2024

Wanted to get a Draft PR up for this so it could get some more field testing.

What's in so far:

  • All Silver Rupees are able to be replaced with other items.
  • All Silver Rupees can appear in place of other items in the game.
  • The GetItem text will tell you how many Silver Rupees of that puzzle you have collected.
  • Collecting all Silver Rupees of a given puzzle will cause the puzzle to be immediately solved when you enter the room.
  • Silver Rupees can be shuffled to Same Dungeon, Any Dungeon, Overworld, or Anywhere (same as Keys).
  • There is an optional "Magical Silver Rupee" which will automatically solve all Silver Rupee Puzzles.

Left to be done:

  • Clean up/autoformat text (some of the names are long)
  • Add options for freezing when picking up Silver Rupee checks (a-la GS Tokens)
  • Logic (would prefer to wait for Malk's Logic class rework to prevent merge conflicts)
  • Silver Rupee Pouches (Same concept as key rings. May or may not wait for a second iteration for these, as the options menu for this would be hell to implement currently)

Build Artifacts

Remaining locations yet to be added, but the ones that were added are working.
1. Fixed Ganon Non-hint text from loading as Saria's Magic Hint.
2. Fixed Ganon Non-hint text from not getting saved correctly.
3. Fixed gossip stone hint generation from not generating any non-always hints on No Logic.

For #3, the hint distribution and placement algorithm was bailing out too early when it wasn't able
to place a hint. For No Logic, what it was doing was failing to place WOTH hints (since No Logic seeds
don't calculate WOTH candidacy), returning the amount of hints it failed to place, and then it called
the function to redistribute the hints, but did not call the function to attempt to place the remaining hints.

Additionally, it was not accounting for the fact that we shouldn't redistribute the hints into the categories we failed to
place a hint in, so it would redistribute hints right back into those categories. I changed it so that when DistributeHints
gets called after PlaceHints fails to place the hint, it checks if the distribution settings copies attribute was set to 0.
In this case, it breaks while looping for the type distribution settings, and moves on to the next category. Also, it now repeatedly
attempts to distribute and place hints until PlaceHints returns 0 (meaning it placed all of its hints successfully).
Comment on lines 69 to 71
/* */ RandomizerGet rg;
/* */ GetItemEntry* giEntry;
/* */ RandomizerInf randInfFlag;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you not derive these 3 from just storing the RC?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, the randomizer get is for the Silver Trackers, not Silver Rupees. That rando get is for identifying which room it's for. It's get a little messy since the rupees and the tracker share an actor type.

The other two I store after deducing them once because if I don't store them somewhere I have to deduce again every frame for the drawing and update functions to work properly.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You would know better than me actually, is there a good place to store them with the hook setup without extending the vanilla struct like this?

@leggettc18 leggettc18 added the rando v3 Issues specifically targeting develop-rando label Jul 30, 2024
@boomshroom
Copy link

Been testing this and ran into trouble with the GTG boulder room. It's probably not a coincidence that it's the first room to give me trouble when it's also the only one to have special cased behavior. The weird part is that simulating the non-special behavior with the flags editor somehow fixed it. (As in opening the door; it didn't cancel the timer.)

P.S. The changes to CustomMessageManager.h seem to have broken hint formatting.

Aside from those two issues (and the lack of logic and item tracker support), this patch works very well!

@boomshroom
Copy link

Potentially a more significant issue than the lack of logic: even if silver rupees are set to vanilla, they can still have items placed in their locations, and potentially required items that the seed can't be beaten without. They still spawn as vanilla in their respective dungeons, so while their room can be completed, those important items can become unobtainable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rando v3 Issues specifically targeting develop-rando
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants