You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

17 lines
538 B

using Spine.Unity;
public static class SpineExtension
{
public static bool TryGetAnimation(this SkeletonAnimation skeletonAnimation, string animationName, out Spine.Animation animation)
{
var skeletonData = skeletonAnimation.skeletonDataAsset.GetSkeletonData(false);
animation = skeletonData.FindAnimation(animationName);
return animation != null;
}
public static bool IsComplete(this Spine.TrackEntry trackEntry)
{
return trackEntry.AnimationLast == trackEntry.AnimationEnd;
}
}