VertexAnimation/Runtime/Scripts/VA_AnimationLibrary.cs
max 21a8c4615b AssetBuilder
Removed functionality from the books.
Seperated editor and play data.
2020-12-21 23:19:05 +01:00

31 lines
739 B
C#

using System.Collections.Generic;
using UnityEngine;
namespace TAO.VertexAnimation
{
[CreateAssetMenu(fileName = "new AnimationLibrary", menuName = "VA_Animation/AnimationLibrary", order = 400)]
public class VA_AnimationLibrary : ScriptableObject
{
[SerializeField]
private List<VA_AnimationBook> animationBooks = new List<VA_AnimationBook>();
[HideInInspector]
public List<VA_AnimationData> animations = null;
public void Init()
{
animations = new List<VA_AnimationData>();
foreach (VA_AnimationBook ab in animationBooks)
{
ab.SetMaterials();
animations.AddRange(ab.playData.GetAnimations);
}
}
private void OnValidate()
{
// TODO: Check for naming conflicts in AnimationBooks.
}
}
}