/// <summary> /// 复活 /// </summary> public override void revive() { if (Time.timeScale != 1) { Time.timeScale = 1; } BM.clearBuff(); GameCharacterManager.Instance.reviveCharacter(this); IsDead = false; Rbody2D.gravityScale = NormalGravityScale; LoadObj.transform.position = new Vector2(PlayerPrefs.GetFloat("recordX"), PlayerPrefs.GetFloat("recordY")); CurrentHealth = TotalHealth; CurrentEnergy = TotalEnergy; CurrentHungerValue = TotalHungerValue * 0.35f; Alive = true; Eternal = false; Locked = false; MoveAnim.SetBool("dead", false); if (GameCharacterManager.Instance.containPlayer(this) == false) { GameCharacterManager.Instance.addPlayer(this); } CurrentState = StateEnum.IDLE; }