mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2025-08-22 22:33:43 -07:00
Comment out satellite preset pickers for now.
This commit is contained in:
parent
26437223c3
commit
5200bd9723
2 changed files with 43 additions and 42 deletions
|
@ -3651,47 +3651,47 @@ void RandomizerSettingsWindow::DrawElement() {
|
||||||
bool disableEditingRandoSettings =
|
bool disableEditingRandoSettings =
|
||||||
CVarGetInteger(CVAR_GENERAL("RandoGenerating"), 0) || CVarGetInteger(CVAR_GENERAL("OnFileSelectNameEntry"), 0);
|
CVarGetInteger(CVAR_GENERAL("RandoGenerating"), 0) || CVarGetInteger(CVAR_GENERAL("OnFileSelectNameEntry"), 0);
|
||||||
ImGui::BeginDisabled(CVarGetInteger(CVAR_SETTING("DisableChanges"), 0) || disableEditingRandoSettings);
|
ImGui::BeginDisabled(CVarGetInteger(CVAR_SETTING("DisableChanges"), 0) || disableEditingRandoSettings);
|
||||||
const PresetTypeDefinition presetTypeDef = presetTypes.at(PRESET_TYPE_RANDOMIZER);
|
//const PresetTypeDefinition presetTypeDef = presetTypes.at(PRESET_TYPE_RANDOMIZER);
|
||||||
std::string comboboxTooltip = "";
|
//std::string comboboxTooltip = "";
|
||||||
for (auto iter = presetTypeDef.presets.begin(); iter != presetTypeDef.presets.end(); ++iter) {
|
//for (auto iter = presetTypeDef.presets.begin(); iter != presetTypeDef.presets.end(); ++iter) {
|
||||||
if (iter->first != 0)
|
// if (iter->first != 0)
|
||||||
comboboxTooltip += "\n\n";
|
// comboboxTooltip += "\n\n";
|
||||||
comboboxTooltip += std::string(iter->second.label) + " - " + std::string(iter->second.description);
|
// comboboxTooltip += std::string(iter->second.label) + " - " + std::string(iter->second.description);
|
||||||
}
|
//}
|
||||||
const std::string presetTypeCvar = CVAR_GENERAL("SelectedPresets.") + std::to_string(PRESET_TYPE_RANDOMIZER);
|
//const std::string presetTypeCvar = CVAR_GENERAL("SelectedPresets.") + std::to_string(PRESET_TYPE_RANDOMIZER);
|
||||||
randomizerPresetSelected = CVarGetInteger(presetTypeCvar.c_str(), RANDOMIZER_PRESET_DEFAULT);
|
//randomizerPresetSelected = CVarGetInteger(presetTypeCvar.c_str(), RANDOMIZER_PRESET_DEFAULT);
|
||||||
|
|
||||||
if (UIWidgets::Combobox("Randomizer Presets", &randomizerPresetSelected, randomizerPresetList,
|
//if (UIWidgets::Combobox("Randomizer Presets", &randomizerPresetSelected, randomizerPresetList,
|
||||||
UIWidgets::ComboboxOptions()
|
// UIWidgets::ComboboxOptions()
|
||||||
.DefaultIndex(RANDOMIZER_PRESET_DEFAULT)
|
// .DefaultIndex(RANDOMIZER_PRESET_DEFAULT)
|
||||||
.Tooltip(comboboxTooltip.c_str())
|
// .Tooltip(comboboxTooltip.c_str())
|
||||||
.Color(THEME_COLOR))) {
|
// .Color(THEME_COLOR))) {
|
||||||
CVarSetInteger(presetTypeCvar.c_str(), randomizerPresetSelected);
|
// CVarSetInteger(presetTypeCvar.c_str(), randomizerPresetSelected);
|
||||||
}
|
//}
|
||||||
ImGui::SameLine();
|
//ImGui::SameLine();
|
||||||
ImGui::SetCursorPosY(ImGui::GetCursorPos().y + 35.f);
|
//ImGui::SetCursorPosY(ImGui::GetCursorPos().y + 35.f);
|
||||||
if (UIWidgets::Button(
|
//if (UIWidgets::Button(
|
||||||
"Apply Preset##Randomizer",
|
// "Apply Preset##Randomizer",
|
||||||
UIWidgets::ButtonOptions().Color(THEME_COLOR).Size(UIWidgets::Sizes::Inline).Padding(ImVec2(10.f, 6.f)))) {
|
// UIWidgets::ButtonOptions().Color(THEME_COLOR).Size(UIWidgets::Sizes::Inline).Padding(ImVec2(10.f, 6.f)))) {
|
||||||
if (randomizerPresetSelected >= presetTypeDef.presets.size()) {
|
// if (randomizerPresetSelected >= presetTypeDef.presets.size()) {
|
||||||
randomizerPresetSelected = 0;
|
// randomizerPresetSelected = 0;
|
||||||
}
|
// }
|
||||||
const PresetDefinition selectedPresetDef = presetTypeDef.presets.at(randomizerPresetSelected);
|
// const PresetDefinition selectedPresetDef = presetTypeDef.presets.at(randomizerPresetSelected);
|
||||||
for (const char* block : presetTypeDef.blocksToClear) {
|
// for (const char* block : presetTypeDef.blocksToClear) {
|
||||||
CVarClearBlock(block);
|
// CVarClearBlock(block);
|
||||||
}
|
// }
|
||||||
if (randomizerPresetSelected != 0) {
|
// if (randomizerPresetSelected != 0) {
|
||||||
applyPreset(selectedPresetDef.entries);
|
// applyPreset(selectedPresetDef.entries);
|
||||||
}
|
// }
|
||||||
CVarSetInteger(presetTypeCvar.c_str(), randomizerPresetSelected);
|
// CVarSetInteger(presetTypeCvar.c_str(), randomizerPresetSelected);
|
||||||
Ship::Context::GetInstance()->GetWindow()->GetGui()->SaveConsoleVariablesNextFrame();
|
// Ship::Context::GetInstance()->GetWindow()->GetGui()->SaveConsoleVariablesNextFrame();
|
||||||
mSettings->UpdateOptionProperties();
|
// mSettings->UpdateOptionProperties();
|
||||||
// force excluded location list and trick list update if tab is open.
|
// // force excluded location list and trick list update if tab is open.
|
||||||
locationsTabOpen = false;
|
// locationsTabOpen = false;
|
||||||
tricksTabOpen = false;
|
// tricksTabOpen = false;
|
||||||
}
|
//}
|
||||||
|
|
||||||
UIWidgets::Spacer(0);
|
//UIWidgets::Spacer(0);
|
||||||
UIWidgets::CVarCheckbox("Manual seed entry", CVAR_RANDOMIZER_SETTING("ManualSeedEntry"),
|
UIWidgets::CVarCheckbox("Manual seed entry", CVAR_RANDOMIZER_SETTING("ManualSeedEntry"),
|
||||||
UIWidgets::CheckboxOptions().Color(THEME_COLOR));
|
UIWidgets::CheckboxOptions().Color(THEME_COLOR));
|
||||||
if (CVarGetInteger(CVAR_RANDOMIZER_SETTING("ManualSeedEntry"), 0)) {
|
if (CVarGetInteger(CVAR_RANDOMIZER_SETTING("ManualSeedEntry"), 0)) {
|
||||||
|
|
|
@ -35,7 +35,7 @@ void SohMenu::AddMenuEnhancements() {
|
||||||
AddMenuEntry("Enhancements", CVAR_SETTING("Menu.EnhancementsSidebarSection"));
|
AddMenuEntry("Enhancements", CVAR_SETTING("Menu.EnhancementsSidebarSection"));
|
||||||
|
|
||||||
// Enhancements
|
// Enhancements
|
||||||
WidgetPath path = { "Enhancements", "Presets", SECTION_COLUMN_1 };
|
/*WidgetPath path = {"Enhancements", "Presets", SECTION_COLUMN_1};
|
||||||
AddSidebarEntry("Enhancements", path.sidebarName, 3);
|
AddSidebarEntry("Enhancements", path.sidebarName, 3);
|
||||||
|
|
||||||
const PresetTypeDefinition presetTypeDef = presetTypes.at(PRESET_TYPE_ENHANCEMENTS);
|
const PresetTypeDefinition presetTypeDef = presetTypes.at(PRESET_TYPE_ENHANCEMENTS);
|
||||||
|
@ -75,10 +75,11 @@ void SohMenu::AddMenuEnhancements() {
|
||||||
}
|
}
|
||||||
CVarSetInteger(presetTypeCvar.c_str(), selectedPresetId);
|
CVarSetInteger(presetTypeCvar.c_str(), selectedPresetId);
|
||||||
Ship::Context::GetInstance()->GetWindow()->GetGui()->SaveConsoleVariablesNextFrame();
|
Ship::Context::GetInstance()->GetWindow()->GetGui()->SaveConsoleVariablesNextFrame();
|
||||||
});
|
});*/
|
||||||
|
|
||||||
// Quality of Life
|
// Quality of Life
|
||||||
path.sidebarName = "Quality of Life";
|
//path.sidebarName = "Quality of Life";
|
||||||
|
WidgetPath path = { "Enhancements", "Quality of Life", SECTION_COLUMN_1 };
|
||||||
AddSidebarEntry("Enhancements", path.sidebarName, 3);
|
AddSidebarEntry("Enhancements", path.sidebarName, 3);
|
||||||
path.column = SECTION_COLUMN_1;
|
path.column = SECTION_COLUMN_1;
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue