Exporting Character Animation assets involves a bit more steps than exporting animated hard body geometry data.
This startup guide will make it easier for you to export character animation data. It is recommended to follow the following sequence of steps when exporting character animation.
With the release of SDK 3.3.0, Character animations are mapped in a single XML format text file called .chrparams file (this file is a combination of the .cal, .setup and .ik files). CAL and IK files will not be supported anymore with the new and following releases of 3.3.0.
If your build is either 3.3.0 or higher, you can click here to read the latest documentation that explains the setup using .chrparams file.
If you are exporting character animation for the first time, following the 4C steps helps you avoid any mistakes and makes it simple to get your custom made animation in game. The chr and cba setup is required only once per character.
Before exporting a character's skeleton animation, make sure you have exported the character's chr. This .chr file will be used as a reference during the exporting process.
If your character is composed of multiple .chr files, you can use any skeleton as a reference for the animation. For the SDK Character, we use the skeleton_character.chr as the reference model.
For more information, please refer to DCC Setup (animated) documentation.
Make sure your .chr file is exported properly and facing Y-positive in The Character Editor.
If you notice any anomalies here, you should debug and re-export your chr before you proceed to the next step.
Once you have exported your .chr file and previewed it in the Character Editor that it conforms to all the rules, you can add the reference to your .chr file in the Animations.cba (Resource Compiler Settings) file.
For more information on Animations.cba file, please refer to The CBA File documentation.
If the character's animation you are exporting has same skeleton to another character that has already been defined in the Animations.cba file, you don't need to add a new entry in that case. Just export your animation to the corresponding character's animation path.
However, if your character is a new character, you need to add an animation definition for your character.
Animations.cba file is located in Game\Animations folder.
Here is what a sample animation definition looks like:
After adding an entry in the Animations.cba file, you are now ready to export your character animation.
For more information on exporting animation assets from your respective DCC tool, please refer to the documentation links below:
Make sure you export your animation to the animation path you specified in the Animations.cba file. You can nest the animation into several folders further but the root folder has to be the one specified in animation path.
Once you have exported your animations, you need to add an entry for your caf files in the .cal (Character Animation List) file.
A .cal file can be easily created using a notepad. It has to have the same name as the .chr file you want to associate it with.
Please refer to the documentation for more information.
Here is how your sample entry in a cal file would look like:
You can also use wildcards to avoid adding each animation entry manually:
Great! You have completed 4C step to export your new character animation to CE3. You can now open the Character Editor and preview the animation.
Once you are satisfied, you can check in (if you are using Perforce) your animation asset and ready to test it in game.