Gamepads for OHR
Moderators: Bob the Hamster, marionline, SDHawk
- Soda_piggy
- Slime Knight
- Posts: 163
- Joined: Tue Oct 16, 2007 1:18 am
- Location: Osaka, Japan
- Contact:
- Bob the Hamster
- Liquid Metal King Slime
- Posts: 7460
- Joined: Tue Oct 16, 2007 2:34 pm
- Location: Hamster Republic (Ontario Enclave)
- Contact:
That can't possibly be it-- audierre.dll is for the music backed, and I don't see how it could be affecting the keyboard input, which is fully controlled by the gfx backend.VampiDucki wrote:Thank you so much! The audiere.dll fixes the problem right up. :D
Can you be more specific about what you did to work around the problem?
- Soda_piggy
- Slime Knight
- Posts: 163
- Joined: Tue Oct 16, 2007 1:18 am
- Location: Osaka, Japan
- Contact:
- Soda_piggy
- Slime Knight
- Posts: 163
- Joined: Tue Oct 16, 2007 1:18 am
- Location: Osaka, Japan
- Contact:
- Bob the Hamster
- Liquid Metal King Slime
- Posts: 7460
- Joined: Tue Oct 16, 2007 2:34 pm
- Location: Hamster Republic (Ontario Enclave)
- Contact:
Hmm, I see that gfx_directx is indeed doing something unusual with the arrow keys. When it receives one of those keypresses, it checks whether the "extended key flag" is set. Buried in the winapi documentation I found:
I think this could be considered an obscure bug in Joy2key, where it doesn't set the extended flag, and unsurprisingly almost no application (not the example code in the winapi documentation, nor any code I could find on the internet) bothers to check the extended key bit.
I'll remove that check from gfx_directx, because the way it's written, it would actually break on those old keyboards by treating them as if they didn't have arrow keys.
Basically, by checking these bits gfx_directx is trying to support early PC keyboards that did not have separate arrows keysThe Extended Key Flag is 1 if the keystroke results from one of the additional keys on the IBM enhanced keyboard. (The enhanced keyboard has 101 or 102 keys. Function keys are across the top. Cursor movement keys are separate from the numeric keypad, but the numeric keypad also duplicates the cursor movement keys.) This flag is set to 1 for the Alt and Ctrl keys at the right of the keyboard, the cursor movement keys (including Insert and Delete) that are not part of the numeric keypad, the slash (/) and Enter keys on the numeric keypad, and the Num Lock key
I think this could be considered an obscure bug in Joy2key, where it doesn't set the extended flag, and unsurprisingly almost no application (not the example code in the winapi documentation, nor any code I could find on the internet) bothers to check the extended key bit.
I'll remove that check from gfx_directx, because the way it's written, it would actually break on those old keyboards by treating them as if they didn't have arrow keys.
Anybody with a old keyboard like that is going to have a Model M which did have arrow keys anyway.
I've never seen anybody looking for PC/XT or AT's.
I've never seen anybody looking for PC/XT or AT's.
Last edited by Shizuma on Wed Mar 20, 2013 3:02 pm, edited 1 time in total.