M_HandleMenuInput: Pass a choice of 2 to IT_CVAR/IT_ARROWS routines

- Permits IT_ARROWS routines to distinguish between a rightward input and an A-button input.
- Only M_ChangeCvar needed to change to accomodate this - every other example of IT_ARROWS already acommodates this
This commit is contained in:
toaster 2023-02-04 10:44:47 +00:00
parent 96297aad1c
commit 3ca1c554c4

View file

@ -143,7 +143,7 @@ static void M_ChangeCvar(INT32 choice)
return; return;
} }
choice = (choice<<1) - 1; choice = (choice == 0 ? -1 : 1);
if (((currentMenu->menuitems[itemOn].status & IT_CVARTYPE) == IT_CV_SLIDER) if (((currentMenu->menuitems[itemOn].status & IT_CVARTYPE) == IT_CV_SLIDER)
|| ((currentMenu->menuitems[itemOn].status & IT_CVARTYPE) == IT_CV_INVISSLIDER) || ((currentMenu->menuitems[itemOn].status & IT_CVARTYPE) == IT_CV_INVISSLIDER)
@ -939,7 +939,7 @@ static void M_HandleMenuInput(void)
{ {
case IT_CVAR: case IT_CVAR:
case IT_ARROWS: case IT_ARROWS:
routine(1); // right arrow routine(2); // usually right arrow
break; break;
case IT_CALL: case IT_CALL:
routine(itemOn); routine(itemOn);