Those two functions were added back in Burning Crusade and allow to check if spell is usable right now or (in default UI) should be dimmed out. They check both for mana (for spells) and special requirements, notably health percent or special buffs, so for item https://www.wowhead.com/item=208321/iridal-the-earths-masterIsUsableItem has 1st return true when target falls below 35% and for Hunter's ability https://www.wowhead.com/spell=53351/kill-shot 1st return becomes true when target has < 20% health OR Kill Shot effect from Deathblow talent is active.
Unfortunately both functions cannot report anything but "target" unit. It would be nice if they had 2nd argument unit, so you could check against other units.
Those two functions were added back in Burning Crusade and allow to check if spell is usable right now or (in default UI) should be dimmed out. They check both for mana (for spells) and special requirements, notably health percent or special buffs, so for item https://www.wowhead.com/item=208321/iridal-the-earths-master
IsUsableItem
has 1st returntrue
when target falls below 35% and for Hunter's ability https://www.wowhead.com/spell=53351/kill-shot 1st return becomestrue
when target has < 20% health OR Kill Shot effect from Deathblow talent is active.Unfortunately both functions cannot report anything but "target" unit. It would be nice if they had 2nd argument
unit
, so you could check against other units.