Beispiel #1
0
        public RecoverCommand(BattleChar instigator, HealSkill skill) : base(instigator)
        {
            this.skill = skill;

            battle = GameManager.instance._battle;
            ui     = GameManager.instance._ui;

            delay = battle._delay;

            recoverType = CommandType.Skill;
        }
        void UseHealSkill(Skill skill)
        {
            HealSkill hSkill = (HealSkill)skill;

            if (hSkill._healAll)
            {
                turn._command._targets = battle._activeEnemies;
            }
            else
            {
                turn._command._targets = new BattleChar[] { combatant };
            }
        }
        void HealSkill(Skill skill)
        {
            HealSkill hSkill = (HealSkill)skill;

            if (hSkill._healAll)
            {
                turn._command._targets = battle._activeParty;

                sm.ChangeState(StateID.PlayerTurnAction);
            }
            else
            {
                turn._targets = battle._activeParty;

                sm.ChangeState(StateID.PlayerTurnTarget);
            }
        }