Returns whether or not a given spell is usable or cannot be used due to lack of mana. Does not account for spell cooldowns (see GetSpellCooldown() -- returns 1 if other conditions allow for casting the spell (e.g. if the spell can only be cast while outdoors).
See also Spell functions.
Signature:
isUsable, notEnoughMana = IsUsableSpell(index, "bookType") or IsUsableSpell("name")
Arguments:
index- Index of a spell in the spellbook (number, spellbookID)bookType- Type of spellbook (string)pet- The pet's spellbookspell- The player's spellbook
name- Name of a spell (string)
Returns:
isUsable- 1 if the spell is castable; otherwise nil (1nil)notEnoughMana- 1 if the player lacks the resources (e.g. mana, energy, runes) to cast the spell; otherwise nil (1nil)