Merging SkeletalMesh(SK) is where you merge a specific mesh into an already existing SK without changing its original structure or materials.
For example, a hat on top of a character, while keeping everything in its original state.
This process is similar to SK swap but a bit shorter.
We will need Blender, and a Blender PSK-plugin to be able to import the .psk
files which are exported from FModel/UModel.
Blender is free and available on Blender website or on Steam page (Blender).
The plugin link: io_scene_psk_psa.
(download the correct version, and follow the instructions in that repo readme)
For this example, I will be attaching a duck model onto a spider-mech in a game called AtomicHeart (ue4.27).
Using the PSK plugin, import the model without scaling.
Blender 4: File->Import->PSK (scale 1).
Blender 3: Using the dropdown menu.
Rename the root object to Armature
(Important!).
Import the new mesh, and align it to suit your model, scale and rotation-wise.
Before you merge, ensure the UV Map names are identical, otherwise the materials will be messed up.
- Select the original mesh, go to UV Maps, and copy the name of the first UV map, usually, it's
UV_SINGLE
. - Select the new mesh, and go to UV Maps (as shown in the image below).
- Rename the UV Map to match the original mesh UV map name, which in this case is
UV_SINGLE
.
- Select the new mesh.
- Select the original mesh.
- Click Ctrl+J to merge
- Select the mesh.
- Go to Weight-Paint mode.
- Pick a Vertex Group(also known as a bone), that would be logical for the new mesh to be attached to.
- While the bone is selected, completely paint the new mesh in red.
This will make the new mesh to follow the bone in animations like it's attached to it.
Note:
If it's a hat, the logical bone will be the head
bone, if it's a backpack then the spine_03
bone, etc...
For this example, the new mesh should be "attached" to the Pelvis, so I've selected the pelvis bone and completely painted the new mesh part in red.
Before you export:
- Change to Pose mode, and move the bones to see if the new merged mesh follows the correct bones.
- Check the textures work.
- Materials are in order (first the original mesh, then followed by your custom ones).
Export into .fbx
with 0.01
scale.
- Create the same folder structure as in the game files, of where the SK is located.
- Drag and drop the exported FBX file into the UE content browser, and click Import All.
The next step is naming and placing the Skeleton and PhysicsAsset in their original folders.
- Using FModel, open the SK and look for the full paths of the Skeleton and PhysicsAsset.
- In UnrealEngine, create those folders.
- Name the Skeleton and the PhysicsAsset the same as shown in FModel.
- Move the two into their corresponding folders (if needed).
Now the same goes with the default materials of the mesh.
- Using FModel, double-check the auto-generated materials are named correctly by opening the SK asset and looking at the used materials.
- Move them to their original folders (create those folders if missing).
The last step is making sure the newly merged mesh looks as expected.
Import the textures you need for the mesh and adjust the materials.
Only pack the modified SK and the used materials and textures for the new mesh part (not the original/replicated ones).
DON'T pack the skeleton, physicsAsset, shadowPhysics(if any), or any of the replicated materials.
UE4 -> using UnrealPak (or by assigning chunks). UE5 -> chunk assigning (unless the game has no IOStore).
For more information about how to package your mod, view Cooking Content guide.
(don't forget to name your mod with _P
in its name)
The mod was showcased in this video at 10:50 mark.
Atomic Heart but ruined by mods 4