Prevent material modification if vertex colors are present.

This commit is contained in:
kovacsv 2021-12-29 09:50:31 +01:00
parent df5ad1e6be
commit 6a022775a4

View File

@ -67,7 +67,7 @@ OV.ThreeModelLoader = class
ReplaceDefaultMaterialColor (defaultColor)
{
if (this.defaultMaterial !== null) {
if (this.defaultMaterial !== null && !this.defaultMaterial.vertexColors) {
this.defaultMaterial.color = OV.ConvertColorToThreeColor (defaultColor);
}
}