Original Post
🔒 Locked
while (!_kbhit() );
Advertisement
I''d have to agree with my esteemed colleague Dr. Nes on the "Evil! Evil!!!" part... but really, the reason it''s not working all the time might be that you''re hitting a key that has an extended (2-byte) ASCII code. For instance, if you press an arrow key, PgUp, PgDown, etc., two characters are sent to the keyboard buffer instead of just one: a null character, followed by an identifying character. It could be that when you press such a key, it triggers two of your kbhit statements, one for the null, and one for the second byte. Just a guess, though, since I never use that evil stuff myself.
-Ironblayde
Aeon Software
-Ironblayde
Aeon Software
Topic Locked
This topic has been locked by a moderator. New replies are not allowed.
Sign in to reply to this topic.
Advertisement