Ke-catching and STILL proceding with screen-updating...

Started by
0 comments, last by Scorpion 24 years, 1 month ago
I''m using a structure in my game (directx, dinput), and whenever i hold (for example) the upkey, it "blocks" the entire game... It''s a nibble''s game, and with the upkey pressed, it checks if it isn''t been the last key that has been pressed, so it won''t set the "north" direction again. for example: if ((INPUT(VIK_UP)) && (nibble.movement!=NORTH){ nibble.movement=NORTH; } but when i hold the up-key in this example, it will move for 2 blocks (with the current speed i use) and then it stops until i release the key. After that it will move the normal speed again. What the hell is wrong? Why doesn''t he get out of the loop when i hold the key down?? icq# 10251921 thescorpion@most-wanted.com
Advertisement
Well, normally you call keyboard->GetDeviceState() once per frame (or once per few frames) and then just check your array. Is that how you''re doing it?

------------------------------
Jonathan Little
invader@hushmail.com
http://www.crosswinds.net/~uselessknowledge

This topic is closed to new replies.

Advertisement