   [.net] missing key event
  OK, so I havethis.KeyDown += new KeyEventHandler(this.keyDownMethod)in my Form, and it works fine, except for one thing. When you press and hold down the down arrow key, and then press and hold down the up arrow key as well, and then finally press the left arrow key while still holding the other two, Left is not processed (the method is not hit for it). BUT, if you use the right arrow key instead of the left arrow key, the method is hit. Why would the right arrow key work in this case and not the left one? My OS is XP Professional, .Net version is 2.0, and keyboard is from Dynex. This is making the control schemes of a game less than ideal... I would like Left to work in this case, not just Right. Any ideas?I already tried overriding IsInputKey() but this had no effect.[Edited by - DanX2002 on January 20, 2010 1:09:12 PM]
  It's a keyboard hardware issue - the way that keys are wired internally means that not all combinations of held keys can be identified (generally, the cheaper the keyboard, the worse they are). I have a Dell multimedia keyboard, and holding up and down prevents the left key from working too (right still works, as per your example). This is sadly not a software issue (try other apps and see if you can hold up and down and press left at the same time).   ;  :-(That's really sad. The arrow keys are the most intuitive controls. It seems that a three-key combination using I-J-K-L also does not work.... not sure what to do   ;  On my keyboard the arrow keys printed on the number pad (2, 4, 6 and 8) all work. Of course, this won't help laptop users and is not likely to work on all keyboards. Bear in mind that gamepads usually make it physically impossible to press both up and down at the same time, too, by using a rocker over the four direction buttons.   ;Quote:Original post by DanX2002When you press and hold down the down arrow key, and then press and hold down the up arrow key as well, and then finally press the left arrow key while still holding the other two, Left is not processed (the method is not hit for it). BUT, if you use the right arrow key instead of the left arrow key, the method is hit. Why would the right arrow key work in this case and not the left one? My OS is XP Professional, .Net version is 2.0, and keyboard is from Dynex. This is making the control schemes of a game less than ideal... If your control scheme calls for holding down all three of those keys, it sounds like a game I would have no interest in playing. Just my opinion. I can't recall a game where two opposing keys are held down and something is still supposed to happen.   ;  That's not true at all. Many side-view games use left / right for movement and up for jump. To do a motion as simple as a running jump, you already need two keys, and for games that have complex moves the characters can perform (e.g. tekken button strings) you can easily have quite a few buttons that need to be pressed either simultaneously or in quick succession (in which case the user may not be fast enough to unpress each button before pressing the next).   ;Quote:Original post by DanX2002That's not true at all.Opposing keys – that is keys that act in opposite directions - up and down or left and right. If you look at a d-pad on a game controller you'll see that you usually cannot physically press the two buttons at once.   ;  Exactly. As an experiment at home, try moving left and right at the same time! [wink]   ;Quote:Original post by MachairaExactly. As an experiment at home, try moving left and right at the same time! [wink]Only be careful, because if you pass through a doorway while doing this, you will appear below the floor level in the next room.Oops, wait, thought we were talking about Zelda here!   ;  well, I suppose I can work around this. Thanks for the info   