Skip to content

Add BQ Spoiler to Spectrum#8

Open
SlyryD wants to merge 1 commit intomzxrules:masterfrom
SlyryD:bqspoiler
Open

Add BQ Spoiler to Spectrum#8
SlyryD wants to merge 1 commit intomzxrules:masterfrom
SlyryD:bqspoiler

Conversation

@SlyryD
Copy link
Copy Markdown

@SlyryD SlyryD commented Jan 10, 2023

  • Add readable names for entrances
  • Add BQ spoiler command that outputs the full entrance shuffle log
  • Update existing BQ commands for consistency
  • Remove outdated BQ version support

Copy link
Copy Markdown
Owner

@mzxrules mzxrules left a comment

Choose a reason for hiding this comment

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

Missed this pr because I don't check up on my repos all that often

Most of the additions seem fine enough, but most of what is being deleted shouldn't be.

Cat = SpectrumCommand.Category.Proto,
Name = "bqspoiler",
Description = "Outputs Beta Quest entrance spoiler log",
Cat = SpectrumCommand.Category.Spectrum,
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Suggested change
Cat = SpectrumCommand.Category.Spectrum,
Cat = SpectrumCommand.Category.BetaQuest,

SpectrumCommand.Category is used to group together commands on the help menu. SpectrumCommand.Category.Spectrum is reserved for commands of significant importance since they are displayed first; they're either commands that configure the program itself or are important commands that always have applicable usage.

return VAR_Entrances;
}

static readonly short[] VAR_Entrances1_6 =
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Not sure why you chose to remove this stuff. This was an updated entrance that would have fixed a couple minor "bugged" entrances

Description = "Locates Beta Quest entrance by name",
Cat = SpectrumCommand.Category.Spectrum,
Sup = SpectrumCommand.Supported.OoT)]
private static void TestBetaQuestShuffleData(Arguments args)
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

why are you deleting this command?

Comment on lines +821 to +825
short entranceId = VAR_Entrances[i];
string fromEntrance = Grotto_Table.ContainsKey(entranceId) ? Grotto_Table[entranceId] : Entrance_Table[entranceId];
string toEntrance = Entrance_Table[read];

Console.WriteLine($"{fromEntrance} => {toEntrance}");
Copy link
Copy Markdown
Owner

@mzxrules mzxrules Nov 10, 2023

Choose a reason for hiding this comment

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

bqfindindex is not an adequate replacement for beta_ent.

the purpose of beta_ent is to convert a vanilla entranceId into a BetaQuest entranceId that can then be passed into the ent command for testing purposes, hence the name. the command should still have an alias to beta_ent

Second, you shouldn't assume that read will always map to Entrance_Table

Suggested change
short entranceId = VAR_Entrances[i];
string fromEntrance = Grotto_Table.ContainsKey(entranceId) ? Grotto_Table[entranceId] : Entrance_Table[entranceId];
string toEntrance = Entrance_Table[read];
Console.WriteLine($"{fromEntrance} => {toEntrance}");
short entranceId = VAR_Entrances[i];
string fromEntrance = Grotto_Table.ContainsKey(entranceId) ? Grotto_Table[entranceId] : Entrance_Table[entranceId];
string toEntrance = Entrance_Table.ContainsKey(entranceId) ? Entrance_Table[read] : $"{VAR_Entrances[i]:X4}" ;
Console.WriteLine($"{fromEntrance} => {toEntrance}");

string fromEntrance = Grotto_Table.ContainsKey(entrance) ? Grotto_Table[entrance] : Entrance_Table[entrance];

short read = shuffleTable.ReadInt16(i * 2);
string toEntrance = Entrance_Table[read];
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Suggested change
string toEntrance = Entrance_Table[read];
string toEntrance = Grotto_Table.ContainsKey(index) ? Grotto_Table[index] : Entrance_Table[index];

Don't assume that read always maps to an Entrance_Table record

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