mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2025-02-23 22:32:50 -05:00
Manually declared rando menu
This commit is contained in:
parent
ffa3780d7b
commit
b42a282a84
@ -1381,30 +1381,44 @@ namespace SohImGui {
|
|||||||
|
|
||||||
for (const auto& category : windowCategories) {
|
for (const auto& category : windowCategories) {
|
||||||
ImGui::SetCursorPosY(0.0f);
|
ImGui::SetCursorPosY(0.0f);
|
||||||
if (ImGui::BeginMenu(category.first.c_str())) {
|
if (category.first != "Randomizer") {
|
||||||
if (category.first == "Randomizer") {
|
if (ImGui::BeginMenu(category.first.c_str())) {
|
||||||
if (ImGui::BeginMenu("Rando Enhancements"))
|
for (const std::string& name : category.second) {
|
||||||
{
|
std::string varName(name);
|
||||||
EnhancementCheckbox("Dynamic Item Fanfares", "gRandoFanfareByItemType");
|
varName.erase(std::remove_if(varName.begin(), varName.end(), [](unsigned char x) { return std::isspace(x); }), varName.end());
|
||||||
Tooltip(
|
std::string toggleName = "g" + varName + "Enabled";
|
||||||
"Change what fanfare is played to match the type of item that is\n"
|
|
||||||
"obtained. This can make fanfares longer than usual in some cases."
|
|
||||||
);
|
|
||||||
|
|
||||||
ImGui::EndMenu();
|
EnhancementCheckbox(name.c_str(), toggleName.c_str());
|
||||||
|
customWindows[name].enabled = CVar_GetS32(toggleName.c_str(), 0);
|
||||||
}
|
}
|
||||||
ImGui::Separator();
|
ImGui::EndMenu();
|
||||||
}
|
}
|
||||||
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";
|
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("Dynamic Item Fanfares", "gRandoFanfareByItemType");
|
||||||
|
Tooltip(
|
||||||
|
"Change what fanfare is played to match the type\n"
|
||||||
|
"of item that is obtained. This can make fanfares\n"
|
||||||
|
"longer than usual in some cases."
|
||||||
|
);
|
||||||
|
|
||||||
EnhancementCheckbox(name.c_str(), toggleName.c_str());
|
|
||||||
customWindows[name].enabled = CVar_GetS32(toggleName.c_str(), 0);
|
|
||||||
}
|
|
||||||
ImGui::EndMenu();
|
ImGui::EndMenu();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ImGui::EndMenu();
|
||||||
}
|
}
|
||||||
|
|
||||||
ImGui::EndMenuBar();
|
ImGui::EndMenuBar();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user