From 6c065e9109980c12a097b6ab2afd4a95d90703cf Mon Sep 17 00:00:00 2001 From: ousttrue Date: Tue, 27 Mar 2018 21:16:59 +0900 Subject: [PATCH] check duplicate BlendShapeKey --- Scripts/BlendShape/Editor/VRMBlnedShapeProxyEditor.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Scripts/BlendShape/Editor/VRMBlnedShapeProxyEditor.cs b/Scripts/BlendShape/Editor/VRMBlnedShapeProxyEditor.cs index 9ed7cd655..6706ddc6c 100644 --- a/Scripts/BlendShape/Editor/VRMBlnedShapeProxyEditor.cs +++ b/Scripts/BlendShape/Editor/VRMBlnedShapeProxyEditor.cs @@ -264,6 +264,12 @@ namespace VRM EditorGUILayout.Space(); EditorGUILayout.LabelField("CurrentClip", EditorStyles.boldLabel); + var key = BlendShapeKey.CreateFrom(CurrentClip); + if(m_target.BlendShapeAvatar.Clips.Where(x => key.Match(x)).Count() > 1) + { + EditorGUILayout.HelpBox("duplicate clip", MessageType.Error); + } + /*var loadClip = (BlendShapeClip)*/ GUI.enabled = false; EditorGUILayout.ObjectField("Current clip",