Mac: Fix keyboard implementation for players 2-8

This commit is contained in:
Michael Buckley 2020-01-15 20:01:56 -08:00
parent 404c01019f
commit 70b3345476
1 changed files with 2 additions and 2 deletions

View File

@ -2838,7 +2838,7 @@ void QuitWithFatalError ( NSString *message)
pthread_mutex_lock(&keyLock);
S9xButton button = keyCodes[event.keyCode];
if ( button.buttonCode >= 0 && button.buttonCode < kNumButtons && button.player <= 0 && button.player <= MAC_MAX_PLAYERS)
if ( button.buttonCode >= 0 && button.buttonCode < kNumButtons && button.player >= 0 && button.player <= MAC_MAX_PLAYERS)
{
pressedKeys[button.player][button.buttonCode] = true;
}
@ -2866,7 +2866,7 @@ void QuitWithFatalError ( NSString *message)
pthread_mutex_lock(&keyLock);
S9xButton button = keyCodes[event.keyCode];
if ( button.buttonCode >= 0 && button.buttonCode < kNumButtons && button.player <= 0 && button.player <= MAC_MAX_PLAYERS)
if ( button.buttonCode >= 0 && button.buttonCode < kNumButtons && button.player >= 0 && button.player <= MAC_MAX_PLAYERS)
{
pressedKeys[button.player][button.buttonCode] = false;
}