Useful Macro Templates

Self Cast Key Bug

In 9.2.5 Blizzard introduced a bug where the Self Cast Key interferes with @unit (mouseover, focus, etc.) and @cursor macros. If you want to use modifiers with those types of macros, you need to ensure your Self Cast Key is set to None (even if your Self Cast is set to Auto).

More info on the issue:

Season of Discovery Rune Placeholder Spells

With Season of Discovery, Blizz has added a number of placeholder spells you can use that will dynamically update depending on the rune you’ve selected. You can use these in combination with any conditions like you would with normal spells.

#showtooltip
/cast Legs Rune Ability
#showtooltip
/cast Hands Rune Ability
#showtooltip
/cast Chest Rune Ability

General Macro Templates

Ping Macro - 10.1.7

Pings your mouseover, if you have one, otherwise pings the ground at your cursor. The default keybind doesn’t support the mouseover of frames but this does.

/ping [@mouseover,harm] Warning; [@mouseover,help] Assist; [@mouseover,exists] Ping
/stopmacro [@mouseover,exists]
/ping

Universal Mount Macro

#showtooltip
/cast [advflyable] DRAGONRIDING_MOUNT; [flyable] FLYING_MOUNT; GROUND_MOUNT
/dismount [mounted]

Known Macro

With the addition of the known condition you can now filter macro logic by spell name or spell id.

#showtooltip
/cast [known:SPELL1] SPELL1; [known:123456] SPELL2

Helpful Mouseover Macro

Cast a helpful spell prioritizing mouseover.

#showtooltip
/cast [@mouseover,help,nodead] [] SPELL

Harmful Mouseover Macro

Cast a harmful spell prioritizing mouseover.

#showtooltip
/cast [@mouseover,harm,nodead] [] SPELL

Reaction Neutral Mouseover Macro

Cast a spell that can target both friends and enemies, prioritizing mouseover (Penance, Holy Shock, Shadowstep etc.)

#showtooltip
/cast [@mouseover,exists,nodead] [] SPELL

Help/Harm Macro

This will cast one spell when mousing over or targeting a friend and another when mousing over or targeting an enemy.

HELP_SPELL as Default

#showtooltip
/cast [@mouseover,help,nodead] HELP_SPELL; [@mouseover,harm,nodead] [harm] HARM_SPELL; HELP_SPELL

HARM_SPELL as Default

#showtooltip
/cast [@mouseover,harm,nodead] HARM_SPELL; [@mouseover,help,nodead] [help] HELP_SPELL; HARM_SPELL

Multi-modifier Mouseover Macro

Example of how to include multiple spells, differentiated by modifier, including mouseover. Trim it down and change exists to help or harm depending on what you’re actually using it for.

#showtooltip
/cast [mod:ctrl,@mouseover,exists,nodead] [mod:ctrl] CTRL_SPELL; [mod:shift,@mouseover,exists,nodead] [mod:shift] SHIFT_SPELL; [mod:alt,@mouseover,exists,nodead] [mod:alt] ALT_SPELL; [@mouseover,exists,nodead] [] SPELL

Reticle Macro

Alt: Cast at Player
Combat: Cast at Cursor
Default: Display Reticle

#showtooltip
/cast [mod:alt,@player] [@cursor,combat] [] SPELL

Nochanneling Macro

Prevent casting when CHANNELING SPELL is channeling.

#showtooltip
/stopmacro [channeling:CHANNELING SPELL]
/cast SPELL

Prevent casting when ANY SPELL is channeling.

#showtooltip
/stopmacro [channeling]
/cast SPELL

Stopcasting Macro

Cancels your currently queued spell and interrupts your current cast so you can cast a priority spell. Note: this functionality is automatically baked into all interrupts. Also, this is really only useful for cancelling spells with a cast time > 1 GCD OR if you’re cancelling so you can cast a spell that’s off the GCD.

#showtooltip
/cqs
/stopcasting
/cast SPELL

Cancelaura Macro

Useful for things like Levitate, Ice Block, Spectral Sight where you want to be able to toggle them on and off with a single key.

#showtooltip
/cancelaura BUFF
/cast SPELL

Base Healing Macro

