# Multilayered Material Properties

## Summary

**Created:** Jan 14 2024 by [mana vortex](mailto:undefined)\
**Last documented update:** Apr 07 2024 by [mana vortex](mailto:undefined)

This page documents multilayered shader properties.

* For an **overview** of glass shaders, see [Cheat sheet: Materials](/cyberpunk-2077-modding/for-mod-creators-theory/references-lists-and-overviews/cheat-sheet-materials.md)-> [Cheat sheet: Materials](/cyberpunk-2077-modding/for-mod-creators-theory/references-lists-and-overviews/cheat-sheet-materials.md#multilayered)
* For an **explanation** of material properties and further links, see [Material properties](/cyberpunk-2077-modding/for-mod-creators-theory/materials/configuring-materials.md)

{% hint style="warning" %}
If a layer with a greyscale mask is invisible, set MicroblendContrast in the `.mlsetup` to 1!
{% endhint %}

## Multilayered Material

For a full documentation, check the corresponding [page](/cyberpunk-2077-modding/for-mod-creators-theory/materials/multilayered.md).

To set it up, use these keys for the "values" array of your material:

|                 |                                                                                                                                                                  |
| --------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| GlobalNormal    | path\to\normal.xbm                                                                                                                                               |
| MultilayerMask  | path\to\mask.mlmask ([white file](/cyberpunk-2077-modding/for-mod-creators-theory/references-lists-and-overviews/cheat-sheet-materials.md#white-multilayermask)) |
| MultilayerSetup | path\to\material.mlsetup                                                                                                                                         |

<figure><img src="/files/dXahSznb1d2UhAdwP5jv" alt=""><figcaption><p>an example multilayered material</p></figcaption></figure>

## Material properties

### colorScale

Sets a color from within the [mltemplate](#what-is-the-mltemplate) file. Hex codes corresponds to rows and columns in substance painter.

### material

Depot path to the base material [mltemplate](#what-is-the-mltemplate) from which the surface inherits its properties (lightbreaking, subsurface scattering…).

Example values:\
`base\surfaces\materials\paint\car_paint\car_paint_metallic_01.mltemplate`\
`base\surfaces\materials\metal\enameled_hq\enameled_hq_01_30.mltemplate`

### matTile

**Scaling** (tiling multiplier) of the material across the mesh. The higher the value, the smaller it is.

### metalLevelsIn

Clamps metalness **input** levels. This value corresponds to a (generated?) greyscale texture across the entire mesh.

### metalLevelsOut

Clamps metalness **output** levels. This value corresponds to a (generated?) greyscale texture across the entire mesh.

### normalStrength

Applies or ignores the base mesh's normal map to this layer. This value can be greater than 1!

### offsetU

For logos: X-offset on the texture. Used for e.g. targeting a certain label.

### offsetV

For logos: Y-offset on the texture. Used for e.g. targeting a certain label.

### opacity

Transparency of the layer, 0 means that it isn't displayed, 1 means that it's fully visible.

### roughLevelsIn

TODO

### roughLevelsOut

Determines the roughness of a material

<figure><img src="/files/vMrkb7lIP3JDcbdY5vXz" alt=""><figcaption><p>How roughness affects a material (the colour was not changed)</p></figcaption></figure>

## Microblend properties

{% hint style="danger" %}
You can only use microblends if this layer's mask is not fully white.
{% endhint %}

### mbTile

Like [#mattile](#mattile "mention"), this determines the scaling of the microblend. The higher the value, the smaller it is.

### microblend

Depot path to the base microblend texture (xbm), a seamless pattern which will be projected on the surface. Think of an extra normal map that tiles across a layer.

### microblendContrast

A crossfade between the layer mask and the microblend mask (the black parts of the microblend texture). If you set this to >=1, then the layer will be blocked out where the microblend texture is black.

This requires the xbm's AlphaChannel (transparency) to be set up.

### microblendNormalStrength

Like [#normalstrength](#normalstrength "mention") for the microblend.

### microblendOffsetU

X-offset for the microblend texture.

### microblendOffsetV

Y-offset for the microblend texture

## multilayered\_clear\_coat.mt

Discovered and shared by [Rebecca](https://discord.com/channels/717692382849663036/1082772930892664943/1358835907905589431), thanks a tonne!

Using ClearCoat lets you put additional hues over an mlsetup:

<figure><img src="/files/zATKjCqMvgeqfly1YvAF" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/UrRbCepfg3MeRPqIaST0" alt=""><figcaption></figcaption></figure>

Please note that this uses light colour mixing!

<figure><img src="/files/VPuvgD8haegheDPzmrW5" alt=""><figcaption></figcaption></figure>

## multilayer\_blackbody\_inject.mt

Putting multilayerblackbody\_inject.mt into debugging mode allows for the addition of emissives on top of your multilayer setup. The simplest example of this is on the DLC magic rune katana.

<figure><img src="/files/ATCIqH1Kr5LjfKhPJXp0" alt=""><figcaption><p>Material Setup for Emissive Multilayer Setup</p></figcaption></figure>

<figure><img src="/files/67QpA7glUZ0wFN6jCepG" alt=""><figcaption><p>Example of Emissive on top of mlsetup<br>Emissive painted on the UV DamageTypeRGBMask</p></figcaption></figure>

Debug and MaximumTemperature are required to be 1 to stop the whole mesh from randomly flashing.

You can also use FireHSV or PoisonHSV combined with red and green layers on the mask to create three different Emissive masks on a single xbm file; however through testing it's currently assumed only one can be used at a time. However you can change the % Hue value to use any colour for the emissive.

An additional texture can be added with DamageTypeNoise. This texture can be scaled with the x/y numbers of the UV setting and scrolled with z/w numbers. More contrast can be added into the noise by increasing the value of IntensityAdd.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://wiki.redmodding.org/cyberpunk-2077-modding/for-mod-creators-theory/materials/configuring-materials/multilayered-material-properties.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
