Date: Fri, 26 Jul 1996 14:26:37 +0200 (IST) From: Eli Zaretskii To: Deren Ercoskun Cc: djgpp Subject: Re: C question In-Reply-To: Message-Id: Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On Fri, 26 Jul 1996, Deren Ercoskun wrote: > How can I check the keyboard buffer to see if there is someething waiting > and if its an direction key how can I dertermine which one is it ?? > I use kbhit and getch but after getch I only get 0 ?? If `getch' returns 0, call it again and you will get the scancode of the key. Keys that don't have ASCI code always return a 0 on the first call to getch and the scancode on the next. Or you can use the `getkey' or `getxkey' functions that return the key in one call, even if it is a special key.