Example #1
0
 public bool CanCast(Spell spell)
 {
     return spell.ManaCost <= Mana;
 }
Example #2
0
 void MagicMenu_SpellTriggered(Spell spell)
 {
     CurrentSpell = spell;
 }
Example #3
0
        private void ItemTabOnClicked(Spell item)
        {
            CurrentSpell = item;

            KnownSpellTab.InfoTitle.Text = item.Name;
            KnownSpellTab.InfoImage.Image = item.Image;
            KnownSpellTab.InfoDescription.Text = item.Description + "\n" + "  * " + item.Hint;

            KnownSpellTab.CastButton.IsVisible = true;
            string additional = "";

            KnownSpellTab.InfoDescription.Text += additional;

            string requirementsText = "Requires " + item.ManaCost + " mana.";

            KnownSpellTab.InfoRequirements.Text = requirementsText;
        }
Example #4
0
 public bool CanCast(Spell spell)
 {
     return(spell.ManaCost <= Mana);
 }
Example #5
0
 public void SpellClicked(Spell spell)
 {
     spell.OnButtonTriggered();
     SpellTriggered.Invoke(spell);
     IsVisible = false;
 }