QB64 bug or exception?
#2
(10-03-2022, 07:30 AM)Pete Wrote: This should detect the space bar pressed, even if other keys are held won,like arrow keys, but...

If you hold down the arrow up and arrow left keys at the same time, and press the space bar, you won't hear a sound. Try other combos like arrow up and arrow right while pressing the space bar and you will hear the sound.

So what's up? QB64 version 2.1 Development Build is blocking INKEY$, _KEYHIT, and _KEYDOWN from registering CHR$(32).

Code: (Select All)
DO
    IF INKEY$ = CHR$(32) THEN SOUND 1000, .2
LOOP

Change CHR$(32) to CHR$(9), no problem. Change INKEY$ to _KEYHIT = 32 or to _KEYDOWN(32) and it gets blocked again.

Any ideas as to why, or is this a bug that's been fixed in a newer version?

Pete

IMHO they (Galleon/QB64Team?) totally screwed the entire keyboard input system with the transition from SDL to OpenGL. I don't know how often I complained about in the .net forum, because I wasn't able to type a simple file path into the IDE, as the german keyboards key sequence for a backslash (AltGr+?) wasn't recognized. This finally was the reason for my alternative input routine which another member extended for more languages (follow green "Best Answer") link.

However, these will probably not solve your problem with recognizing multiple keys, but I bet its some of the same issue I had with the backslash. The whole keyboard input system should be ripped out and rebuild in a manner using the systems language/keyboard layout settings.
Reply


Messages In This Thread
QB64 bug or exception? - by Pete - 10-03-2022, 07:30 AM
RE: QB64 bug or exception? - by RhoSigma - 10-03-2022, 07:49 AM
RE: QB64 bug or exception? - by Pete - 10-03-2022, 11:11 AM
RE: QB64 bug or exception? - by James D Jarvis - 10-03-2022, 11:11 AM
RE: QB64 bug or exception? - by Pete - 10-03-2022, 11:19 AM
RE: QB64 bug or exception? - by James D Jarvis - 10-03-2022, 11:25 AM
RE: QB64 bug or exception? - by bplus - 10-03-2022, 02:46 PM
RE: QB64 bug or exception? - by TerryRitchie - 10-03-2022, 03:35 PM
RE: QB64 bug or exception? - by Pete - 10-03-2022, 05:22 PM
RE: QB64 bug or exception? - by James D Jarvis - 10-03-2022, 11:44 PM
RE: QB64 bug or exception? - by Pete - 10-04-2022, 12:10 AM
RE: QB64 bug or exception? - by James D Jarvis - 10-04-2022, 12:35 AM
RE: QB64 bug or exception? - by Pete - 10-04-2022, 12:52 AM
RE: QB64 bug or exception? - by mnrvovrfc - 10-04-2022, 02:05 AM



Users browsing this thread: 4 Guest(s)