how to play 2d animation in unity c# code example Example: play animation through script unity animator.Play("StateName");