Krazyito

Guide to simple macros.

14 posts in this topic

Introduction and basics of a macro.
This guide is meant to make simple macros for almost any class and explain how they work.

If you are looking to make a specific kind of macro, please post below and we will be glad to help.

Basically, a macro is just a group of slash commands that is executed by the push of a single button.

Any spell can be cast with a slash command


/use Fireball

This command (on a fire mage) will cast Fireball and each time you execute this macro it will attempt to cast fireball.

Now, usually I like to show the tool tip for the spell I'm casting for when I mouse over it, so I add the simple "#showtooltip" to the top of the macro to do so.

#showtooltip
/use Fireball

This will now show the tool tip for the spell you are casting when you mouseover. You can also add a spell name after "showtooltip" to make a different tool tip appear.



Conditions
Conditions are extra bits of information next to a slash command that either make it do something different or to a specific target, when you either have a specific target, or button pressed.


A simple example will is

#showtooltip
/use [@player] Heal

This condition "[@player]" means that it will use the spell on the player (player in this case means yourself). It does not matter if you have a target or not, it will indefinitely attempt to cast "Heal" on the player.


You can use any condition in place of it to target or use spells on something specific. Here is a list that I can think of off the top of my head (please post below if you know of others!)

  • [@player] - Use on yourself
  • [@target] / [] - redundant since it will automatically cast to your target if there is no modifier, but there it is nonetheless
  • [target=krazyito] - This will attempt to cast the spell on a unit named "krazyito".
  • [@Krazyito] - this will do the same as above, but use it on a target named "Krazyito" - only works if you're in the same party/raid
  • [@focus] - cast on your focus
  • [@pet] - use spell on your pet
  • [@mouseover] - cast on your mouseover target
  • [@targetoftarget] - targets your targets target.
  • [combat] / [nocombat] - only use if you're in combat or not.
  • [help] - use only if the target is friendly
  • [harm] - use only if the target is hostile
  • [nodead] / [dead] - use only if the target is not dead / dead
  • [stance:0] / [stance:1] / [stance:2] - will only use if you're in a specific stance (0 = no stance), is ordered from left to right of the stance bar.
  • [mod:shift] / [mod:ctrl] / [mod:alt] - will only be used if a specific button is also being pressed.
  • [spec:1] / [spec:2] - These are for your Primary and Secondary specialization
  • [mounted] - if you're mounted
  • [flyable] - only if the area is flyable
  • [indoors] - if the area is indoors
  • [swimming] - if you're swimming
  • [@boss1] / [@boss2] / [@boss3] - targets a specific boss that is displayed on the right hand side of the screen on the boss frame. (top down on default, bottom up on ElvUI)
  • WOD ONLY: [talent:3/2] - This is a new condition in WoD where it will only activate is you have the talent on the 3rd tier, 2nd spell active.

 

 

Those are most of the ones I can think of off the top of my head. Now all of these can be used individually, but the strength comes when you chain them together. Note: be careful when stringing these together you do not use two that are conditioning one thing that can be in one state or the other, (example, indoors and flying. Make sure they are mutually exclusive before using them together)

An example of chaining 2 spells together using a Shift modifier.

#showtooltip
/use [mod:ctrl] Greater Heal; Heal

Multiple commands on a single line are separated by a semi-colon. This particular macro means when the ctrl button is being pushed, it will cast greater heal (on your target), else if control is not being pushed it will cast heal.

Important! - Macros work in a priority system in order from left to right.

This means that a macro will attempt to execute the spells from left to right based on the conditions present. What ever the first spell it reaches that is true, that is what it will cast.

EXAMPLE - BAD MACRO
#showtooltip
/use Heal; [mod:ctrl] Greater Heal

The reason this macro is bad is because the condition is at the end of the macro. Since the first command it reached was "Heal" with no condition, then it will only cast heal, regardless of your condition.

Now, some macros can also be tied together. Specifically, any condition that has an "@" symbol can be paired with another condition that does NOT have the "@" symbol ([target=krazyito] is an exception because, this was the old way of doing these macros before the "@" symbol was implemented)

Examples of pairing conditions together

#showtooltip
/use [mod:ctrl, @mouseover] Greater Heal

#This macro will only work if you're holding the control key and have a mouseover target

Notice that they are all together within the brackets, spaced by a comma. You can string more conditions together in there, in any order (since the condition is read all together and only the spells are on the priority list). The more conditions you add, the more specific the macro becomes.


