Importing JSON Animations With Wolven kit - dingdio/witcher3-maya-animation GitHub Wiki

Download Necessary Files

As the tools are still being developed you must use this custom version of Wolven-kit: Mega Folder

Download the example wolven-kit project: Mega Folder

Adding AnimationSet to game

Add your new exported json animations to a folder as part of DLC. Right click on the folder and press "Create w2anims" This will create a new animation set with all the animations inside the folder.

Playing Aniamtion

To see the animation inside the game you need to add the animation set to the entity that is going to be using it. For the player that is the player.w2ent file. Check the "npc_entities" in Wolven-kit's asset browser folders to add it to NPCs. Look at the this screenshot to see what needs to be added:

Have the Witcher 3 Debug Console enabled. (Add "DBGConsoleOn=true" to bin/config/base/general.ini before you start the game.) and download Debug console extensions https://www.nexusmods.com/witcher3/mods/601 Once in the game you can now open the console and type "forceanim("my_new_anim")" and the animation will play on Geralt.

Editing SwordCombat script

You can make the animation play as an attack animation by replacing values in swordcombat.ws

To actually have good combat animations you need a CLineMotionExtraction2 component and various animation events. The CLineMotionExtraction2 is an array of frames that describe the location the entity will be at during the animation. The motion is extracted from the "trajectory" bone. I've included an example attack called "seph_B_AtkSenkou02" in the sample Wolven-kit project. The serialization of animation events from json files has not been fully tested yet so be sure to check them inside Wolven-kit. Of course you can use Wolven-kit to add these events too.

Result:

Sephiroth Attack