[edit] Should be moved to programming questions, I guess... Perhaps help with that from a moderator maybe..? (Sorry)

Hi,I'm having some issues with the keyboard key-up detection. The problem is that it seems like when I release ARROWUP and ARROWLEFT keys at the same time, the program doesn't detect that the ARROWLEFT-key is released. It behaves the same if I use keyboard events as if not.

The thing is that I can't repeat this with any other key combination - just with up/left keys. And it's quite easy to repeat. I'm beginning to think it's a hardware related problem, but does anyone have a solution to the problem?

Well, the most common way to detect key presses and releases is through keyboard events, but you said you tried that already... You made sure to also detect ALLEGRO_EVENT_KEY_UP events, right?

Also, is the problem only when up and left are pressed at the same time? Keyboards are pretty picky when you press multiple keys, and several combinations block all keyboard input. It makes sense: if you fall asleep on your keyboard while writing a document, you don't want to wake up to 671 pages of "g", but it does suck for playing games.Now, I know up and left are amongst the most jarring examples, but... That only seems to happen when I press up, left, and another key. Up and left alone normally work fine without blocking. Try it on another machine, I guess.I tried your code on my machine, and up+left works fine; the tank goes forward and rotates to the left.

Yeah, the code looks like it should be working, so it probably is hardware related. Many keyboards don't like it when certain combinations of keys are pressed, and even as few as two keys can be enough to mess things up.

To that end, it's always good to allow players to use different combinations and set their own controls. AWDS is common nowadays, but the numeric keypad is always a good standby too for a game that doesn't have any mouse controls.