Skip to content
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

Keys for Asteroids Deluxe don't work #29

Closed
mattgodbolt opened this issue Oct 18, 2014 · 9 comments
Closed

Keys for Asteroids Deluxe don't work #29

mattgodbolt opened this issue Oct 18, 2014 · 9 comments

Comments

@mattgodbolt
Copy link
Owner

[from the author! yay] : "The only trouble is the keys don't quite work properly:

Ctrl turns right
Caps Lock turns left continuously when enabled but I think holding Shift should turn left - I can't quite remember.
] is thrust but I'm not sure that's right

...I've only tried it in Safari and Chrome on a MacBook with UK keyboard layout though. Elite and Defender seem to work OK.."

@mattgodbolt
Copy link
Owner Author

Keys work OK on my US laptop.

@murkle
Copy link
Collaborator

murkle commented Oct 18, 2014

http://bbc.godbolt.org/?disc=%7CAtarisoft%2FAsteroidsDeluxe.zip&autoboot
UK Keyboard, Chrome, Win 8.1
all keys seem OK here (no "sticking"). Shift doesn't do anything. Is he using the same disc image?
Capslock: turn left
Ctrl: turn right
[: Thrust
Space: Shield
Enter: Fire

@mattgodbolt
Copy link
Owner Author

That's the one he linked, yes -- I wonder what's going on. I'll get his Chrome version.

@mattgodbolt
Copy link
Owner Author

" MacBook Pro Retina 16GB (Late 2013)
UK keyboard (build-in to MacBook)

System Version: OS X 10.9.5 (13F34)
Kernel Version: Darwin 13.4.0

Safari          Version 7.1 (9537.85.10.17.1)
Google Chrome   Version 38.0.2125.104

"

@jlarcombe
Copy link

For what it's worth, I noticed yesterday that the same thing happens in Zalaga running in Chrome on the Mac, and presumably any other game that uses caps lock to move left. Haven't debugged it, but it's as though jsbeeb 'sees' the key being held down continuously while the system's real caps lock is enabled.

@mattgodbolt
Copy link
Owner Author

Ah that could well be it! Thanks for the hint; though I'm not quite sure how one might go about fixing it.

My caps lock key is configured as a completely different key so I've not seen the problem :)

@jlarcombe
Copy link

Looking around, it seems as though this would be impossible to fix without a change to the browsers. Cocoa simply doesn't issue key up events for caps lock. They'd have to go down to a lower layer (IOHIDManager) and that would be a pain because it wouldn't come through the normal event loop. The Qt and Firefox developers have had the same problem (https://bugzilla.mozilla.org/show_bug.cgi?id=712535, https://bugreports.qt.io/browse/QTBUG-46549).

The 'Gaming' keyboard layout works around the problem in jsbeeb, of course.

@murkle
Copy link
Collaborator

murkle commented Oct 14, 2015

@richtw1 richtw1 added the input label Oct 20, 2015
mattgodbolt added a commit that referenced this issue Sep 14, 2024
Caps lock is treated like a "sticky" key in OS X. So...treat it
like a "tap". Fixes #297 and at least warns about #29
mattgodbolt added a commit that referenced this issue Sep 14, 2024
Caps lock is treated like a "sticky" key in OS X. So...treat it
like a "tap". Fixes #297 and at least warns about #29
@mattgodbolt
Copy link
Owner Author

Now jsbeeb will pop up a warning on Mac OS X. It seems intractable (have asked pals at Apple for help but don't expect much). Closing as "not planned" as I can't fix it generally.

@mattgodbolt mattgodbolt closed this as not planned Won't fix, can't repro, duplicate, stale Sep 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants