From 74aa14c9b47c848a1b9832379d8cd69b558037f8 Mon Sep 17 00:00:00 2001 From: shinyquagsire23 Date: Mon, 15 Jan 2018 00:24:23 -0700 Subject: settings: adjust button configs for Switch controllers --- src/core/settings.h | 67 +++++++++++++++++++++++++++++++++++++++-------------- 1 file changed, 50 insertions(+), 17 deletions(-) (limited to 'src/core') diff --git a/src/core/settings.h b/src/core/settings.h index f2c88e5d4..be79ff78e 100644 --- a/src/core/settings.h +++ b/src/core/settings.h @@ -16,17 +16,32 @@ enum Values { B, X, Y, - Up, - Down, - Left, - Right, + LStick, + RStick, L, R, - Start, - Select, - ZL, ZR, + Plus, + Minus, + + DLeft, + DUp, + DRight, + DDown, + + LStick_Left, + LStick_Up, + LStick_Right, + LStick_Down, + + RStick_Left, + RStick_Up, + RStick_Right, + RStick_Down, + + SL, + SR, Home, @@ -34,34 +49,52 @@ enum Values { }; constexpr int BUTTON_HID_BEGIN = A; -constexpr int BUTTON_IR_BEGIN = ZL; constexpr int BUTTON_NS_BEGIN = Home; -constexpr int BUTTON_HID_END = BUTTON_IR_BEGIN; -constexpr int BUTTON_IR_END = BUTTON_NS_BEGIN; +constexpr int BUTTON_HID_END = BUTTON_NS_BEGIN; constexpr int BUTTON_NS_END = NumButtons; constexpr int NUM_BUTTONS_HID = BUTTON_HID_END - BUTTON_HID_BEGIN; -constexpr int NUM_BUTTONS_IR = BUTTON_IR_END - BUTTON_IR_BEGIN; constexpr int NUM_BUTTONS_NS = BUTTON_NS_END - BUTTON_NS_BEGIN; static const std::array mapping = {{ - "button_a", "button_b", "button_x", "button_y", "button_up", "button_down", "button_left", - "button_right", "button_l", "button_r", "button_start", "button_select", "button_zl", - "button_zr", "button_home", + "button_a", + "button_b", + "button_x", + "button_y", + "button_lstick", + "button_rstick", + "button_l", + "button_r", + "button_zl", + "button_zr", + "button_plus", + "button_minus", + "button_dleft", + "button_dup", + "button_dright", + "button_ddown", + "button_lstick_left", + "button_lstick_up", + "button_lstick_right", + "button_lstick_down", + "button_sl", + "button_sr", + "button_home", }}; } // namespace NativeButton namespace NativeAnalog { enum Values { - CirclePad, - CStick, + LStick, + RStick, NumAnalogs, }; static const std::array mapping = {{ - "circle_pad", "c_stick", + "lstick", + "rstick", }}; } // namespace NativeAnalog -- cgit v1.2.3