Alt: Self Cast
Mouseover Friend: Cast on Mouseover
Target Friend: Cast on Target
Target Enemy Targeting Friend: Cast on Enemy’s Target
Default casting behavior. This condition also serves to generate the correct tooltip.

#showtooltip
/cast [mod:alt,@player] [@mouseover,help,nodead] [help] [@targettarget,help,nodead] [] SPELL

Offensive Macro for Healers

This macro is for healers who want to dps without switching to enemy targets. Basically allows you to dps while having fiendly players targeted or moused over.

Mouseover Enemy: Cast on Mouseover
Target Enemy: Cast on Target
Mouseover Friend Targeting Enemy: Cast on Friend’s Target
Target Friend Targeting Enemy: Cast on Friend’s Target
Default casting behavior. This condition also serves to generate the correct tooltip.

#showtooltip
/cast [@mouseover,harm,nodead] [harm] [@mouseovertarget,harm,nodead] [@targettarget,harm,nodead] [] SPELL

Conditional Focus Cast

Shift: Clear Focus
Alt: Set/Cast on Focus
Default: Cast on Target

#showtooltip
/focus [mod:alt,@focus,dead] [mod:alt,@focus,noexists]
/clearfocus [@focus,dead] [mod:alt,@focus,noexists] [mod:shift]
/cast [mod:alt,@focus,exists] [] SPELL

Dynamic GetSpellInfo Macro

This has been supplanted by the known condition in Retail but you may still need it in Classic. You can add whatever conditions you want to the cast lines.

#showtooltip
/cast SPELL1
/cast SPELL2
/cast SPELL3
/run local G=GetSpellInfo SetMacroSpell(GetRunningMacro(), G"SPELL1" or G"SPELL2" or G"SPELL3")

CVar Toggle

Macro for toggling a 0/1 CVar on and off. Replace CVAR_NAME with the CVar you want to toggle.

/run local k,v = "CVAR_NAME" v = C_CVar.GetCVar(k) C_CVar.SetCVar(k, 1 - v) print(k .. (v == "1" and " Disabled" or " Enabled"))

World Marker Spam

WeakAura Version; doesn’t break if you don’t use it while out of combat first:
https://wago.io/WLcXW-0JN

This macro is > 255 chars. I recommend using it with BindPad.

Click to set world markers, shift click to clear.
Note: You need to be out of combat the first time you press it or it will throw an error.

/cwm [mod:shift] 0
/run local b=_MB or CreateFrame("Button", "_MB", nil, "SecureActionButtonTemplate")  _MH=_MH or(b:SetAttribute("*type5","macro")or SecureHandlerWrapScript(b,"PreClick",b,'Z=IsShiftKeyDown()and 0 or(Z or 0)%8+1 self:SetAttribute("macrotext5","/wm [@cursor] "..Z)'))or 1
/click _MB Button5

This variant is <255 but uses ActionButton8 for the macro.

/cwm [mod] 0
/run local b=ActionButton8 _MH=_MH or(b:SetAttribute("*type5","macro")or SecureHandlerWrapScript(b,"PreClick",b,'Z=IsShiftKeyDown()and 0 or(Z or 0)%8+1 self:SetAttribute("macrotext5","/wm [@cursor] "..Z)'))or 1
/click ActionButton8 Button5

Class Utility Macros

Death Knight

Alt: Lichborne
Help: Raise Ally
Default: Raise Dead/Gnaw

#showtooltip
/cast [mod:alt] Lichborne; [@mouseover,help,dead] [help,dead] Raise Ally; [spec:3,nopet] Raise Dead; [spec:3,@mouseover,harm,nodead] [spec:3] Gnaw

Demon Hunter

Alt: Spectral Sight
Default: Consume Magic

#showtooltip
/cancelaura Spectral Sight
/cast [mod:alt] Spectral Sight; [@mouseover,harm,nodead] [] Consume Magic

Druid

Dead: Rebirth
Harm: Soothe
Default: Nature’s Cure/Remove Corruption

#showtooltip
/cast [@mouseover,help,dead][help,dead]Rebirth;[spec:4,@mouseover,help,nodead]Nature's Cure;[@mouseover,help,nodead]Remove Corruption;[@mouseover,harm,nodead][harm]Soothe;[spec:4]Nature's Cure;Remove Corruption

