mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2024-12-26 10:08:51 -05:00
Merge pull request #915 from aMannus/rando-enhancements-menu
Rando: Added extra flyout for item fanfares
This commit is contained in:
commit
bf6ef1344e
@ -1393,19 +1393,43 @@ namespace SohImGui {
|
||||
|
||||
for (const auto& category : windowCategories) {
|
||||
ImGui::SetCursorPosY(0.0f);
|
||||
if (ImGui::BeginMenu(category.first.c_str())) {
|
||||
for (const std::string& name : category.second) {
|
||||
std::string varName(name);
|
||||
varName.erase(std::remove_if(varName.begin(), varName.end(), [](unsigned char x) { return std::isspace(x); }), varName.end());
|
||||
std::string toggleName = "g" + varName + "Enabled";
|
||||
if (category.first != "Randomizer") {
|
||||
if (ImGui::BeginMenu(category.first.c_str())) {
|
||||
for (const std::string& name : category.second) {
|
||||
std::string varName(name);
|
||||
varName.erase(std::remove_if(varName.begin(), varName.end(), [](unsigned char x) { return std::isspace(x); }), varName.end());
|
||||
std::string toggleName = "g" + varName + "Enabled";
|
||||
|
||||
EnhancementCheckbox(name.c_str(), toggleName.c_str());
|
||||
customWindows[name].enabled = CVar_GetS32(toggleName.c_str(), 0);
|
||||
EnhancementCheckbox(name.c_str(), toggleName.c_str());
|
||||
customWindows[name].enabled = CVar_GetS32(toggleName.c_str(), 0);
|
||||
}
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
}
|
||||
|
||||
// Randomizer Menu
|
||||
ImGui::SetCursorPosY(0.0f);
|
||||
if (ImGui::BeginMenu("Randomizer"))
|
||||
{
|
||||
EnhancementCheckbox("Randomizer Settings", "gRandomizerSettingsEnabled");
|
||||
customWindows["Randomizer Settings"].enabled = CVar_GetS32("gRandomizerSettingsEnabled", 0);
|
||||
EnhancementCheckbox("Item Tracker", "gItemTrackerEnabled");
|
||||
customWindows["Item Tracker"].enabled = CVar_GetS32("gItemTrackerEnabled", 0);
|
||||
|
||||
ImGui::Separator();
|
||||
if (ImGui::BeginMenu("Rando Enhancements"))
|
||||
{
|
||||
EnhancementCheckbox("Quest Item Fanfares", "gRandoQuestItemFanfares");
|
||||
Tooltip(
|
||||
"Play unique fanfares when obtaining quest items\n"
|
||||
"(medallions/stones/songs). Note that these fanfares\n"
|
||||
"are longer than usual."
|
||||
);
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
ImGui::EndMenu();
|
||||
}
|
||||
ImGui::EndMenuBar();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user