Thread Tools Display Modes
12-01-21, 09:15 PM   #1
unknown_ascaptain
A Kobold Labourer
Join Date: Dec 2021
Posts: 1
Binding a macro to Minimap Right-click? (or any other mouse action!)

Hello everyone, sorry for the weird question!

I have a tracking sequence macro that I love and use frequently. I would love to be able to run that macro when rightclicking my minimap.
However, the minimap steals clicks. As long as you're mousing over the minimap, ALL mousebuttons get turned into pings - even if you have mouse5 bound to a hotbar and nothing else, it gets turned into a ping anyways.
I haven't been able to get around this problem.
The only thing I've found is this code:
Code:
Minimap:SetScript("OnMouseUp", function(self, button)
	if button=="RightButton" then
		--LUA goes here
	else
	   Minimap_OnClick(self)
	end
end)
...This does work for binding something to minimap rightclick! But it seems limited to LUA. I can't put a macro there. Or at least, I don't know how.
So, I'm looking for a way to do one of these three things:
1) Somehow call a macro from Minimap:SetScript, or some other more direct way to bind a macro to minimap rightclick.
2) Somehow free up mouse5 from the minimap's click-stealing, then I can just leave mouse5 always bound to my macro, even when mousing over the minimap.
3) Maybe I could use some sort of semi-transparent frame *on top of* the minimap, that responds to rightclicks, but lets leftclicks pass through to the vanilla minimap? Is such a thing even possible?

Again, I apologize for the weird question and I apologize if I wasn't very clear. Any help is appreciated! (To be clear, though: I realize it would be easier to have a button outside the minimap. But that's not what I want!)
  Reply With Quote

WoWInterface » Developer Discussions » Lua/XML Help » Binding a macro to Minimap Right-click? (or any other mouse action!)

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off