kb pad fix

This commit is contained in:
Jasper St. Pierre
2026-04-12 20:32:08 -07:00
parent 9f22f27909
commit 155c269e4f
+14 -14
View File
@@ -4,65 +4,65 @@
#include "ImGuiConsole.hpp"
void DuskDebugPad() {
if (ImGui::IsKeyPressed(ImGuiKey_K)) {
if (ImGui::IsKeyDown(ImGuiKey_K)) {
mDoCPd_c::getCpadInfo(PAD_1).mPressedButtonFlags |= PAD_BUTTON_A;
}
if (ImGui::IsKeyPressed(ImGuiKey_J)) {
if (ImGui::IsKeyDown(ImGuiKey_J)) {
mDoCPd_c::getCpadInfo(PAD_1).mPressedButtonFlags |= PAD_BUTTON_B;
}
if (ImGui::IsKeyPressed(ImGuiKey_L)) {
if (ImGui::IsKeyDown(ImGuiKey_L)) {
mDoCPd_c::getCpadInfo(PAD_1).mPressedButtonFlags |= PAD_BUTTON_X;
}
if (ImGui::IsKeyPressed(ImGuiKey_I)) {
if (ImGui::IsKeyDown(ImGuiKey_I)) {
mDoCPd_c::getCpadInfo(PAD_1).mPressedButtonFlags |= PAD_BUTTON_Y;
}
if (ImGui::IsKeyPressed(ImGuiKey_H)) {
if (ImGui::IsKeyDown(ImGuiKey_H)) {
mDoCPd_c::getCpadInfo(PAD_1).mPressedButtonFlags |= PAD_BUTTON_START;
}
if (ImGui::IsKeyPressed(ImGuiKey_O)) {
if (ImGui::IsKeyDown(ImGuiKey_O)) {
mDoCPd_c::getCpadInfo(PAD_1).mPressedButtonFlags |= PAD_TRIGGER_Z;
}
if (ImGui::IsKeyPressed(ImGuiKey_Keypad8)) {
if (ImGui::IsKeyDown(ImGuiKey_Keypad8)) {
mDoCPd_c::getCpadInfo(PAD_1).mPressedButtonFlags |= PAD_BUTTON_UP;
}
if (ImGui::IsKeyPressed(ImGuiKey_Keypad2)) {
if (ImGui::IsKeyDown(ImGuiKey_Keypad2)) {
mDoCPd_c::getCpadInfo(PAD_1).mPressedButtonFlags |= PAD_BUTTON_DOWN;
}
if (ImGui::IsKeyPressed(ImGuiKey_Keypad6)) {
if (ImGui::IsKeyDown(ImGuiKey_Keypad6)) {
mDoCPd_c::getCpadInfo(PAD_1).mPressedButtonFlags |= PAD_BUTTON_RIGHT;
}
if (ImGui::IsKeyPressed(ImGuiKey_Keypad4)) {
if (ImGui::IsKeyDown(ImGuiKey_Keypad4)) {
mDoCPd_c::getCpadInfo(PAD_1).mPressedButtonFlags |= PAD_BUTTON_LEFT;
}
if (ImGui::IsKeyPressed(ImGuiKey_W)) {
if (ImGui::IsKeyDown(ImGuiKey_W)) {
mDoCPd_c::getCpadInfo(PAD_1).mMainStickPosY = 1.0f;
mDoCPd_c::getCpadInfo(PAD_1).mMainStickValue = 1.0f;
mDoCPd_c::getCpadInfo(PAD_1).mMainStickAngle = 0x8000;
}
if (ImGui::IsKeyPressed(ImGuiKey_S)) {
if (ImGui::IsKeyDown(ImGuiKey_S)) {
mDoCPd_c::getCpadInfo(PAD_1).mMainStickPosY = -1.0f;
mDoCPd_c::getCpadInfo(PAD_1).mMainStickValue = 1.0f;
mDoCPd_c::getCpadInfo(PAD_1).mMainStickAngle = 0;
}
if (ImGui::IsKeyPressed(ImGuiKey_D)) {
if (ImGui::IsKeyDown(ImGuiKey_D)) {
mDoCPd_c::getCpadInfo(PAD_1).mMainStickPosX = 1.0f;
mDoCPd_c::getCpadInfo(PAD_1).mMainStickValue = 1.0f;
mDoCPd_c::getCpadInfo(PAD_1).mMainStickAngle = 0x4000;
}
if (ImGui::IsKeyPressed(ImGuiKey_A)) {
if (ImGui::IsKeyDown(ImGuiKey_A)) {
mDoCPd_c::getCpadInfo(PAD_1).mMainStickPosX = -1.0f;
mDoCPd_c::getCpadInfo(PAD_1).mMainStickValue = 1.0f;
mDoCPd_c::getCpadInfo(PAD_1).mMainStickAngle = -0x4000;