Add Xbox trigger enum options

Bumper and trigger in place of 1/2, as used on the Playstation controllers.
This commit is contained in:
David Madison 2021-07-01 04:42:23 -04:00
parent b6511306f1
commit 6e63210c2a

View file

@ -143,10 +143,10 @@ enum ButtonEnum {
BACK, BACK,
// START, // listed under Playstation buttons // START, // listed under Playstation buttons
// L1, // listed under Playstation buttons LB,
// R1, // listed under Playstation buttons RB,
// L2, // listed under Playstation buttons LT,
// R2, // listed under Playstation buttons RT,
XBOX, XBOX,
SYNC, SYNC,
@ -199,10 +199,10 @@ inline constexpr int8_t ButtonIndex(ButtonEnum key) {
(key == START || key == OPTIONS || key == MENU || key == PLUS) ? 5 : (key == START || key == OPTIONS || key == MENU || key == PLUS) ? 5 :
(key == L3 || key == TWO) ? 6 : (key == L3 || key == TWO) ? 6 :
(key == R3 || key == ONE) ? 7 : (key == R3 || key == ONE) ? 7 :
(key == L2 || key == MINUS || key == BLACK) ? 8 : (key == L2 || key == LT || key == MINUS || key == BLACK) ? 8 :
(key == R2 || key == HOME || key == WHITE) ? 9 : (key == R2 || key == RT || key == HOME || key == WHITE) ? 9 :
(key == L1 || key == Z) ? 10 : (key == L1 || key == LB || key == Z) ? 10 :
(key == R1 || key == C) ? 11 : (key == R1 || key == RB || key == C) ? 11 :
(key == TRIANGLE || key == B) ? 12 : (key == TRIANGLE || key == B) ? 12 :
(key == CIRCLE || key == A) ? 13 : (key == CIRCLE || key == A) ? 13 :
(key == CROSS || key == X) ? 14 : (key == CROSS || key == X) ? 14 :