mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-04-27 04:21:47 +00:00
Merge branch 'virtual-keyboard-fix' into 'master'
Only toggle keyboardTyping when input key is valid See merge request KartKrew/Kart!1604
This commit is contained in:
commit
ade0b7cf10
1 changed files with 2 additions and 2 deletions
|
|
@ -237,7 +237,7 @@ void M_MenuTypingInput(INT32 key)
|
||||||
if (!menutyping.keyboardtyping) // controller inputs
|
if (!menutyping.keyboardtyping) // controller inputs
|
||||||
{
|
{
|
||||||
// we pressed a keyboard input that's not any of our buttons
|
// we pressed a keyboard input that's not any of our buttons
|
||||||
if (M_IsTypingKey(key) && menucmd[pid].dpad_lr == 0 && menucmd[pid].dpad_ud == 0
|
if (key >= 0 && M_IsTypingKey(key) && menucmd[pid].dpad_lr == 0 && menucmd[pid].dpad_ud == 0
|
||||||
&& !(menucmd[pid].buttons & MBT_A)
|
&& !(menucmd[pid].buttons & MBT_A)
|
||||||
&& !(menucmd[pid].buttons & MBT_B)
|
&& !(menucmd[pid].buttons & MBT_B)
|
||||||
&& !(menucmd[pid].buttons & MBT_C)
|
&& !(menucmd[pid].buttons & MBT_C)
|
||||||
|
|
@ -252,7 +252,7 @@ void M_MenuTypingInput(INT32 key)
|
||||||
else // Keyboard inputs.
|
else // Keyboard inputs.
|
||||||
{
|
{
|
||||||
// On the flipside, if we're pressing any keyboard input, switch to controller inputs.
|
// On the flipside, if we're pressing any keyboard input, switch to controller inputs.
|
||||||
if (!M_IsTypingKey(key) && (
|
if (key >= 0 && !M_IsTypingKey(key) && (
|
||||||
M_MenuButtonPressed(pid, MBT_A)
|
M_MenuButtonPressed(pid, MBT_A)
|
||||||
|| M_MenuButtonPressed(pid, MBT_B)
|
|| M_MenuButtonPressed(pid, MBT_B)
|
||||||
|| M_MenuButtonPressed(pid, MBT_C)
|
|| M_MenuButtonPressed(pid, MBT_C)
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue