| delorie.com/archives/browse.cgi | search |
| Date: | Thu, 7 Oct 1999 19:58:01 +0200 (IST) |
| From: | Eli Zaretskii <eliz AT is DOT elta DOT co DOT il> |
| X-Sender: | eliz AT is |
| To: | Roland Moritz <hotel DOT moritz AT utanet DOT at> |
| cc: | djgpp AT delorie DOT com |
| Subject: | Re: How to empty the keyboard buffer |
| In-Reply-To: | <7tibo0$44f$1@rohrpostix.uta4you.at> |
| Message-ID: | <Pine.SUN.3.91.991007195639.24707A-100000@is> |
| MIME-Version: | 1.0 |
| Reply-To: | djgpp AT delorie DOT com |
| X-Mailing-List: | djgpp AT delorie DOT com |
| X-Unsubscribes-To: | listserv AT delorie DOT com |
On Thu, 7 Oct 1999, Roland Moritz wrote:
> allegro_init();
> install_timer();
> do
> {
> c = getch();
> rest(1000);
> while (kbhit())
> c = getch();
> }
> while (c != 27);
> }
>
> It basically does the same that happens in a game loop, but doesn't work
> (When I press a button for a longer time, I hear a loud beeping, which
> means, that the kb-buffer is full, right?)
That might be because of the rest(1000) call. How much time does it
wait? (I don't know much about ALlegro.) If it waits enough time, the
keyboard buffer could become full.
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |