The "target=*" macro condition only supports (a) unit tokens like "player" or "focus", or (b) names of characters in your current party or raid.

You could try this:

Code:

/cleartarget
/target Auctioneer
/click [exists] MacaroonButton70

However, a better solution would probably be to modify whatever macrotext code is on MacaroonButton70 to only run if the auction house was open. If you need help with that, or aren't sure if it's even possible, you'll have to post the button's macrotext.

The "target=*" macro condition only supports (a) unit tokens like "player" or "focus", or (b) names of characters in your current party or raid.

"target=*" isn't a conditional really. It sets which unit to apply the conditionals to, and if applicable, who to act on. This is not a target comparison check of any kind and such functionality doesn't exist within the macro system. Blizzard has added the "@*" alias for this to try to solve the ambiguity of the syntax of this macro option.

True, that's not the intended use, but it is the only way to accomplish some things. My action bar addon (also Macaroon) can use macro conditionals to define bar states. In order to create a bar state that shows only when I am dead, I have to do [@player, dead] which is the short version of [target=player, dead]. If you simply use [dead] it will show the bar when my current target is dead, which is not the desired functionality.

Also, I think the @unit alias for target=unit was added more because of the extreme limitations on the length of macros, than as an attempt to clarify the meaning. Length is also the reason they added bar as an alias for actionbar and form as an alias for stance (though the latter was also added because the average player probably does not realize that druid forms are considered stances by the game/macro engine).

I use extensive Macro branching to minimize the amount of work required to change something that is used by more than one button. MacaroonButton503 ,for example, is in all of my combat macros and works perfectly, printing "Combat gear equipped successfully" only if that is actually the case. If I were to get an upgrade for my Bloodthirsty Pyrium Helm, (which is likely lol) it would be a nightmare changing all my buttons! With Macro branching I just need to change 1.

The first macro, the /in command provided by an addon would error trying to call /stopmacro because it's a secure command. Also the way macros are run, the line after it would execute immediately anyway.

The second macro doesn't guarantee in any way whether or not the user has the AH up. You can run the macro right outside the building (the auctioneers still in view of the client) and the entire macro would still run.

Originally Posted by Aanson

Don't get me wrong though Phanx, if there's a way to make the button only work when the AH is open like

Code:

/run if AuctionFrame:IsVisible() then...

i'd much prefer that! I did try messing about with the idea for a bit without success.

This'll be more specific and only run if the Blizzard_AuctionUI addon is loaded and opened to the auctions tab.

Code:

/run if AuctionFrameAuctions and AuctionFrameAuctions:IsVisible() then AuctionsCancelAuctionButton:Click();StaticPopup1Button1:Click(); end