Mail Archives: djgpp/1997/10/25/17:07:35
Jamie Love schrieb:
> Hi, my mind is blank to the way to do the following.
>
> What i want is an array of five DATAFILE pointers (of Allegro type)
>
> At the moment i have DATAFILE *tiledata;
>
> and i want to do it so that i can access one of five datafiles in a quick
> array something like:
>
> DATAFILE *tiledata[5];
>
> I know this is wrong as it doesn't seem to work.
Sorry, but this isn't wrong at all...
This gives you an array of five not initialized pointers to DATAFILE structures
>
> also, how to i access the data stored in the data array when i do use the
> array of pointers
>
> is it like:
>
> tiledata[arraypointernum][datanum].dat;
>
> or what?
Exactly that should work... remenber to use
tiledata[0] = load_datafile("dat1.dat");
tiledata[1] = load_datafile("dat2.dat");
...
- Raw text -