Best practices for structuring DAZ projects for game character export?
I'm working on a game and right now I have a crude asset pipeline where I prepare a character, add outfit combinations, decimate and texture atlas, export as FBX, combine with other FBX files to consolidate animations, and then convert to my game engine's native formats. It works, but it's very tedious, error-prone, and any time I want to make a change to the character I have to repeat the entire process since the character and all outfits are in a single DAZ project file.
I've been thinking a bit about how the process might be improved and here's what I've come up with so far:
- Create and save Character Preset/Scene Subset/(Support Asset?) of base character
- Create decimation/atlas for that character and save as another preset/subset
- Using files created in steps 1 and 2, create one DAZ project per character-outfit combination and decimate/atlas each outfit to fit the character's decimated form
- Export the base character to FBX
- Export the base character performing each individual animation to FBX
- Export each character-outfit combination to FBX
- Using my own tools, aggregate all the animation FBX files into the base character export, and then extract each outfit combination so that we have a base character and separate, individual outfits all sharing the same rig and animations
There are a lot of things I like about this scheme, in particular that it's easy to add or modify new animations and outfits since each is its own file. Reconciling and extracting the components of each outfit is also easier since the only commonality is the base character (which could be automatically detected and pruned). The biggest downside is that if I want to update the base character, I will potentially have to update dozens of files with the new character.
In my research thus far, I've seen support assets come up as a potential solution to this problem, since only one copy of those assets is saved instead of a copy per project and changes to the base character would propagate to each respective file when it is next opened. Is this true?
It would also be really nice to be able to automate the whole export process so that I don't have to manually load and export every character-outfit combination any time there's a change. I'm looking through the command line arguments and it seems like it might be possible to have DAZ run a script on startup which does this. Even better is the potential to use DzProcess to invoke other command-line tools to do the FBX animation consolidation and format conversion after export, completely removing those manual steps.
Am I on the right track, or are there even better ways to accomplish this?
