delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/07/03/13:48:35

Date: Thu, 3 Jul 1997 10:42:17 -0700 (PDT)
Message-Id: <199707031742.KAA02467@adit.ap.net>
Mime-Version: 1.0
To: syntaxlogic AT earthlink DOT net
From: Nate Eldredge <eldredge AT ap DOT net>
Subject: Re: Using Timer?
Cc: djgpp AT delorie DOT com

Alex Kain wrote:
>I'm trying to use Allegro's timer functions in my tools and games I'm
>programming in C using DJGPP's compiler.   I'm sort of new to timing in
>games and I was wondering if their is a faq explaing the concept and use of
>such timer functions.
In Allegro, the timer works as follows (AFAIK):
- You set how often you want the timer to tick.
- You install a function to be called each time the timer ticks.
ALLEGRO.TXT contains an explanation of this topic, and I'm sure some of the
example programs demonstrate it. Take a look at that.

>I'd also like to know if their is a way to control
>input from the mouse and keyboard, and how to keep a game running around
>the same speed under different computers.  Please help.
Well, the timer always ticks at the speed you want regardless of the
computer, and Allegro contains many routines for dealing with the mouse and
keyboard. Read ALLEGRO.TXT, all the way through if need be, and then ask for
more help if you still need it.

HTH

Nate Eldredge
eldredge AT ap DOT net



- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019