[aquaria] Loading treasures.txt from a mod

Kasoroth kasoroth at concordant-opposition.net
Tue Feb 15 00:52:34 EST 2011


I recently started experimenting with Aquaria's modding tools, and one 
of the first things I tried to do was create custom collectible 
treasures.  I couldn't find any information about how to load the 
treasures.txt file from a mod, so I decided to look at the source to 
figure it out.

After a bit more examination of how the treasure menu works, it seemed 
like the problem with adding/modifying collectibles in a mod was that 
treasures.txt, stringbank.txt, and menu-treasures.lua were all loaded 
only from the main game, and also the number of treasures (for purposes 
of next/prev page in the treasure menu) was hard coded to 32 (2 pages of 
16).

I've created a quick patch that to fix these problems and allow 
additional collectibles in mods.  I've only recently started looking at 
the Aquaria code, so if there is already some other way to do this that 
I'm missing, I apologize.  I hope this code is useful to the modders out 
there.

Also, I had a problem with my build that did not seem to occur in the 
executable included in the Humble Bundle:  The loadskin function in 
SkeletalSprite was converting the whole path string to lower case, 
causing it to fail for mods in my .Aquaria folder.  I modified it to 
only change the filename (not the whole path) to lower case.

- Kasoroth
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: export_patch.txt
URL: <http://icculus.org/pipermail/aquaria/attachments/20110215/cbf36ffd/attachment.txt>


More information about the aquaria mailing list