I got an very simple issue on Unity Animator Play. It seems to be Unity Animator go through automatically only pre defined “Animation States”. But my issue from to try to play specific AnimationClip on MonoBehaviour script in game realtime. Is there a way to handle Animator.play on Mono like next pseudo codes?
ex)
void LateUdpate()
{
Animator anim = GetComponent();
if (Input.GetKeyDown(KeyCode.P))
{
// I want to handling AnimationCilp “Jump” here. But next code not working.
anim.Play(“Jump”, 0, 1.0f);
}
}
Any advises are welcome. Thanks.