Other examples that are popular for healers

#showtooltip
/use [@mouseover,nodead,help][help, nodead] [@focus,nodead,help] [@player] Flash Heal

- this macro targets your mouseover first, if they are not dead and friendly, then your normal target, if they are not dead and friendly, then your focus, if they are not dead and friendly, then yourself.

Notice how this macro separates any "@" condition with separate brackets. This is important when making your priority. If you have a macro like this, but with a mod attached, you may have to add them to each section for it to work.



Other Special macros I have learned recently

#showtooltip
/use [mod:ctrl, @mouseover, spec:2] Pain Suppression; [mod:ctrl, @mouseover, spec:1] Guardian Spirit; [@mouseover] Greater Heal

This is one specific to priests, if you have Disc as your Secondary spex, and Holy as your primary spec. This macro will but greater heal as the button, then when you press ctrl, it will be pain sup or guardian spirit depending what spec I'm in.

#showtooltip
/use [stance:1] renewing mist; [stance:2] jab

This is a macro I'm going to be using in WoD for mistweaver, it uses renewing mists if im in Serpent stance, while jab in Crane stance.


WOD ONLY, DRUID:

#showtooltip
/use [talent:5/1] Disorienting Roar; [talent:5/2] Ursol's Vortex; [talent:5/3] Mighty Bash

----
 

#showtooltip
/use [combat] rebirth; revive

Use a specific res depending if you're in combat or not.
 

/cwm [mod:ctrl] all
/wm 1
 --- 
/wm [mod:ctrl] 2; [mod:alt] 3; 4

Uses world marker 1, if holding ctrl clear all world markers
--
uses different markers on different modifiers.

/run SetRaidTarget("Target", 3)

Sets specific marker on your target.
8 = {skull}
7 = {cross}
6 = {square}
5 = {moon}
4 = {triangle}
3 = {diamond}
2 = {circle}
1 = {star}


Then there are other extra things like

  • /click StaticPopup1Button1 - clicks the conformation button on stuff like "Are you sure you want to do that"
  • /targetlasttarget - targets your last target
  • /target boss1 - or do /tar
  • /target focus - etc....
  • /dismount [mounted] - dismounts if you're mounted.
8 people like this

Share this post


Link to post
Share on other sites

I made this guide at 6am. I'm gonna go back when I'm a bit more awake to fix any grammatical errors. I pretty much just wrote everything I could think of before I forgot it all to my sleep. 

Share this post


Link to post
Share on other sites

Awesome stuff Krazy. Like Gwen said.. those who cannot do, teach. ;)

1 person likes this

Share this post


Link to post
Share on other sites

So you and Gwen suck too since you're here.

1 person likes this

Share this post


Link to post
Share on other sites

another one I like to use for certain things is /castsequence. it will allow you to put multiple spells in one macro that normally wouldn't be able to be macro'd together. For example I use a castsequence for raise dead and death pact so I can just spam the same button twice and it will raise dead and then deathpact immediately afterwards.

 

it looks like this:

 

#showtooltip

/castsequence reset=120 Raise Dead, Death Pact

 

The first time I use the macro it will /cast raise dead, and the tooltip will show raise dead, then after casting raise dead the macro and tooltip will switch to death pact. reset=120 is in there so that if I don't use deathpact within 2 minutes the macro will reset back to Raise Dead.

 

another thing worth noting, the coolest feature about #showtooltip is that when you use shift mods, and castsequences, the tooltip/icon will always change to the spell that is currently set to go off when you cast the macro.

2 people like this

Share this post


Link to post
Share on other sites

another one I like to use for certain things is /castsequence. it will allow you to put multiple spells in one macro that normally wouldn't be able to be macro'd together. For example I use a castsequence for raise dead and death pact so I can just spam the same button twice and it will raise dead and then deathpact immediately afterwards.

 

it looks like this:

 

#showtooltip

/castsequence reset=120 Raise Dead, Death Pact

 

The first time I use the macro it will /cast raise dead, and the tooltip will show raise dead, then after casting raise dead the macro and tooltip will switch to death pact. reset=120 is in there so that if I don't use deathpact within 2 minutes the macro will reset back to Raise Dead.

 

another thing worth noting, the coolest feature about #showtooltip is that when you use shift mods, and castsequences, the tooltip/icon will always change to the spell that is currently set to go off when you cast the macro.

 

Not sure if there have been changes to this lately, but I remember death pact being oof the global cooldown. so this particular example can be used with one click by simply putting:

#showtooltip
/cast raise dead
/cast death pact

might be wrong on that, just wanted to let u know this worked for that example. the castsequence macro is very usefull tho.

Share this post


Link to post
Share on other sites

you may be right, but the other reason I put them on a cast sequence is so I can sometimes summon my ghoul early for dps purposes and save death pact until I need it, but they still only take up one button.

 

I have some other more advanced ones that work for me, but may or may not actually be useful for other people unless you're OCD about putting all of your abilities on a few buttons as possible. like I have a cast sequence + ctrl mod for taunt and death grip. (I mostly use cntrl mods because shift mods don't work with the Razor Naga if you're binding keypad buttons)

 

#showtooltip

/cast [mod:ctrl] deathgrip;

/castsequence reset=8  dark command, deathgrip

 

what that macro does is initially the button is dark command. if I want to death grip I can hold ctrl and the macro will death grip instead. but if I use dark command the macro will automatically switch to deathgrip while dark command is on cooldown.

 

I do the same thing for a lot of my cooldowns and somewhat situational abilities. I use almost the exact same macro for warlock cookies/ health pot, I have one like that for vampiric blood and icebound fortitude, another one for AMS/AMZ, I shift mod icy touch/plague strike for blood spec since they're only used occasionally for applying diseases. pretty much the only abilities I don't double up on through macros one way or another are my most spammed abilities, death strike and rune strike.

 

It's a little bit crazy, but it allows me to get all my keybinds down to just 5 on my keyboard, and 12 Naga buttons, and there are less than 5 abiltiies that I ever need to click, and they're either extremely situational, or targeting/marking macros.

Share this post


Link to post
Share on other sites

Awesome stuff Krazy - just the sort of thing I would have killed for when i first started out!

1 person likes this

Share this post


Link to post
Share on other sites

used this recently.  helped me remember some stuff. =D

Share this post


Link to post
Share on other sites

Alright I'll give this thread a shot.  How about making a macro thats able to show item links in trade.  Try this out

 

When you create a trade barking macro, write the text first. Then where you want to insert your item write "<>"

 

Like so:

 

/2 WTS "<>" 500k or OBO  

 

-

 

Now put your cursor right between the <>.

 

Then type: /script MacroFrameText:Insert("") 

in the chat window.  Be sure not to use the macro window.  Now shift+click the item you want to link... and Boom!  It goes right into the macro.

 

This will insert the item link into your macro.. And now you have a macro that puts an item link into trade.  cool.png

 

You can put up to 3 different links in there too.  The script alone is good for trade barking.

Share this post


Link to post
Share on other sites

So since we're sharing, I once upon a time found this macro around the internet and have been using it for years now.

 

simply make an action button for this macro and click it once. every time you relog or /reloadui you will have to click it again fo it to work. Clicking it multiple times will not do anything else than clicking it once already does.

I haven't been able to figure how to turn it off without a /reloadui but that is not really a problem.

/run local f=AtH or CreateFrame("Frame","AtH") f:SetScript("OnEvent",function() CallCompanion(C_MountJournal.Summon(0)) end) f:RegisterEvent("LOOT_CLOSED")

Now this may look difficult but it's actually rather simple, if you have clicked this macro once it will automatically summon a random favorite mount whenever you loot anything.

this is particulary useful if you are a miner/herber/skinner etc. 

I realise the use of this macro is a bit outdated. If you have the stables for example, it becomes rather useless.

 

The only thing I would like better is when it would include auto-mounting me whenever I finish a cast of Logging (Lumber Mill) or Survey (Archaeology). But I'm not too sure this is even possible.

 

Anyhow, just throwing this in there for anyone to use if they want.

Share this post


Link to post
Share on other sites

You can also make cool macros for button clicks if needed.  

 

If type /fstack in game WoW will show you the button codes for pretty much any button ingame.  You can process these codes into a macro for ease of use.  With it you can make macros for any button on your UI.

 

So lets say I wanted to make a button that closes a vendor's window after purchasing.  I would type /fstack and mouse over the little "x" button that closes out the window.  WoW would then give you the code for the close button.  It'll read something like (xxxxx (button name) Window Pane).

 

Now you would just create a macro that read:

 

" /Click: [paste button code]

 

...

 

And your done.  

 

You can make buttons  / macros for opening and closing just about anything I'd suppose.  I use it mainly for TSM, but I'm sure people here can find uses for it.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.