-
Notifications
You must be signed in to change notification settings - Fork 7.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Arrow keys UP+DOWN not recognized when holding spacebar! #949
Comments
This may not be a Phaser issue, but in fact a hardware issue. Keyboards often do not accept certain combinations of keys, especially when dealing with the cursor keys. Could you try using other combinations of keys to determine if this is truly a Phaser issue? For instance, using shift + WASD - or other keys which in normal use are meant to be held together. |
At first I thought so, too. But space + WASD works fine, space + numpad Keys (8456) works fine, enter + arrow keys work fine, etc. This would be the weirdest hardware limitation space+left+up doesn't work, but space+left+down works. |
If Space + WASD works fine then this is definitely a hardware issue, called 'key jamming': http://en.wikipedia.org/wiki/Rollover_(key)#Key_jamming_and_ghosting As a lefty who plays fps games, this affects me a lot - the cursor keys don't play well with the rest of the keyboard. |
This is a hardware issue, I even mention it in the Keyboard class documentation!
In the Invaders example above I can quite happily hold space and move left + up, because I use a gaming grade keyboard. |
Ok, so this is the weirdest hardware limitation. Thanks, guys! :) |
It's probably one of the most annoying ones too. |
This is a strange phenomenon, that's unfortunately very problematic for my game: If the space key is held down pushing the left and upper arrow key simultaneously will not be recognized. However the other combinations (up+right, down+right, down+left) are recognized!
This can be easily reproduced in the examples:
http://examples.phaser.io/_site/view_full.html?d=input&f=cursor+key+movement.js&t=cursor%20key%20movement
Though holding space will scroll the page, it's easy to memorize where the ball was at start (upper left corner). Now if you hold space and push up+left for a while, then scroll back up you can still see the ball exactly where he was. If instead you hold space and push up+right this will not be the case.
Using Phaser Master v2.0.5. Tested on Chrome 31.0.1650.63 m & Firefox 30.0
EDIT: It's easier to test in Invaders. Holding space to shoot and then pushing left+up and the ship won't move, but holding space and pushing left+down works:
http://examples.phaser.io/_site/view_full.html?d=games&f=invaders.js&t=invaders
The text was updated successfully, but these errors were encountered: