Page 1 of 1

getting number of mods/effects and best practices...

Posted: Thu Apr 22, 2010 4:05 am
by daroou
Hi,

I was wondering if there's a way to retrieve both the number of mods and effects in a bank file once it has been loaded? I looked at the asm, and saw that there's a global containing the number of mods (forgot the name now) which I can extern easily and retrieve, but this is evil and implementation dependent. On the other hand, I didn't find anything for the number of effects (waves). Would it be possible to add functions to retrieve both of these values?

The reason I ask is that I'm thinking of organizing my game by having a single sound bank per map/section of the game, and when I load the bank, I just want to load all the modules/effects in that bank immediately. To do this, I need to know the number of mods/effects once the bank is loaded. I know that the exported header contains the number of mods, so worst case, I can just pass that in (although I would rather not). In any case, the header doesn't contain the number of effects.

Thanks for your time!

- daroou