-
-
Notifications
You must be signed in to change notification settings - Fork 4
Custom uHead model bundles
This guide is about making uHead models from scratch in the unity project, with this, you will be able to have an insane amount of control over what heads look like, with lots of tools at your disposal.
I'm going to explain the process of importing heads, making animations, making eyes work, making mouths work, and the materials and shaders. This guide is intended to be followed even if you nothing about this at all, for example if you used the template and have no idea how that works either, you can still follow this guide with no trouble. I will explain some things but know that its not necessary.
-Gradients such as Gradients_Skin, Gradients_Hair and Gradients_Eye (https://cdn.discordapp.com/attachments/1065367994886262786/1216133912481501304/CharaEye.shader?ex=65ff47f7&is=65ecd2f7&hm=3988c7e5b47c28020fa98360ee4867a330cbf8a6a38c23b3984fc9b2ed94c870&)
For this example, we're going to use Panette's head and get rid of her cat eyes to make her normal.
Search up the uHead you're going to use in the AssetTable. The names match the Japanese ones, so looking for someone like Panette would actually be Panetone.

Search up the uHead Bundle name in your dump folder.

Now we can use this special version of AssetStudio to rip this model
Make sure to press this specific option, otherwise we will not be able to get the necessary animations for the uHead. Tick all the checkboxes in the Scene Hierarchy tab.

Since we are adding a new uHead bundle to the game, we need to give the uHead a new model number (_cXX). Make sure to use one that is not already in use by the game.
Now, we can move on to the next part.
Now, make a new Unity project using the template for Engage mods and add a new head folder for the number of your choosing.
Make sure to respect casing so that the game can pick up the file.
Here is the folder hierarchy for uHeads. We're going to choose to go with uHead_c019 for this case.

Drag the FBX file into the Prefabs folder, and don't worry if it looks messed up, this is normal. We need to change some settings for the uHead, these are what the settings will be when you first import it.

We'll need to change it to this, please put what I colored red.

Navigate to the materials section, and press the following.

Navigate to the Rig tab, the settings will appear like this.

Change the setting to the image below.

We have the generic animations for the head included in the FBX, but now we'll need the specific animations for the head, as well as the things that tell them what animations are which. This part has a good amount of dragging and dropping, so make sure to be careful what you're dragging. We can use the software AssetRipper to extract these things, which can be downloaded here.
https://nightly.link/AssetRipper/AssetRipper/workflows/publish/master/AssetRipper_win_x64.zip (Windows) https://nightly.link/AssetRipper/AssetRipper/workflows/publish/master/AssetRipper_mac_x64.zip (Mac) https://nightly.link/AssetRipper/AssetRipper/workflows/publish/master/AssetRipper_linux_x64.zip (Linux)
When opened, it should look like this.
Make sure to follow these steps

We need to change the version for AssetRipper which can be done here. (Do not worry about the "Static Mesh Separation" checkbox.)

Now click Save, and go to Open File.

Lets go back to where we copied our bundle to, and select the Bundle.

Click on view loaded files.

Select Export all files.

Put the output to our Animations Folder.

Your output folder should look like this.

Now we have our Animation controllers, Override Controllers, and animations for the face at our disposal.

Drag The AC_Face and AC_Face.meta Controllers to the project tab here.

Do the same with AOC_Facial_c453.overrideController and AOC_Facial_c453.overrideController.meta

Now, go to AnimationClip, drag all of the animations to the project tab here. (If you do not have the 000 animations included within the previously imported head fbx, then you should import all of the animations. Otherwise, you would leave out the 000 animations, and use the ones within the head fbx instead.)

Drag the uHead_c453Avatar.asset and uHead_c453Avatar.asset.meta files to the project tab here.

The Folder should look like this.

If you opened the FBX, it should look like this instead.

We need to get the model looking little closer to the base game so we can see the animations better. The materials need to be properly assigned; they need to have these shaders. Drag the Albedo and Multi into your Materials folder.




Please reference the images below for the Materials. The Albedo and Multi will differ if you use a head other than Panette's, since everyone has a unique Texture.

If you changed the uHead materials to use the Albedo and Multi, and/or the correct settings above, then the shader will automatically set the textures for your head to be viewed in the Inspector Tab.

Double click on AC_Face, and make sure you are in 'Base Layer'

We need to drag the 000 animations (underlined in red) to their matching entry (underlined in blue). They need to correspond to the naming. There is one exception to this, the "Beaten" entry should use the "Pain" Animation.

Now that we've matched them all, we need to go to the LipA layer, and select the corresponding animation for it. Click on the LipA layer

Now do the same for LipI, LipU, LipE, and LipO

Now that we assigned the 000 Animations, we need to select the Animations that the face has for its own. click on AOC_Facial_c453

We now have to match each animation, with the animations we pulled from AssetRipper.

It should look like this.

Drag your uHead in the Scene

Drag the avatar you extracted with assetripper and assign it to the uHead in the scene, and drag AOC_Facial_c453 to the Controller tab, then click Apply Root Motion.

If you've done these steps correctly, you can check if the Transforms are correct by selecting an animation that is not c000 (In our case, it's c453) and dragging the object from the scene to it.


Drag EventCharacterMouthController from the bridge folder in the code Folder from Cobalt onto to uHead in the Scene like this:

Drag LookAtIKRotationLimit_Bridge from the bridge folder in the code Folder from Cobalt onto the uHead in the Scene like this:

Drag LookAtIK from the RootMotion folder in the code Folder from Cobalt onto the uHead in the Scene like this:

The object selected in the scene should look like this:

Now we'll need to add the eye scripts to the eyes, and adjust the settings.
Go here in the uHead object from the scene:

Change this value from 0 to 2.
Now, navigate to the scene hierarchy, and go here

Drag them to to Eyes, and put l_eyeball_jnt into element 0, and r_eyeball_jnt eyeball into element 1
like this

Now drag the uHead scene object here like above.
Your uHead in the scene's settings should look like this.

Now we have to tweak the settings. The following image is an example of how this specific uHead's values look. You can use UABE to determine what the values of another uHead should be if necessary.

Now that the settings are complete, we're right at the finish line! Drag the uHead from the scene into the project tab like this.

Select Original Prefab
Use UABE to extract the material values from the original head, in order to determine how you should setup your material values in Unity.
Make certain that the eye highlight materials' "Color White" field is set to 1,1,1,1 (Fully White), regardless of what the extracted material values say, or else they will look incorrect ingame.
To know more about making Custom Bundles to be used in game, please refer to https://github.com/DivineDragonFanClub/Lythos/wiki/Custom-models-(Unity)
Pat yourself on the back, you completed the guide!


- Introduction
- Troubleshooting
- Modding features
- Guides
- Divine Dragon Fan Club - Complementary resources & guides
- Custom model bundles
- Spring Bones (physics)
- Appendix