Between more recent versions of Starfield-capable NIFSkope generating the material ID checksum automagically (like in the custom fork here) and BGS finally packing the material files discretely in the newly added SFBGS007 - Main.ba2 file, I think this tool is no longer needed. Now all we need is someone to make a material reader/writer app so we don't have to manually poke around their json structures.
The update also shipped all materials in .mat format. I am not sure if this was a mistake by Bethesda, or if it was intentional in preparation for the official mod support, but right now the loose materials can simply be extracted from the BA2s with baunpack (from ce2utils or fo76utils), BAE, or any other tool for managing archives.
"SFBGS007 - Main.ba2" contains 48692 materials while ce2utils/mat_info reports 48863 materials inside "Starfield - Materials.ba2", free materials list has no materials/citymaps/* and materials/unknown/* (I beleive the latter is not used, there are many test materials). Still, this is confusing, something has changed and Starfield Material Exporter no longer works.
I am not familiar with the source code of Starfield Material Exporter, but I suspect the reason it no longer works might be that the BSComponentDB2::DBFileIndex::ObjectInfo structure has a new BSResource::ID field for the parent object since the 1.11.33 beta. I already updated my tools for this change.
The "citymaps" materials are from SFBGS008, that is likely why they are missing from the archive. It looks like these new features have been developed as Creations (the rover will apparently also be one as SFBGS003), so they could have been made by different people.
Material paths under materials/unknown/ are not official, they are used by mat_info for directory names I could not crack. Since they exist in the data only as CRC32 hashes, I have to guess the strings that produce those hashes, and when I cannot figure out the correct path, I generate one in the format materials/unknown/XXXXXXXX/ (where the Xs could be any letters) that hashes to the same CRC.
OK, so I select Materials.ba2 to open but nothing happens. Is it suposed to open with a list of materials in the file? If I drag a nif in there it does show me the mat's used, but dragging the materials.ba2 nothing happens.
Not to take anything away from Maxie, it's awesome tool !! Just a heads up that ce2utils was updated as well and its "mat_info" can now dump mat names as list, or .mat files as JSON files (same as Maxie's tool), it has built in mat browser & viewer, and so on. All that also for NIFs. Viewer/render options for WRLD/location, etc. So I believe that ce2utils is must have for anyone working with NIFs, MATs, CELLs, PKINs, and all that.
Link is in Maxie's description but here it goes as well for convenience:
Now we're talkin'! And since the .mat files are just jsons under the hood, I imagine it'll be a simple affair for someone to make a more general-user-friendly app for handling them.
I dont understand something else now. Lets say I create my custom mat. And it points to a material on my PC, and textures on my PC. When I upload a mod with my custom material, does other person need to have that material or what?
22 comments
The "citymaps" materials are from SFBGS008, that is likely why they are missing from the archive. It looks like these new features have been developed as Creations (the rover will apparently also be one as SFBGS003), so they could have been made by different people.
Material paths under materials/unknown/ are not official, they are used by mat_info for directory names I could not crack. Since they exist in the data only as CRC32 hashes, I have to guess the strings that produce those hashes, and when I cannot figure out the correct path, I generate one in the format materials/unknown/XXXXXXXX/ (where the Xs could be any letters) that hashes to the same CRC.
If I drag a nif in there it does show me the mat's used, but dragging the materials.ba2 nothing happens.
Link is in Maxie's description but here it goes as well for convenience:
https://github.com/fo76utils/ce2utils
https://www.nexusmods.com/starfield/mods/7280
Cheers!
Endorsed.