Only trouble is I can’t see how to retrieve the Module Name from the Mod File. I have managed to read the Mod Description, but I can’t figure out how to get the offset for the Module Name.
If you have any ideas, I would be most appreciative.
It’s in the module.ifo file in the mod so you’d need to extract that and pull it from there. It’s a gff file. I use Niv’s ruby tools to convert things like that to yaml to read/modify them. The new nim based tools will do it too but since they don’t speak yaml I have not bothered to play with that much.
Probably won’t be able to use that - I need to read it from an application, but will take a look in case it helps me figure out how to find the IFO file offset from the beginning of the file.
What I would really like to do is retrieve the MOD file name by reading the SAV file.
Need to do some more research now that I have asked the correct question. However, looking at the SAV file with Leto, did not highlight the mods filename - so it may not be possible.
Still need to establish whether the MOD file name is stored in the SAV or MOD file as apposed to the name used for the SAV file. So far as I can tell, it is not held in the either file, but I could be wrong.
The module file name is not stored anywhere. The filename can be changed arbitrarily and will still work. Once saved the original file is not needed anymore.
I guess I will leave NIT’s current mechanism of linking a SAV name to the MOD file name as it is. The only other alternative would be read all the MOD files to find the save name and that is probably too much overhead.