Evoker

Shift: Rescue
Alt: Cauterizing Flame
Default: Naturalize/Expunge

/cast [mod:shift,known:370665,@mouseover,help,nodead][mod:shift,known:370665]Rescue;[mod:alt,known:374251,@mouseover,help,nodead][mod:alt,known:374251]Cauterizing Flame;[spec:2,@mouseover,help,nodead][spec:2]Naturalize;[@mouseover,help,nodead][]Expunge

Hunter

Shift: Revive/Mend Pet
Alt: Misdirection
Default: Tranquilizing Shot

/cast [mod:shift,@pet] Revive Pet; [nomod,@mouseover,harm,nodead] [nomod] Tranquilizing Shot; [@focus,help,nodead] [@mouseover,help,nodead] [help] [@pet,exists] [] Misdirection

If you want to be absolutely certain it perfectly falls back, use this version instead. It just excludes the possibility of mouseover or focus not in your group

#showtooltip
/cast [mod:alt,@pet] Revive Pet; [@focus,help,group] [@mouseover,help,nodead,group] [help,group] [@pet,exists] [] Misdirection

Mage

Alt: Alter Time
Harm: Spellsteal
Default: Remove Curse

#showtooltip
[mod:alt] Alter Time; [@mouseover,help,nodead] Remove Curse; [@mouseover,harm,nodead] [harm] Spellsteal; Remove Curse

Monk

Alt: Diffuse Magic
Shift: Dampen Harm
Help: Detox
Harm (WW): Touch of Karma

#showtooltip
/cast [mod:alt] Diffuse Magic; [mod:shift] Dampen Harm; [spec:3,@mouseover,harm,nodead] Touch of Karma; [@mouseover,help,nodead] [help] Detox; [spec:3,harm] Touch of Karma

Paladin

Dead: Intercession
Default: Cleanse Toxins/Cleanse

#showtooltip
/cast [@mouseover,help,dead] [help,dead] Intercession; [spec:1,@mouseover,help,nodead] [spec:1] Cleanse; [@mouseover,help,nodead] [] Cleanse Toxins

Priest

Shift: Mind Soothe
Alt: Mass Dispel
Harm: Dispel Magic
Default: Purify Disease/Purify

#showtooltip
/cast [mod:shift] Mind Soothe; [mod:alt] !Mass Dispel; [spec:3,@mouseover,help,nodead] Purify Disease; [@mouseover,help,nodead] Purify; [@mouseover,harm,nodead] [harm] Dispel Magic; [spec:3] Purify Disease; Purify

Rogue

Shift: Crimson Vial
Alt: Shiv
Default: Grappling Hook/Shadowstep

#showtooltip
/cast [mod:shift] Crimson Vial; [mod:alt] Shiv; [known:36554,@mouseover,exists,nodead] Shadowstep; [known:195457,@cursor] Grappling Hook; [known:36554,exists] Shadowstep

Shaman

Harm: Greater Purge/Purge
Default: Purify Spirit/Cleanse Spirit

#showtooltip
/cast [spec:3,@mouseover,help,nodead]Purify Spirit; [@mouseover,help,nodead] Cleanse Spirit; [known:378773,@mouseover,harm,nodead][known:378773,harm] Greater Purge; [@mouseover,harm,nodead][harm] Purge; [spec:3] Purify Spirit; Cleanse Spirit

Warlock

Alt: Unending Resolve
Dead: Soulstone [overly complex due to Blizz bugs]
Default: Command Demon

/cqs [@mouseover,help,dead] [help,dead]
/target [@mouseover,help,dead]
/cast [mod:alt] Unending Resolve; [@mouseover,help,dead] [help,dead] Soulstone;  [@mouseover,exists,nodead] [] Command Demon
/targetlasttarget [@mouseover,help,dead]

Warrior

Alt: Spell Reflection
Shift: Shattering Throw
Default: Heroic Throw

#showtooltip
/cast [mod:alt,known:23920] Spell Reflection; [mod:shift,known:64382,@mouseover,harm,nodead] [mod:shift,known:64382] Shattering Throw; [@mouseover,harm,nodead] [] Heroic Throw

Other Resources

9 Likes

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