Add old vrcboardimage script as vrcboardimagebasic

This commit is contained in:
2024-10-22 13:40:45 +03:00
parent 9777e0225d
commit 26de34be44
14 changed files with 1454 additions and 6 deletions

View File

@@ -191,12 +191,18 @@ namespace VRCBoard.Components
OnDisable();
EditorUtility.SetDirty(script);
}
if (renderer.sharedMaterials.Length == 0)
{
EditorGUILayout.HelpBox("Material has no material slots.", MessageType.Error);
return;
}
Material material = renderer.sharedMaterials[newMaterialIndex];
if (material == null)
{
EditorGUILayout.HelpBox("No material assigned to material slot ("+newMaterialIndex+")", MessageType.Warning);
EditorGUILayout.HelpBox("No material assigned to material slot ("+newMaterialIndex+")", MessageType.Error);
return;
}