mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2025-07-06 04:51:30 -07:00
bump lus (to bump imgui) (#5501)
This commit is contained in:
parent
b418db7792
commit
3c0e7bcf72
2 changed files with 8 additions and 8 deletions
|
@ -1 +1 @@
|
||||||
Subproject commit 7135d1494e74c38aa7fca734b92ec50bba543b44
|
Subproject commit 6a3f6cd327b99f617b623e5b9a3afeae460aac2b
|
|
@ -49,14 +49,14 @@ void InputViewer::RenderButton(std::string btnTexture, std::string btnOutlineTex
|
||||||
if (outlineMode == BUTTON_OUTLINE_ALWAYS_SHOWN || (outlineMode == BUTTON_OUTLINE_NOT_PRESSED && !state) ||
|
if (outlineMode == BUTTON_OUTLINE_ALWAYS_SHOWN || (outlineMode == BUTTON_OUTLINE_NOT_PRESSED && !state) ||
|
||||||
(outlineMode == BUTTON_OUTLINE_PRESSED && state)) {
|
(outlineMode == BUTTON_OUTLINE_PRESSED && state)) {
|
||||||
ImGui::Image(Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName(btnOutlineTexture), size,
|
ImGui::Image(Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName(btnOutlineTexture), size,
|
||||||
ImVec2(0, 0), ImVec2(1.0f, 1.0f), ImVec4(255, 255, 255, 255));
|
ImVec2(0, 0), ImVec2(1.0f, 1.0f));
|
||||||
}
|
}
|
||||||
// Render button if pressed
|
// Render button if pressed
|
||||||
if (state) {
|
if (state) {
|
||||||
ImGui::SetCursorPos(pos);
|
ImGui::SetCursorPos(pos);
|
||||||
ImGui::SetNextItemAllowOverlap();
|
ImGui::SetNextItemAllowOverlap();
|
||||||
ImGui::Image(Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName(btnTexture), size,
|
ImGui::Image(Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName(btnTexture), size,
|
||||||
ImVec2(0, 0), ImVec2(1.0f, 1.0f), ImVec4(255, 255, 255, 255));
|
ImVec2(0, 0), ImVec2(1.0f, 1.0f));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -201,7 +201,7 @@ void InputViewer::DrawElement() {
|
||||||
// Background
|
// Background
|
||||||
ImGui::Image(
|
ImGui::Image(
|
||||||
Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName("Input-Viewer-Background"),
|
Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName("Input-Viewer-Background"),
|
||||||
scaledBGSize, ImVec2(0, 0), ImVec2(1.0f, 1.0f), ImVec4(255, 255, 255, 255));
|
scaledBGSize, ImVec2(0, 0), ImVec2(1.0f, 1.0f));
|
||||||
}
|
}
|
||||||
|
|
||||||
// A/B
|
// A/B
|
||||||
|
@ -352,7 +352,7 @@ void InputViewer::DrawElement() {
|
||||||
ImGui::SetCursorPos(aPos);
|
ImGui::SetCursorPos(aPos);
|
||||||
ImGui::Image(
|
ImGui::Image(
|
||||||
Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName("Analog-Stick Outline"),
|
Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName("Analog-Stick Outline"),
|
||||||
scaledBGSize, ImVec2(0, 0), ImVec2(1.0f, 1.0f), ImVec4(255, 255, 255, 255));
|
scaledBGSize, ImVec2(0, 0), ImVec2(1.0f, 1.0f));
|
||||||
}
|
}
|
||||||
const int analogStickMode =
|
const int analogStickMode =
|
||||||
CVarGetInteger(CVAR_INPUT_VIEWER("AnalogStick.VisibilityMode"), STICK_MODE_ALWAYS_SHOWN);
|
CVarGetInteger(CVAR_INPUT_VIEWER("AnalogStick.VisibilityMode"), STICK_MODE_ALWAYS_SHOWN);
|
||||||
|
@ -363,7 +363,7 @@ void InputViewer::DrawElement() {
|
||||||
ImVec2(aPos.x + maxStickDistance * ((float)(pads[0].stick_x) / MAX_AXIS_RANGE) * scale,
|
ImVec2(aPos.x + maxStickDistance * ((float)(pads[0].stick_x) / MAX_AXIS_RANGE) * scale,
|
||||||
aPos.y - maxStickDistance * ((float)(pads[0].stick_y) / MAX_AXIS_RANGE) * scale));
|
aPos.y - maxStickDistance * ((float)(pads[0].stick_y) / MAX_AXIS_RANGE) * scale));
|
||||||
ImGui::Image(Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName("Analog-Stick"),
|
ImGui::Image(Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName("Analog-Stick"),
|
||||||
scaledBGSize, ImVec2(0, 0), ImVec2(1.0f, 1.0f), ImVec4(255, 255, 255, 255));
|
scaledBGSize, ImVec2(0, 0), ImVec2(1.0f, 1.0f));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Right Stick
|
// Right Stick
|
||||||
|
@ -376,7 +376,7 @@ void InputViewer::DrawElement() {
|
||||||
ImGui::SetCursorPos(aPos);
|
ImGui::SetCursorPos(aPos);
|
||||||
ImGui::Image(
|
ImGui::Image(
|
||||||
Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName("Right-Stick Outline"),
|
Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName("Right-Stick Outline"),
|
||||||
scaledBGSize, ImVec2(0, 0), ImVec2(1.0f, 1.0f), ImVec4(255, 255, 255, 255));
|
scaledBGSize, ImVec2(0, 0), ImVec2(1.0f, 1.0f));
|
||||||
}
|
}
|
||||||
const int rightStickMode =
|
const int rightStickMode =
|
||||||
CVarGetInteger(CVAR_INPUT_VIEWER("RightStick.VisibilityMode"), STICK_MODE_ALWAYS_HIDDEN);
|
CVarGetInteger(CVAR_INPUT_VIEWER("RightStick.VisibilityMode"), STICK_MODE_ALWAYS_HIDDEN);
|
||||||
|
@ -387,7 +387,7 @@ void InputViewer::DrawElement() {
|
||||||
ImVec2(aPos.x + maxRightStickDistance * ((float)(pads[0].right_stick_x) / MAX_AXIS_RANGE) * scale,
|
ImVec2(aPos.x + maxRightStickDistance * ((float)(pads[0].right_stick_x) / MAX_AXIS_RANGE) * scale,
|
||||||
aPos.y - maxRightStickDistance * ((float)(pads[0].right_stick_y) / MAX_AXIS_RANGE) * scale));
|
aPos.y - maxRightStickDistance * ((float)(pads[0].right_stick_y) / MAX_AXIS_RANGE) * scale));
|
||||||
ImGui::Image(Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName("Right-Stick"),
|
ImGui::Image(Ship::Context::GetInstance()->GetWindow()->GetGui()->GetTextureByName("Right-Stick"),
|
||||||
scaledBGSize, ImVec2(0, 0), ImVec2(1.0f, 1.0f), ImVec4(255, 255, 255, 255));
|
scaledBGSize, ImVec2(0, 0), ImVec2(1.0f, 1.0f));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Analog stick angle text
|
// Analog stick angle text
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue