Пример #1
0
 public bool CanCast(Spell spell)
 {
     return spell.ManaCost <= Mana;
 }
Пример #2
0
 void MagicMenu_SpellTriggered(Spell spell)
 {
     CurrentSpell = spell;
 }
Пример #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;
        }
Пример #4
0
 public bool CanCast(Spell spell)
 {
     return(spell.ManaCost <= Mana);
 }
Пример #5
0
 public void SpellClicked(Spell spell)
 {
     spell.OnButtonTriggered();
     SpellTriggered.Invoke(spell);
     IsVisible = false;
 }