Jump to content

3dsMax Havok Import Script


Recommended Posts

In case you guys missed this, Sebbo86 has provided an 3dsMax Havok Import Script. This script helps animators to import vanilla Fallout 4 animations into 3ds Max. Optionally also the annotations can be transferred to 3ds Max Scene.

 

As your may recall, Sebbo was the one who made the mixamo animations available for us to use.

 

Edited by pepperman35
Link to comment
Share on other sites

Thanks for mentioning this, pepperman35, it looks to be quite useful!

 

Importing havok animations used to be a real pain, having to convert Fallout 4 .hkx -> 32 bit .hkx -> .hkx to FBX converter -> then import back the FBX into 3DS. :teehee: I only use Bethesda animations as references, but it's annoying how many steps it takes just to see them.

Link to comment
Share on other sites

Looks like having Java installed is mandatory? I thought the note track import which requires Java was optional, but there doesn't seem to be a way to skip that part. It just throws errors for me.

 

Since I don't want to install Java, I can't use this one. :confused:

Link to comment
Share on other sites

  • 2 months later...
It works. I was able to import hkx, save to fbx and run the animation with my rig. But... I can't export this animation back to hkx. There is a bug with hko f4ak. I don't know how to set up hct so that the exporter skips this animation.
Link to comment
Share on other sites

Hello South8028,

 

Yeah, when I wrote the post, I wasn't importing the .hkx skeleton before importing the animation. The havok max script works, I should have followed up on my post, sorry about that.

 

As for the export, are you sure you are doing the steps correctly? You might be missing a step, as this is not as simple as it looks and I don't think it's explained well anywhere. This is my workflow (you might know parts of it, but I'll just post the whole process, so that others who don't know can follow) :

 

Import (transferring .hkx animation to the CAT rig) :

 

1) Open "F4BipedCATImport.max" document in 3DS Max.

2) Import the human skeleton .hkx located at "Data\Meshes\Actors\Character\CharacterAssets\skeleton.hkx"

3) Import the desired .hkx animation.

 

The CAT rig at this point is constrained to the skeleton, meaning, the animated skeleton can drive the CAT rig, so that the just imported animation can be saved in clip manager :

 

4) Click on the triangle + arrow object called "Bip_", and go to the motion tab.

5) Save the imported animation using Clip Manager. The clip saved contains animation for the CAT rig.

6) Now close this project file, and open "F4BipedCAT.max"

 

In this "F4BipedCAT.max" project file, the skeleton is constrained to the CAT rig, so that when you animate the "Bip_xxxxx" CAT parts, that will be transferred to the skeleton. This is the actual project file you work on your own animation with.

 

7) Click on the triangle + arrow object named "Bip_" and from the Clip Manager, load the clip you just saved above.

 

Your import process is complete.

 

 

Exporting .hkx using Havok Content Tool :

 

In my experience, the quirk with HCT is that it can only reliably save to the same directory level your current 3ds Max project is in. So, before you hit "Run Configuration button, make sure you are pointing to the same directory as your max project file is located at (Root). It will throw errors otherwise. :-/

 

1) Make sure "Fallout4Rig1st.txt" or "Fallout4Rig3rd.txt" is placed in your project folder.

2) After your animation is completed, click on the "Export..." to open the Havok Content Tools File Manager.

3) In the "Configuration Set" panel, choose "AnimationExport1stPerson" or "AnimationExport3rdPerson" depending on your project.

4) In the "Configuration Set", click on "Create Skeleton" and then in the panel on the right, choose your skeleton text file by clicking on "..." button in the "From File" section.

5) In the "Configuration Set" panel, click on "Write to platform". In the panel on the right, at the top you can set the target directory, which is the same as your 3DS project file. (You need to set this every time you quit and start 3DS Max to make sure it exports to the correct directory.)

6) Click on "Run configuration" button. This will write your animation to an .hkx file. At this point you'll likely to get one warning, but you can ignore it.

7) Done!

 

I hope that helps. :smile:

Link to comment
Share on other sites

Correction : Between #4 and #5 of the import process, I think you need to collapse the animation layers before writing to the Clip Manager.

Thank you very much. In general, it worked out. But your instructions didn't work. Following the instructions, I was able to export to hkx, but nothing was exported, only an empty 1kb file. I don't know why this is happening. So I did the following... I imported hkx, edited the animation right away with biped. Exported to fbx. Opened my rig zaz. I imported fbx to it (this naturally knocked out all the control knobs from zaz, but the bones worked without problems). Removed completely the entire biped rig. In hct loaded hco f4ak, and txt with bones. exported. In the game, the animation plays without errors. Edited by South8028
Link to comment
Share on other sites

I'm not sure how your method works to be honest. Just to be on the same page, I'm using MaikCG's CAT template here :

 

https://www.nexusmods.com/fallout4/mods/16691

 

His CAT template has most things set up for the HCT exporter configurations, and it maybe that you are missing those?

 

Here's my .hkx animations exported with the above method :

 

 

My animations are done from scratch mostly, so the import stuff is just for reference, but the export process is just as I've described above.

Edited by DiodeLadder
Link to comment
Share on other sites

I'm not sure how your method works to be honest. Just to be on the same page, I'm using MaikCG's CAT template here :

 

https://www.nexusmods.com/fallout4/mods/16691

 

His CAT template has most things set up for the HCT exporter configurations, and it maybe that you are missing those?

 

Here's my .hkx animations exported with the above method :

 

https://youtu.be/kyFME07CuLo

 

My animations are done from scratch mostly, so the import stuff is just for reference, but the export process is just as I've described above.

The method works. Here is the walk animation from mixamo edited and exported with this method. The only problem is that I'm a little uncomfortable using this rig. Unusual.

https://disk.yandex.ru/d/4_kgpBGlYrp1PQ

In any case, thank you. I'm using the f4ak shadeanimator package + female and male rigs zaz zex. I used to dislike the zaz, but now I'm comfortable with it and it seems to me the most convenient in terms of control.With my own animations, the ones I made from scratch, I never had a problem exporting to hkx. The problem was with this import script, but the problem is solved.

Edited by South8028
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...