VERTEX_COLOR_IS_INCLUDED check MeshRenderer

This commit is contained in:
ousttrue 2020-10-01 11:49:37 +09:00
parent b4f4a4a6f5
commit 718e3253c7

View File

@ -321,7 +321,7 @@ namespace VRM
yield return Validation.Error(Msg(VRMExporterWizardMessages.NEEDS_VRM_BLENDSHAPE_PROXY));
}
var vertexColor = ExportRoot.GetComponentsInChildren<SkinnedMeshRenderer>().Any(x => x.sharedMesh.colors.Length > 0);
var vertexColor = ExportRoot.GetComponentsInChildren<Renderer>().Select(r => GetMesh(r)).Any(x => x != null && x.colors.Length > 0);
if (vertexColor)
{
yield return Validation.Warning(Msg(VRMExporterWizardMessages.VERTEX_COLOR_IS_INCLUDED));