This section will now continue on with the CRYENGINE portion of getting your assets in from either the 3dsMax or Maya pipeline. Within this document we will explain how to add a new character into the engine using the Character Tool.
This tutorial may rely on the GameSDK Sample Project. We recommend that you download this from the Asset Database, import it into your Launcher, start it from there and then create a new level.
See this page to find out how to import a project to your Launcher. (The default folder for the GameSDK Sample Project when downloaded is C:\Program Files (x86)\Crytek\CRYENGINE Launcher\Crytek\gamesdk_<XXX>\GameSDK
)
Open the Sandbox Editor from your Launcher.
Open the Character Tool:
The screenshot below shows the left pane split into two vertical layouts, this is activated using the icon highlighted by the red arrow and provides two viewing filters. You might want to set the lower pane to the filter "Animation" in the course of this tutorial.
Create a new *.CDF file and give the CRYENGINE character a nice appropriate name:
Assign your exported skeleton *.CHR file in the skeleton section. The yellow warning boxes will help you fix what is missing to get a correct CRYENGINE character.
Add a skin attachment to the skeleton *.CHR file.
By default the Character Tool will add a "Joint Attachment", change this to a "Skin Attachment" and browse for the *.CHR file you have exported earlier.
This will be the current configuration of the character. Now assign the material you have exported. We will fix the black shaded material for the head in the last step. This is because we assigned it a dx11Shader in Maya, which CRYENGINE doesn't support.
The Character Tool is missing the location of the animations (and more). A *.CHRPARAMS file will handle this. To create a new *.CHRPARAMS for this character, click on the Skeleton field - this is the area marked in red (screenshot above) and that is loaded with the *.CHR.
Add an "Animation Set Filter" and point to the directory of your exported "default.i_caf" animation file! The *.I_CAF file is an intermediate format before compression. If you wish, you can add a new "Animation Events" after this step to get rid of the yellow warning box - just select the animation folder of the *.I_CAF.
Browse the directory containing the *.I_CAF file(s):
On the left you will find the associated animations with the skeleton *.CHR.
Select the "default" animation from the left pane. You now need to add a new *.ANIMSETTINGS file and save it:
In order for the the Character Tool to update your blendshape animation go to the left pane - switch by double-clicking LMB on any existing *.CDF and then go back to this tutorial's *.CDF that you created. (You might need to exit and restart the Sandbox Editor and then go back to the Character Tool).
Browse the left pane for the saved character (sdk_blendshape_tutorial.cdf ). Select and double-click "default" animation from the bottom left (or press spacebar). You should see both the skeletal animation of the head/neck joint AND the blendshape animation playing as well:
Tip: Check for the red marked areas (screenshot above). The options identified will help you inspect the scene you have created.
You may also want to correct the "sdk_player_head" material. Open the Material Editor from the Sandbox Editor and edit the material to something more useful:
The Character Tool window will update the changes made.
To conclude this tutorial, here is a list of the files you created in Maya and exported to CRYENGINE: (replace the file name if you chose to use different names):
In the CRYENGINE Character Tool you edited/created the following files (either by yourself or automatically by the CRYENGINE Character Tool):
As a follow-up to this blendshape tutorial we will continue with a wrinkle map setup which will add more detail: Tutorial - Wrinkle Map Setup.
More advanced information regarding blendshape animation inside CRYENGINE can be found below - these are mostly used for debugging purposes.
Non-rigid deformation requires tangent updates in order to obtain the correct shading. Geometric real-time tangent updates are expensive, so in order to minimize CPU cost we use vertex colors to transfer a blue (0,0,255) painted mask inside Maya that marks the most important facial parts. The budget for XBox One was ~2K vertices.
Tangent updates only work with 8 weights skinning and software skinning (Flags=8) in the *.cdf file.
To enable/disable/preview the triangles marked by the mask in the ENGINE use the following CVars: