Preview loaded animations

Preview to be loaded animations in the library.
This commit is contained in:
max 2021-01-19 13:59:54 +01:00
parent c465ec6585
commit a192fed5e9
2 changed files with 51 additions and 0 deletions

View File

@ -0,0 +1,40 @@
using UnityEngine;
using UnityEditor;
namespace TAO.VertexAnimation.Editor
{
[CustomEditor(typeof(VA_AnimationLibrary))]
public class VA_AnimationLibraryEditor : UnityEditor.Editor
{
private VA_AnimationLibrary library = null;
void OnEnable()
{
library = target as VA_AnimationLibrary;
}
public override void OnInspectorGUI()
{
serializedObject.Update();
InputGUI();
EditorGUILayoutUtils.HorizontalLine(color: Color.gray);
InfoGUI();
serializedObject.ApplyModifiedProperties();
}
private void InputGUI()
{
EditorGUILayout.PropertyField(serializedObject.FindProperty("animationBooks"));
}
private void InfoGUI()
{
using (new EditorGUI.DisabledScope(disabled: true))
{
EditorGUILayout.PropertyField(serializedObject.FindProperty("loadedAnimationsPreview"));
}
}
}
}

View File

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 257147ab6c1fe224784cbb0c5db92c6c
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant: