private void setAnimationFrame(UnityEngine.Animator anim, int currState)
 {
     anim.SetInteger("frame", animationArray[currState][(int)frame]);
 }