put boss souls back on the menu

This commit is contained in:
Ralphie Morell 2023-11-17 16:35:37 -05:00
parent aa00765997
commit ae715bdc15
6 changed files with 55 additions and 43 deletions

View File

@ -829,7 +829,7 @@ void GenerateItemPool() {
ctx->PlaceItemInLocation(RC_KAK_100_GOLD_SKULLTULA_REWARD, RG_HUGE_RUPEE, false, true);
}
if (ShuffleBossSouls.IsNot(BOSSSOULS_OFF)) {
if (ctx->GetOption(RSK_SHUFFLE_BOSS_SOULS)) {
AddItemToMainPool(RG_GOHMA_SOUL);
AddItemToMainPool(RG_KING_DODONGO_SOUL);
AddItemToMainPool(RG_BARINADE_SOUL);
@ -839,17 +839,17 @@ void GenerateItemPool() {
AddItemToMainPool(RG_BONGO_BONGO_SOUL);
AddItemToMainPool(RG_TWINROVA_SOUL);
IceTrapModels.push_back(0xE0);
IceTrapModels.push_back(0xE1);
IceTrapModels.push_back(0xE2);
IceTrapModels.push_back(0xE3);
IceTrapModels.push_back(0xE4);
IceTrapModels.push_back(0xE5);
IceTrapModels.push_back(0xE6);
IceTrapModels.push_back(0xE7);
if (ShuffleBossSouls.Is(BOSSSOULS_ON_PLUS_GANON)) {
ctx->possibleIceTrapModels.push_back(RG_GOHMA_SOUL);
ctx->possibleIceTrapModels.push_back(RG_KING_DODONGO_SOUL);
ctx->possibleIceTrapModels.push_back(RG_BARINADE_SOUL);
ctx->possibleIceTrapModels.push_back(RG_PHANTOM_GANON_SOUL);
ctx->possibleIceTrapModels.push_back(RG_VOLVAGIA_SOUL);
ctx->possibleIceTrapModels.push_back(RG_MORPHA_SOUL);
ctx->possibleIceTrapModels.push_back(RG_BONGO_BONGO_SOUL);
ctx->possibleIceTrapModels.push_back(RG_TWINROVA_SOUL);
if (ctx->GetOption(RSK_SHUFFLE_BOSS_SOULS).Is(RO_BOSS_SOULS_ON_PLUS_GANON)) {
AddItemToMainPool(RG_GANON_SOUL);
IceTrapModels.push_back(0xE8);
ctx->possibleIceTrapModels.push_back(RG_GANON_SOUL);
}
}

View File

@ -477,7 +477,8 @@ namespace Logic {
}
bool HasBossSoul(RandomizerGet itemName) {
if (ShuffleBossSouls.Is(BOSSSOULS_OFF)) {
auto ctx = Rando::Context::GetInstance();
if (!ctx->GetOption(RSK_SHUFFLE_BOSS_SOULS)) {
return true;
}
switch(itemName) {
@ -498,7 +499,7 @@ namespace Logic {
case RG_TWINROVA_SOUL:
return CanSummonTwinrova; break;
case RG_GANON_SOUL:
return ShuffleBossSouls.Is(BOSSSOULS_ON_PLUS_GANON) ? CanSummonGanon : true;
return ctx->GetOption(RSK_SHUFFLE_BOSS_SOULS).Is(RO_BOSS_SOULS_ON_PLUS_GANON) ? CanSummonGanon : true;
break;
default: break;
}

View File

@ -703,39 +703,39 @@ void InitTrickNames() {
Text{"Piece of Cheese", "Morceau de Fromage", "Piece of Cheese"},
Text{"Triforce Shard", "Éclat de Triforce", "Triforce Shard"},
Text{"Shiny Rock", "Caiiloux Brillant", "Shiny Rock"}};
trickNameTable[0xE0] = {
trickNameTable[RG_GOHMA_SOUL] = {
Text{"Spider Sense", "", ""},
Text{"Deku Spirit", "", ""},
Text("Ghost of Ghoma", "", "")};
trickNameTable[0xE1] = {
trickNameTable[RG_KING_DODONGO_SOUL] = {
Text{"Lizard Soul", "", ""},
Text{"Regal Remains", "", ""},
Text{"Dodongo's Core", "", ""}};
trickNameTable[0xE2] = {
trickNameTable[RG_BARINADE_SOUL] = {
Text{"Parasitic Poltergeist", "", ""},
Text{"Jabu Insides", "", ""},
Text{"Barinade Bacteria", "", ""}};
trickNameTable[0xE3] = {
trickNameTable[RG_PHANTOM_GANON_SOUL] = {
Text{"Bigger Poe", "", ""},
Text{"Sacred Forest Pine Tree", "", ""},
Text{"Ganon's Phantom", "", ""}};
trickNameTable[0xE4] = {
trickNameTable[RG_VOLVAGIA_SOUL] = {
Text{"Dragon Roast", "", ""},
Text{"Hot n' Ready", "", ""},
Text{"Volvagia's Vitality", "", ""}};
trickNameTable[0xE5] = {
trickNameTable[RG_MORPHA_SOUL] = {
Text{"Dihydrogen Monoxide", "", ""},
Text{"Morpha Molecules", "", ""},
Text{"Wet Stuff", "", ""}};
trickNameTable[0xE6] = {
trickNameTable[RG_BONGO_BONGO_SOUL] = {
Text{"Shadow Soul", "", ""},
Text{"Dark Essence", "", ""},
Text{"Bongo Bongo's Bongo", "", ""}};
trickNameTable[0xE7] = {
trickNameTable[RG_TWINROVA_SOUL] = {
Text{"Sandy Ashes", "", ""},
Text{"Spiritual Spirit", "", ""},
Text{"Twin Rovers", "", ""}};
trickNameTable[0xE8] = {
trickNameTable[RG_GANON_SOUL] = {
Text{"Pure Evil", "", ""},
Text{"Ganon's Ghost", "", ""},
Text{"Pork", "", ""}};

View File

@ -278,8 +278,6 @@ extern "C" void Randomizer_DrawTriforcePieceGI(PlayState* play, GetItemEntry get
}
CLOSE_DISPS(play->state.gfxCtx);
}
// TODO get custom model for boss souls
extern "C" void Randomizer_DrawBossSoul(PlayState* play, GetItemEntry* getItemEntry) {
s16 slot = getItemEntry->getItemId - RG_GOHMA_SOUL;
@ -306,6 +304,7 @@ extern "C" void Randomizer_DrawBossSoul(PlayState* play, GetItemEntry* getItemEn
}
gSPDisplayList(POLY_XLU_DISP++, (Gfx*)gBossSoulSkullDL);
if (slot >= 0) {
Gfx_SetupDL_25Xlu(play->state.gfxCtx);
gSPSegment(POLY_XLU_DISP++, 8, (uintptr_t)Gfx_TwoTexScroll(
play->state.gfxCtx, 0, 0 * (play->state.frames * 0),
@ -323,6 +322,7 @@ extern "C" void Randomizer_DrawBossSoul(PlayState* play, GetItemEntry* getItemEn
gSPDisplayList(POLY_XLU_DISP++, (Gfx*)gGiBlueFireFlameDL);
gSPGrayscale(POLY_XLU_DISP++, false);
Matrix_Pop();
}
CLOSE_DISPS(play->state.gfxCtx);

View File

@ -2848,7 +2848,7 @@ void RandomizerSettingsWindow::DrawElement() {
// Shuffle Boss Souls
// Forces players to find a boss's soul before defeating them in their lair.
ImGui::Text("%s", Settings::ShuffleBossSouls.GetName().c_str());
ImGui::Text("%s", ctx->GetOption(RSK_SHUFFLE_BOSS_SOULS).GetName().c_str());
UIWidgets::InsertHelpHoverText("Shuffles 8 boss souls (one for each blue warp dungeon). A boss will not appear until you collect its respective soul."
"\n\"On + Ganon\" will also hide Ganon and Ganondorf behind a boss soul.");
UIWidgets::EnhancementCombobox("gRandomizeShuffleBossSouls", randoShuffleBossSouls, RO_BOSS_SOULS_OFF);

View File

@ -106,6 +106,7 @@ void Settings::CreateOptions() {
mOptions[RSK_SHUFFLE_ADULT_TRADE] = Option::Bool("Shuffle Adult Trade");
mOptions[RSK_SHUFFLE_CHEST_MINIGAME] = Option::U8("Shuffle Chest Minigame", {"Off", "On (Separate)", "On (Pack)"});
mOptions[RSK_SHUFFLE_100_GS_REWARD] = Option::Bool("Shuffle 100 GS Reward");
mOptions[RSK_SHUFFLE_BOSS_SOULS] = Option::U8("Shuffle Boss Souls", {"Off", "On", "On + Ganon"});
mOptions[RSK_SHUFFLE_MAPANDCOMPASS] = Option::U8("Maps/Compasses", {"Start With", "Vanilla", "Own Dungeon", "Any Dungeon", "Overworld", "Anywhere"}, OptionCategory::Setting, RO_DUNGEON_ITEM_LOC_OWN_DUNGEON);
mOptions[RSK_KEYSANITY] = Option::U8("Small Keys", {"Start With", "Vanilla", "Own Dungeon", "Any Dungeon", "Overworld", "Anywhere"}, OptionCategory::Setting, RO_DUNGEON_ITEM_LOC_OWN_DUNGEON);
mOptions[RSK_GERUDO_KEYS] = Option::U8("Gerudo Fortress Keys", {"Vanilla", "Any Dungeon", "Overworld", "Anywhere"});
@ -616,6 +617,7 @@ void Settings::CreateOptions() {
&mOptions[RSK_SHUFFLE_ADULT_TRADE],
&mOptions[RSK_SHUFFLE_CHEST_MINIGAME],
&mOptions[RSK_SHUFFLE_100_GS_REWARD],
&mOptions[RSK_SHUFFLE_BOSS_SOULS],
});
mOptionGroups[RSG_SHUFFLE_DUNGEON_ITEMS] = OptionGroup("Shuffle Dungeon Items", {
&mOptions[RSK_SHUFFLE_MAPANDCOMPASS],
@ -821,6 +823,7 @@ void Settings::CreateOptions() {
{ "Shuffle Settings:Shuffle Frog Song Rupees", RSK_SHUFFLE_FROG_SONG_RUPEES },
{ "Shuffle Settings:Shuffle Merchants", RSK_SHUFFLE_MERCHANTS },
{ "Shuffle Settings:Shuffle 100 GS Reward", RSK_SHUFFLE_100_GS_REWARD },
{ "Shuffle Settings:Shuffle Boss Souls", RSK_SHUFFLE_BOSS_SOULS },
{ "Start with Deku Shield", RSK_STARTING_DEKU_SHIELD },
{ "Start with Kokiri Sword", RSK_STARTING_KOKIRI_SWORD },
{ "Start with Fairy Ocarina", RSK_STARTING_OCARINA },
@ -1520,6 +1523,14 @@ void Settings::ParseJson(nlohmann::json spoilerFileJson) {
mOptions[index].SetSelectedIndex(RO_AMMO_DROPS_OFF);
}
break;
case RSK_SHUFFLE_BOSS_SOULS:
if (it.value() == "Off") {
mOptions[index].SetSelectedIndex(RO_BOSS_SOULS_OFF);
} else if (it.value() == "On") {
mOptions[index].SetSelectedIndex(RO_BOSS_SOULS_ON);
} else if (it.value() == "On + Ganon") {
mOptions[index].SetSelectedIndex(RO_BOSS_SOULS_ON_PLUS_GANON);
}
case RSK_STARTING_OCARINA:
if (it.value() == "Off") {
mOptions[index].SetSelectedIndex(RO_STARTING_OCARINA_OFF);