public BaseMagic Cast(BaseMagic magic, Vector3 position) { if (magicList.Contains(magic.MagicType)) { if (Caster.CurrentMana >= magic.Mana) { Caster.ReduceMana(magic.Mana); return magic.GetInstantiate(position); } } return null; }
protected void SetMagicData(BaseMagic paramMagic) { CurrentDamage = paramMagic.Damage; ManaCount = paramMagic.Mana; LifeTime = paramMagic.LifeTime; }
public void AddMagic(BaseMagic magic) { magicList.Add(magic.MagicType); }