The first macro I'll share is one you can use to sell every grey item in your bag. There are addons for this; however, a macro takes no memory and doesn't need to be updated every patch.
/run for bag=0,4 do for slot=1,GetContainerNumSlots(bag) do local item=GetContainerItemLink(bag,slot) if item and item:find("ff9d9d9d") then UseContainerItem(bag,slot) end end end
What this is actually doing is right-clicking on every gray item in your bag, so don't do it in front of your bank unless you want to deposit all your grays into it.
The next vendor macro you might find useful is a hotkeyable macro for buying vendor goods. If you have TSM (or some other addon that queues crafts and gives you an auto-buy button at the vendor), this won't be as useful. I still use it for some things, though. Sometimes you just need to buy a lot of something from a vendor.
Those numbers indicate what you want to buy and how many of them. The first number is the slot at the merchant; 1 is the top left, 2 is the top right, 3 is just below 1, and it continues on that way. Be careful not to use the wrong index, or else you could find yourself stuck with a lot of the wrong item. The second number is how many you want to buy. Some items are sold in stacks, but this will specify a precise number (just like shift-clicking on the item).
Next, we consider the mailbox. Mailing between characters can be tedious if you have to right-click each time. While TSM can be set up to auto-mail items to alts based on groups (which is handy if you don't list what you make on the character that makes it), it can be intimidating to set up. Also, it won't help you if you're looking to do a one-time mass mail. There are a few things I find myself mailing a lot, and sometimes I want to mail everything of a particular quality, and sometimes I want to do it by name.
This macro will right click everything matching the name "Elementium Ore." Simply open your mail, type the name into it (and a subject, if you want), and then click this macro. It will put 12 items into the mail and then warn you that you can't attach more than 12 items per mail for each item in your bag.
/run for bag=0,4 do for slot=1,GetContainerNumSlots(bag) do local item=GetContainerItemLink(bag,slot) if item and item:find("Elementium Ore") then UseContainerItem(bag,slot) end end end
It's not going to work if you type "Elementium ore" because it's case sensitive. If you want, you can just say "Ore" if you want to mail all your ore. Be careful with this type of matching, though. If you tell it to mail all your "Obsidium," it will also match a lot of green gear you may have in your bags.
Here is a macro that will right-click based on item quality:
/run for bag=0,4 do for slot=1,GetContainerNumSlots(bag) do local texture,itemCount,locked,quality=GetContainerItemInfo(bag,slot) if (quality==2) then UseContainerItem(bag,slot) end end end
That "quality==2" is what determines what gets clicked on. Leave it at 2 to mail greens, change it to 3 for blue quality items, and change it to 4 for epic. This macro is useful if you're using an addon to buy items that can be disenchanted for a profit. Be careful, though, as it will click on everything in your bag that matches the quality, even if it's soulbound. Also, if it's bind on equip and you don't want to bind it, you should be extra careful not to press this macro away from a mailbox. It will at least ask you before equipping it, of course.
Milling, prospecting, and disenchanting
Some things can't be completely automated, especially things such as milling, prospecting, and disenchanting that are designed to take time. That said, the default interface for these abilities is rather clunky. Without a macro, you need to hit the ability, find the item in your bag, and click on it. It's error prone (ever disenchanted your offset?) and clunky. With a macro, you can make one button that will only work on the items you've specified. For example:
/use Stormforged Legguards
The first one is pretty obvious, and it will disenchant with one click (or key press) only Stormforged Legguards. (Obviously, I wrote this one when that was still profitable.) If you craft for disenchanting, this is the way you want to disenchant.
What about jewelcrafters, though? It's one of the best professions for crafting cheap greens. Here's the problem: If you are making Jasper Rings, each one has its own name. They all have the same item ID, though, so you can /use an item number instead of a name.
The last trick I'll post here is how to click anything with a keybindable macro. Whether you want to press space bar to click "craft next," shift-mousewheel up to click the post your next auction button, or press 1 to hit Heroic Will on Ultraxion, you can write a macro and keybind anything.
First off, you need to know the name of whatever it is you want to click. Save this macro, and keybind it to something so you have the use of your mouse:
/run local f = GetMouseFocus(); if f then DEFAULT_CHAT_FRAME:AddMessage(f:GetName()) end
Now hover your mouse over what you really want to click with your keyboard, and press that macro. It'll give you the name of the object in the chat frame, and you can now macro a click. Here are some I have looked up and keybound:
This one will click Heroic Will on Ultraxion, as well as Ysera's damage mitigation from phase 2 of Madness: /click ExtraActionButton1
This one will click the TSM post button, and TSM will even bind it to the mousewheel for you if you ask it to: /click TSMAuctioningPostButton
In short, if you can click it but want to press a key, you now have that choice.
Maximize your profits with advice from Gold Capped. Want to know the very best ways to earn 10,000 gold? Top gold making strategies for auctioneers? How about how to reach 1 million gold -- or how one player got there and then gave it all away? Fox and Basil are taking your questions at email@example.com and firstname.lastname@example.org.