[AD] load_datafile_object with properties

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


The load_datafile_object function doesn't read properties (it's not the
most useful function, but I'd have some use for it now - if it would
read properties) - and in my recent debugging adventures with datafiles
I learned enough about the datafile format to make a patch. It got a bit
longer than my expected 3 lines - and I wanted to avoid too much code
duplication, therefore I also had to simplify the other datafile reading
function a bit. Probably the reasons this wasn't fixed earlier :)

I tested all example programs using datafiles - and everything seems to
work (as well as my own big nested datafile), but I just reordered the
code a bit and split it into separate functions, so no surprise :) I
also did some speedup tests which show that my load_datafile_object has
about the same speed as before, again no surprise as I copied code out
of file.c :)

There also is no more MAX_PROPERTIES limit. Only tested under linux.

--
Elias Pschernig

Attachment: object_properties.diff.gz
Description: GNU Zip compressed data



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/