private void DoAnim() { if (currenthp != theLastHp && currenthp > 0) { ////this.transform.GetChild(1).GetComponent<Animator>().SetBool("BeAttack", true); if (stateController.m_anim != null) { //stateController.m_anim.SetBool("BeAttack", true); stateController.PlayAnim("BeAttack", 0f); stateController.BeAttack = true; } theLastHp = currenthp; //stateController.BeAttack = false ; } else { if (stateController.m_anim != null) { ////this.transform.GetChild(1).GetComponent<Animator>().SetBool("BeAttack", false); //stateController.m_anim.SetBool("BeAttack", false); } stateController.BeAttack = false; } }