Mail Archives: djgpp/1999/05/04/06:21:32
CrashLogix writes:
> set_color_depth(24);
> set_gfx_mode(GFX_AUTODETECT,800,600,0,0);
You should always check for an error here: set_gfx_mode() might fail,
and bad things (crashes) will happen if you just carry on regardless.
> test_dat = load_datafile("test.dat");
> if (test_dat != NULL)
> {
> textout_centre(screen,test_dat[TEST].dat,"abcd",400,300,96);
Is it actually returning a NULL test_dat? If so, I'd guess that your
test.dat file isn't actually located in the current directory, or
perhaps that you put a password on it when you saved it out from
the grabber. If this load is working, the only thing I can think
is that your TEST object is in fact some other type than a FONT:
maybe you imported the PCX file as a bitmap or something by mistake?
Shawn Hargreaves.
- Raw text -