Ejemplo n.º 1
0
    private void AttackSpell(string spellName)
    {
        if (!MyIsAttacking_Spells)
        {
            //get the name of the spell from the spell book array
            Spell newSpell = SpellInventory.MyInstance.CastSpell(spellName);



            if (magicStat_Frame.MyCurrentValue >= newSpell.MagicCost)
            {
                MyAnimator.SetBool("attack", MyIsAttacking_Spells = true);

                attackCoroutine = StartCoroutine(newSpell.Ability());
            }
        }
    }