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

Accessible Randomizer Checks #5091

Draft
wants to merge 15 commits into
base: develop
Choose a base branch
from

Conversation

xxAtrain223
Copy link

@xxAtrain223 xxAtrain223 commented Feb 21, 2025

Adds a feature to the Randomizer Check Tracker to show the checks that are currently accessible given the player's equipment and activities. It uses the randomizer's logic, so it'll usually be updated automatically as the logic evolves.

I'm still playtesting this and finding issues. Here's the known issues.

  • Zelda's Letter
  • Small Keys
  • Beans

This is needed when calculating Accessible checks while playing and using small keys. Otherwise checks will appear unaccessible because Keys have been used.
//set age access as this areas ages
logic->IsChild = Child();
logic->IsAdult = Adult();
if (logic->mSaveContext != nullptr) {
Copy link
Contributor

Choose a reason for hiding this comment

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

First thing here, mSaveContext is never nullptr. The generator runs on a local instance rather than being tied to gSaveContext like happens while playing a save file.

if (areaTable[RR_ROOT].regionName.empty()) {
RegionTable_Init();
}
if (Rando::Context::GetInstance() == nullptr) {
Copy link
Contributor

Choose a reason for hiding this comment

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

I'm not sure whether RegionTable_Init actually still needs to be called, but Context instancing is handled in SaveManager load functions.

Copy link
Author

Choose a reason for hiding this comment

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

It looks like I can get rid of the Context instancing here. I added it while I was chucking spaghetti at the wall in another function. But the areaTable is full of empty records at this point. Is there a better location to calculate accessible checks for the first time?

@Malkierian
Copy link
Contributor

As Logic is already setup to utilize save context structures, you should probably be finding a way of running functions inherent to the randomizer generator itself rather than redoing work like you have here, if possible.

@Malkierian
Copy link
Contributor

Also, I think you're trying to get too specific with door openings. Logic doesn't register a dungeon as in logic unless a certain count of keys is obtained for it, which can be found in the randomizer code.

@Malkierian
Copy link
Contributor

Also, I think you're trying to get too specific with door openings. Logic doesn't register a dungeon as in logic unless a certain count of keys is obtained for it, which can be found in the randomizer code.

And, on top of that, there are far too many implications to the rest of the logic regarding changing that key/door logic than just each locked area, so changing that is not likely to be acceptable either way.

@Malkierian
Copy link
Contributor

Discussion of things surrounding this would definitely be much easier to have if you were on the Discord, in the soh-development channel.

@xxAtrain223
Copy link
Author

I'll join tomorrow and give you a ping around 7pm CT.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants