HOW-TO: Use CSV files for animations

If you create a new animation with a name that has never been used before, you HAVE to add it to a csv.

CSV are stored in the gameplay\globals folder.

Please note that base game has seperate gameplay\globals folder straight in the depot, HOWEVER all DLC’s are separated from the base game in folder dlc. For example the globals folder for Blood and Wine will be located in dlc\bob\data\gameplay\globals\

CSV files are very fragile. One mistake can cause all characters in the game to T-pose. Never add more lines in the CSV than you need. After saving the file, close the CSV editor and open it again to make sure that nothing broke. It happened more times than any animator can count during W3 production.

Types and names of csv used in animation:

  • animations.csv - contains list of all animations sets

  • scene_body_animationcs.csv - contains list of all unique body animation names that were added to body animsets

  • scene_mimics_animation.csv - contains list of all unique facial animation names that were added to body animsets

Names of those csv might be hardcoded in to the engine so it’s best to stick to those when creating new content.


Table of contents:


Adding new animation set to CSV

All animset names are stored in gameplay\globals\animations.csv

To add new animset you have to add a new line to the csv, provide

  • friendlyName - friendly name of the animset (this is how it will be listed in scene editor)

  • animsetDepotPath - path to that animset

b5366c51-f05b-4a4e-a945-2c258373dbe9.png

Adding new body animation name to CSV

You can find examples of properly filled CSV, go to gameplay\globals\scene_body_animations.csv.

  • Status - status part of the idle name, start the name with a capital letter (fill that field once and keep all anims with the same status right below)

    • For generic animations: high or low

    • Character specific animations: name of the character

    • Quest specific: number of the quest

  • Emotional state - emotional state part of the idle name, start the name with a capital letter (fill that field once and keep all anims with the same status right below)

    • for example: aggressive, determined, devastated, happy, sad, proud

  • Pose - pose part of the idle name, start the name with a capital letter. If the pose is made of more than 1 word, black spaces are acceptable (fill that field once and keep all anims with the same status right below)

    • for example: standing, kneeling, sitting

  • Friendly Name - name that will be visible in the scene editor (I think). Has to be provided for all animations. Examples of friendly names:

    • idle - for ALL idles

    • to: status pose emotionalState - for all transitions (ex. to: High Standing Determined)

    • anything really - for all gestures

  • Animation name - full animation name. Has to be provided for all animations

  • Animation type - can be an: Idle, Enter, Exit, Move, Gesture, Transition. Has to be provided for all animations

  • Transition - provide status, emotional state, and pose to which this transition is happening. Separate those words with a comma and space, and start each name with a capital letter. Fill that only for transitions

  • Look ats - provide the name of the lookat that should be used with this pose. Usually there are 2 lookats so seperate them with a comma. Fill that only for idle

  • Tags - tags are used by scene generator. It will only try to use animations that has a tag in csv. Those tags can be: Talk, Shout, Listen, Question, Add. You can provide more than one just seperate them with a comma and space. Fill that only for animations that you think scene generator should use.

  • Dialog generator - animation speed - range of speed the generator can set for animation. Most of the time set to 0.72-1.0

  • Dialog generator - animation weight - range of weight the generator can set for animation. Most of the time set to 0.4-1.0

8d1b441a-bded-4e04-ac57-c20e5817f239.png
Examples of idles and gestures (click to enlarge)

Adding new facial animation name to CSV

  • ActionType - type of animation (fill that field once and keep all anims with the same action type right below)

    • Question - gestures that are questions

    • Blinks - all additive blinking animations

    • Yes - all yes gestures

    • No - all no gestures

    • Point - head points

    • Shout - shouting gestures

    • AccentsBrow - additive brow animations

    • AccentHead - additive head animations

    • Reactions - reaction gestures

    • Special - any gesture that didn’t fall under any other category

    • Idle - for the idle animation (without the eye animation and emotional pose)

    • Eyes - for the idle eye animation

    • Pose - for the idle pose

  • Friedly name - (for gestures) friendly name should start with 1 word that determines what type of gesture it is. Has to be provided for all animations.

  • Animation name - full animation name. Has to be provided for all animations

  • Type - can be an: Idle or Gesture. Has to be provided for all animations

  • Layer name - can be Animation, Eyes or Pose. Fill that only for Idle, Eyes and Pose animations entries

  • Generator Tags - ags are used by scene generator. It will only try to use animations that has a tag in csv. Those tags can be: Accent, Shout, Question. You can provide more than one just seperate them with a comma and space. Fill that only for animations that you think scene generator should use.

  • AnimStretch - range of stretch the generator can set for animation. Most of the time set to 0.72-1.0

  • AnimWeight - range of weight the generator can set for animation. Most of the time set to 0.5-1.0


Adding new emotional state to CSV

Emotional states are idles that scene designers can see and use. In this CSV, we tell the engine what emotional state should be made out of, meaning which eye animation, pose, and the animation of the rest of the face should be used together to create a facial idle.

  • Emotional State - name visible in scene editor

  • Layer Eyes - friendly name (from scene_mimics_animations.csv) of eye layer

  • Layer Pose - friendly name (from scene_mimics_animations.csv) of pose layer

  • Layer Animation - friendly name (from scene_mimics_animations.csv) of animation layer


______________________________________
The Witcher 3: Wild Hunt Complete Edition © 2024 CD PROJEKT S.A. Published by CD PROJEKT S.A. Developed by CD PROJEKT RED. CD PROJEKT®, The Witcher®, REDengine® are registered trademarks of CD PROJEKT Capital Group. All rights reserved. The Witcher game is set in the universe created by Andrzej Sapkowski in his series of books. All rights reserved.