#1
20th Sep 2014 at 1:18 AM
Last edited by justJones : 6th May 2018 at
11:24 PM.
Posts: 75
Thanks: 547 in 13 Posts
6 Achievements
Making better use of the unpackedmod folder
I guess everyone on this forum (or at least those that read the
custom content post in the official forums ) now knows about adding a line with:
Code:
DirectoryFiles unpackedmod autoupdate
to the Resource.cfg file in the mods folder in order to load unpacked resources. But using it like that would be a mess for working with more than one unpacked mod at a time.
I've found two tricks, though, that ought to bring some sanity to working with unpacked mods.
First, just like when using packed mods, it's possible to use subfolders with unpacked mods. I've changed that line in my file to:
Code:
DirectoryFiles unpackedmod\* autoupdate
And it works as expected, loading unpacked mods from subfolders inside the unpackedmod folder. I didn't test, but I expect one can add extra levels, as usual in the resource.cfg file.
The second trick is how to use actual file extensions instead of a hex representation of a 4-bytes hash; it's possible to tell the game to translate from the used extensions to the expected hash by adding lines like:
Code:
FileType 0x220557da stbl
to the resource.cfg file.
With the above two tricks I've got two small mods, the example one from Maxis and a small tweak to the Jog interaction, working correctly, with file extensions a bit more human friendly.
For reference, my current resource.cfg is:
Code:
Priority 500
PackedFile *.package
PackedFile *\*.package
DirectoryFiles unpackedmod\* autoupdate
FileType 0x220557da stbl
FileType 0x6017e896 buff
FileType 0xe882d22f interaction
FileType 0x0c772e27 action
FileType 0xb61de6b4 object
FileType 0xcb5fddc7 trait
FileType 0x545ac67a data
FileType 0x319e4f1d catdata
FileType 0xc0db5ae7 objdata