Ejemplo n.º 1
0
        public override void DoAction()
        {
            base.DoAction();
            //Battle
            _monster.Health.RemoveValue(_player.Attack.Value);
            UpdateStatusText();
            _player.Health.RemoveValue(_monster.Attack.Value);
            _player.HealthText.text = _player.Health.Value.ToString();

            if (_player.IsPlayerDead())
            {
                GameManager.Instance.DungeLikeStatisticData.TotalGold += _player.Gold.Value;
                GameManager.Instance.SaveStatisticData();
                MainMenuManager.CanContinue = false;
                //BinarySaver.SaveData(new DungeLikeCurrentGameData());
                SceneManager.LoadScene("EndGame");
            }
        }