Answers for "unity check if animation is not playing"

C#
1

check if animation is playing unity

if (myAnimator.GetCurrentAnimatorStateInfo(0).IsTag("Example"))
Posted by: Guest on June-13-2021
0

unity animator check if animation is playing

bool isPlaying(Animator anim, string stateName)
{
    if (anim.GetCurrentAnimatorStateInfo(animLayer).IsName(stateName) &&
            anim.GetCurrentAnimatorStateInfo(animLayer).normalizedTime < 1.0f)
        return true;
    else
        return false;
}
Posted by: Guest on September-23-2020

Code answers related to "unity check if animation is not playing"

C# Answers by Framework

Browse Popular Code Answers by Language