# Migrating project from 5.1 to 5.3 causes random materials to be assigned to Nanite meshes

**URL:** <https://forums.unrealengine.com/t/migrating-project-from-5-1-to-5-3-causes-random-materials-to-be-assigned-to-nanite-meshes/1339281>\
**Category:** Issues and Bug Reporting\
**Tags:** unreal-engine, question\
**Created:** [October 20, 2023, 11:50pm UTC](https://forums.unrealengine.com/t/migrating-project-from-5-1-to-5-3-causes-random-materials-to-be-assigned-to-nanite-meshes/1339281 "2023-10-20T23:50:27Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![zlyles](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@zlyles](https://forums.unrealengine.com/u/zlyles)\
**Post date:** [October 20, 2023, 11:50pm UTC](https://forums.unrealengine.com/t/migrating-project-from-5-1-to-5-3-causes-random-materials-to-be-assigned-to-nanite-meshes/1339281/1 "2023-10-20T23:50:27Z")

</div>

I have recently migrated my project from 5.1 to 5.3 and noticed an issue with materials. When using a skylight in my level, all of my nanite meshes are displaying random materials. Every time I make changes to my skylight or run the game, every nanite mesh in my level will display a new random material. Examples below:

 ![correct.PNG](https://d3kjluh73b9h9o.cloudfront.net/original/4X/d/9/0/d9010d2ad7c66a73a1cc033b2537142e566927c0.jpeg)  
 ![random materials example](https://d3kjluh73b9h9o.cloudfront.net/original/4X/c/1/3/c138c7ec01fae8637879c50fe565beb4a9c688e5.jpeg)  
 ![random materials 2.PNG](https://d3kjluh73b9h9o.cloudfront.net/original/4X/5/b/3/5b374c9b22ab36ac31b87512cd096a74cf704edb.jpeg)  
 ![random materials 3.PNG](https://d3kjluh73b9h9o.cloudfront.net/original/4X/b/7/5/b75f82bb0db0e14d875501165a2cf47660dde356.jpeg)

Interestingly, if I delete the skylight the issue is fixed when I run the game, but not fixed in the viewport. If I want to fix the materials in the viewport, I need to select each piece of nanite geometry holding ‘shift’ for some reason. However, this is not a great workaround since I need skylights.

Any help is appreciated!

A few things I’ve already tried:

- Updating Nvidia drivers
- Recompiling all shaders
- Migrating my project to 5.2 and then to 5.3

Specs:  
Intel Core i7-10700KF 3.80GHz  
Nvidia RTX 3080  
32 GB RAM  
2 TB SSD  
Windows 10

EDIT: Seems like this is probably related to this bug [UE-116954](https://issues.unrealengine.com/issue/UE-116954) which seems like it’s been an issue since 5.0 Early Access… You can fix the issue by setting your skylight to ‘moveable’, but this would likely have performance costs, right?
