Left Click with Keyboard

Hi,

I’ve recently developed a pretty rough RSI injury in my right (mouse) hand, and I’m trying to figure out ways to minimize my use of the right hand. I was wondering if it’s possible to create a left-click action via the keyboard?

I currently do alot of crafting which often involves clicking the enchant / craft etc button very frequently. I’m finding the extreme repetitiveness of this is worsening my injury and so a keyboard alternative to the left click would be great, if it exists.

Thanks

You can use AutoHotkey or other keyboard mapping software to do it. So long as you’re doing a one-to-one mapping you shouldn’t run the risk of getting flagged.

You may also be able to manually edit the bindings-cache.wtf file but I’m not sure what the command is.

There’s multiple ways to go about this:

/run frame = GetMouseFocus();frame:Click("LeftButton", 1);

This will simulate a left-click on the Button the mouse is over currently when the key is pressed.


Alternatively:

/run TradeSkillFrame.DetailsFrame.CreateButton:Click("LeftButton", 1);

This will always press the Create button of the crafting window no matter where your mouse currently is.

By replacing the TradeSkillFrame.DetailsFrame.CreateButton part with the name of another button you can use this macro for other buttons aswell.

You can find out the button names by using /framestack. This will toggle an additional tooltip with info over frames that the mouse is currently hovering over (use /framestack again to disable the tooltip when you’re done).


I know this isn’t exactly what you were looking for, but maybe this could help you aswell.

https://www.curseforge.com/wow/addons/console-port

It’s an addon that allows you to control most things with a gamepad.

4 Likes

Great, thank you so much! These are exactly what I was looking for.

Soon I can throw away my mouse entirely!!

Have you considered picking up a game pad with a thumb stick, such as a Razer Tartarus?

I’ve just had a look and whilst interesting, i’m not sure i would ever get used to something like that!

regarding the macros, i was happily using the left-click macro to disenchant items, craft etc, however i’ve just logged in today after a few days off and i’m getting ‘‘a macro script has been blocked from an action only available to the Blizzard UI’’. Disabling addons does nothing, it still does not work.

Has Blizzard intervened to prevent me from doing this?!?!

EDIT - it appears to only be blocked when trying to click an item in my bags for some reason.

Is there a way to modify a version for the right-click? (I.e. looting). I tried changing the left click to right click in the macro but no luck.

Thanks again

Interact with Mouseover in Keybindings should help.

1 Like

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