Macro to cast Blessings depending on targeted class (BCC)

Hey!

I’d like to make a macro so that I can easily bless people while out questing. Basicly I want it to cast Might of the highest rank (dependant on targets lvl) on Warriors and Rogues and Wisdom on everyone else (also dependant on lvl).

So far I’ve got:

/script class = UnitClass(“target”); if ( ( class == “Rogue” ) or ( class == “Warrior” ) ) then CastSpellByName(“Blessing of Might)”); else CastSpellByName(“Blessing of Wisdom”); end

That should work but nothing at all happens when I press it…
I’ve searched around the web and this is what I’ve come up with. Suggestions?

Casting spells is a secure function so that macro will never work in combat.

Also, if you’re posting code you want people to review make sure you wrap it in code tags `x3 or the forums format your code, replace quotes with smart quotes, and make it harder for everyone involved to ensure they’re working with the same code.

/script class = UnitClass("target") if ( class == "Rogue" or class == "Warrior" ) then CastSpellByName("Blessing of Might") else CastSpellByName("Blessing of Wisdom") end

Thanks for the reply, never posted code before.

This macro would generaly be used outside of combat though. Any way to get that to work outside of combat? Even when out of combat it says that action has been blocked and only available by the Blizard UI.

Not sure about the macro but Pally Power appears to be updated.
https://www.curseforge.com/wow/addons/pally-power

My idea is that I can have a button on the actiobar I can “Bless and Run” with while blowing past people on my trusted steed :slight_smile:

This thread talks about turning it into an addon and provides the code. I just don’t know how to actually utilize it. Can’t post links though so I’ll get creative…
wowinterface . com / forums / showthread.php?t=910

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.