View Single Post
03-15-24, 11:29 AM   #5
SDPhantom
A Pyroguard Emberseer
 
SDPhantom's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2006
Posts: 2,327
This is what I'd suggest. Since all 3 spells only work on friendly targets, that's one less thing to be checked. Also combining it into a single /cast command ensures only one spell gets called and makes it easier to work on. Only the first condition that matches gets run and the rest are ignored.

Code:
#showtooltip
/cast [@mouseover,nodead] Blessing of Protection; [@mouseover,combat] Intercession; [@mouseover] Redemption
Here's the logic.
  • Is mouseover alive?
    • <Yes> Cast Blessing of Protection
    • <No> Are we in combat?
      • <Yes> Cast Intercession
      • <No> Cast Redemption

Note: Most unit conditions result in false if the unit doesn't exist ([no...] is an inverse function), so it should default to showing Blessing of Protection if there is no mouseover.
__________________
WoWInterface AddOns
"All I want is a pretty girl, a decent meal, and the right to shoot lightning at fools."
-Anders (Dragon Age: Origins - Awakening)
  Reply With Quote