Changing materials, colors and textures
Changing how an item looks in-game
Summary
Created by @manavortex Published November 05 2022
This guide will teach you how to change an item's appearance by editing its MultilayerSetup (*.mlsetup file), how to rename materials, and how add your own mlsetups (custompathing).
For a step-by-step walkthrough for a recolour of the Netrunner suit, check R&R: Colour Editing
If you want to edit emissive (glowing) material, check R&R: Emissive -> Changing the presets
It uses the following versions:
MLSetupBuilder >= 1.6.7 (get the latest release)
For an overview of base materials and example files, you can check here.
If your changes do not become active, you will want to install Material and Texture Override from Nexus.
Video guide
Please keep in mind that video guides might be outdated, as they are much more difficult to update than a wiki page. Refer to the written guide below if you run into any troubles!
Step 1: Finding your item
We will use the female variant of the puffy vest (as I've already mapped and documented it):
base\characters\garment\player_equipment\torso\t2_002_vest__puffy\t2_002_pwa_vest__puffy.mesh
Add the item to your project and open it in WolvenKit. You want the original to look up material names, even if you overwrite it with your own mesh.
Step 2: Finding the correct appearance
We will change the appearance bwstripes
, which is used by Vest_17_basic_01
:

This vest has only one chunkMask, so there's only one material.
Remember its name (ml_t2_002_ma_vest__puffy_bwstripes
) and find the corresponding material definition:
Most meshes have their materials under localMaterialBuffer/materials
. However, some of them (especially those with physics) use preloadLocalMaterialInstances
instead.

You will (hopefully) see a material with three entries in values
(order doesn't matter):
MultilayerSetup
base\characters\garment\citizen_casual\torso\t2_002_vest__puffy\textures\ml_t2_002_ma_vest__puffy_bwstripes.mlsetup
MultilayerMask
base\characters\garment\citizen_casual\torso\t2_002_vest__puffy\textures\ml_t2_002_ma_vest__puffy_default.mlmask
GlobalNormal
base\characters\garment\citizen_casual\torso\t2_002_vest__puffy\textures\t2_002_ma_vest__puffy_n01.xbm
For the purpose of this guide, all that matters is the mlsetup, which determines all the individual material assignments in this CMaterial. For an explanation of the shader, check here.

Most materials in Cyberpunk use the engine\materials\multilayered.mt
material and assign colours via an .mlsetup file. If you're used to textures, you are probably going to hate this. As somebody who has been where you are: the mlsetup system is cool. Genuinely. Give it a chance!
multilayered material
If you would rather use a textured material, check here.
A multilayered material consists of multiple layers of materials, projected on the mesh through the mlmask: white parts get affected, black parts are blocked out. (Again, for a full explanation, check here).

Exporting the .mlsetup
We're going to edit the mlsetup file and then import it back, causing a global change in the appearances of every item which uses this particular material file. (If you don't want that, see Custompathing below).
We do that by editing the MultilayerSetup. Check the MLSetupBuilder wiki page for how to do that.
Find the file that you want to edit in the Asset Browser.
Add it to your Wolvenkit project.
In the project explorer under Wolvenkit's
archive
folder, right-click on ammlsetup
file This folder will only be visible in the "source" or "archive" tab of your project explorerSelect "Convert to JSON"
Step 3: Editing the .mlsetup file
Optional: If you don't see an
mlsetup.json
in your project, switch the Project Explorer tosource
orraw
.Right-click on the file and open it in MLSetupBuilder.
For a documentation of multilayer properties, see here. For a list of reference images, check Multilayered: Previews
Export the file, overwriting the original
.mlsetup.json
Switch back to Wolvenkit
Right-click on the
.mlsetup.json
and import it from json.
This is already working. You can pack the project and see it in action!

Step 4 (optional): Custompathing
If you want to put up your own .mlsetup, rather than overwriting the original one, you can do that. All you have to do is changing the DepotPaths to the relative path of your mlsetup.

Keep your folder and file names unique! If you have two mods adding a file at the same location, the second one will be unable to overwrite it and will use the first mod's file. That is, unless your mods are in REDmod format, which will be loaded even later and in order of their folder names.
Understood? No? That's fine. Just keep it unique. :D
Step 5 (optional): Renaming materials
You can rename a material by changing the "name" property inside the CMeshMaterialEntry
in the materials
array:

Inside the appearances block, the material assignment to the individual submeshes happens by name, so don't forget to change the chunkMaterial
names!
Step 6 (optional): adding new materials
To add a new material to a mesh, you need to create two entries. The first of those needs to be in the materialEntries array:

Now, add an entry in the localMaterialBuffer.

You can now use your new material just like the regular, old materials.
Last updated