www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1999/08/18/02:46:29

Message-ID: <37BA279C.47D9@ns.sympatico.ca>
From: Klaas <klaas AT ns DOT sympatico DOT ca>
X-Mailer: Mozilla 3.04 (Win95; I)
MIME-Version: 1.0
Newsgroups: comp.os.msdos.djgpp
Subject: Re: ALLEGRO: NEED TUTORIALS
References: <7pcvbq$tal$1 AT nnrp1 DOT deja DOT com>
Lines: 27
Date: Wed, 18 Aug 1999 03:25:05 GMT
NNTP-Posting-Host: 142.177.60.62
X-Complaints-To: abuse AT ns DOT sympatico DOT ca
X-Trace: sapphire.mtt.net 934946705 142.177.60.62 (Wed, 18 Aug 1999 00:25:05 ADT)
NNTP-Posting-Date: Wed, 18 Aug 1999 00:25:05 ADT
Organization: Sympatico-Subscriber
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

rpgmaletteallegro AT my-deja DOT com wrote:
> 
> Greetings fellow DJGPP/Allegro developers,
>   Do you agree with me when I say that Allegro should have had a users
> guide with it? I don't know how to use too much of this great library
> (it IS great, I just don't know how to use it). If ANYONE has a
> tutorial or a link to a tutorial dealing in Sprite graphics in Allegro,
> please tell me where to find it. I also need to know how to print out
> variables using the textout() function. PLEASE, I NEED HELP!!!

1. Use text_printf.  Works just like printf.

2. Use sprintf. eg.,

//--------
char temp_char[50];
int x=5;
float f=22/7.0;

sprintf(temp_char,"Printing variables: %d %f",x,f);
textout(my_bmp,my_font,temp_char,my_x,my_y,my_color);
//--------

I'm not sure if I have the right order of parameters there, i usually
use t_pf.

-Mike

- Raw text -


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