Skip to content

Commit 605c381

Browse files
committed
Add whistle and magnesis control images to menu
1 parent 693c8e8 commit 605c381

File tree

3 files changed

+13091
-3
lines changed

3 files changed

+13091
-3
lines changed

src/rendering/vulkan_imgui.cpp

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -317,8 +317,7 @@ RND_Renderer::ImGuiOverlay::ImGuiOverlay(VkCommandBuffer cb, VkExtent2D fbRes, V
317317
page1.emplace_back(createHelpImage((stbi_uc const*)controls, sizeof(controls)));
318318
page1.push_back(createHelpImage((stbi_uc const*)equip, sizeof(equip)));
319319
page1.push_back(createHelpImage((stbi_uc const*)swing, sizeof(swing)));
320-
page1.push_back(createHelpImage((stbi_uc const*)BOTWcontrolScheme_Magnesis, sizeof(BOTWcontrolScheme_Magnesis)));
321-
page1.push_back(createHelpImage((stbi_uc const*)BOTWcontrolScheme_Whistle, sizeof(BOTWcontrolScheme_Whistle)));
320+
page1.push_back(createHelpImage((stbi_uc const*)whistle_and_magnesis, sizeof(whistle_and_magnesis)));
322321
m_helpImagePages.push_back(page1);
323322

324323
VulkanUtils::DebugPipelineBarrier(cb);
@@ -856,18 +855,32 @@ void RND_Renderer::ImGuiOverlay::DrawHelpMenu() {
856855
if (cameraMode == 1) {
857856
float deadzone = settings.stickDeadzone;
858857
DrawSettingRow("Thumbstick Deadzone", [&]() {
858+
ImGui::PushItemWidth(windowWidth.x * 0.35f);
859859
if (ImGui::SliderFloat("##StickDeadzone", &deadzone, 0.0f, 0.5f, "%.2f")) {
860860
settings.stickDeadzone = deadzone;
861861
changed = true;
862862
}
863+
ImGui::PopItemWidth();
864+
ImGui::SameLine();
865+
if (ImGui::Button("Reset##Deadzone")) {
866+
settings.stickDeadzone = ModSettings::kDefaultStickDeadzone;
867+
changed = true;
868+
}
863869
});
864870

865871
float threshold = settings.axisThreshold;
866872
DrawSettingRow("Stick Direction Threshold", [&]() {
873+
ImGui::PushItemWidth(windowWidth.x * 0.35f);
867874
if (ImGui::SliderFloat("##AxisThreshold", &threshold, 0.1f, 0.9f, "%.2f")) {
868875
settings.axisThreshold = threshold;
869876
changed = true;
870877
}
878+
ImGui::PopItemWidth();
879+
ImGui::SameLine();
880+
if (ImGui::Button("Reset##Threshold")) {
881+
settings.axisThreshold = ModSettings::kDefaultAxisThreshold;
882+
changed = true;
883+
}
871884
});
872885

873886
DrawSettingRow("Reset Input Thresholds", [&]() {

0 commit comments

Comments
 (0)