Replace a player item with an NPC item
Last updated
Last updated
Created by @manavortex Published November 05 2022This tutorial will teach you how to switch a player mesh for an NPC garment and map its variants to the existing colours.We'll assume that you know how to edit mesh appearances. If you don't, check the .
Find the mesh that you want to use ("target mesh") and replace it with the one that you want to switch in ("source mesh").Example: Replacing the short-sleeved poser jacket with the monk shirt with the tied-back sleeves.
target mesh
base\characters\garment\player_equipment\torso\t2_084_jacket__short_sleeves\t2_084_pwa__short_sleeves.mesh
source mesh
base\characters\garment\gang_monk\torso\t2_135_jacket__monk_shirt\t2_135_wa_jacket__monk_shirt.mesh
1.Find both files and add them to your project.
2.Move the source mesh to the target mesh's folder.
3.Rename the target mesh (e.g. "t2_084_pwa__short_sleeves.mesh
" -> "original.mesh
").
4.Rename the source mesh to the target mesh (e.g. "t2_135_wa_jacket__monk_shirt.mesh
" -> "t2_084_pwa__short_sleeves.mesh
")
5.Open both meshes in WolvenKit
Target (original) mesh and its variants
Source (new) mesh and its variants
Now comes the annoying part: we need to find out which spawn code corresponds to which meshMeshAppearance. The process is a little tedious.
For example, the appearance "black" with the chunks pointing at pasted_ml_t2_135_wa_jacket__monk_shirt_fancy will look for:
yes
archive\base\characters\garment\gang_monk\torso\t2_135_jacket__monk_shirt\textures\ml_t2_135_wa_jacket__monk_shirt_fancy.mlsetup
no
base\characters\garment\player_equipment\torso\t2_084_jacket__short_sleeves\textures\ml_t2_135_wa_jacket__monk_shirt_fancy.mlsetup
Don't ask me how the lookup/naming works, I have no idea. Just copy it from the source mesh.The names of the meshMeshAppearance need to be taken from the target mesh - when spawning an item, the game will look for the variant "black", since that's mapped to the corresponding item code. The values in the chunkMaterials belong to the source mesh.Rename all the variants in the source mesh with those from the target mesh. Then, make sure that you can tell them apart (e.g. by giving each variant an individual appearance or colouring the mlmasks. What worked for me was using primary colours on the mlmasks, and then using each of them fully or with plastic sleeves. Your mileage may vary.)
Enjoy!Cyberpunk 2077 Modding
After you've found out which spawn code corresponds to which appearance, you can now .