I don't know how you guys put up with this, but the fact that any type of /stopcasting (macroed or via default Escape key) cancels your AA/swing rotation first, and the actual shot you're casting second, is absolutely fucking irritating. It hardly makes any sense to me that swings would be toggled off first, and then you have to /stopcasting again to cancel the actual thing THAT IS BEING CASTED. Especially when there's a separate command in the game - /stopattack - that stops just the swings, for those who want that functionality specifically. It might be just because I'm coming with a caster background and I'm just way too used to Escape actually canceling casts, I don't know, but this seems wrong.
Now, the obvious solution is to just make Escape a /stopcasting /stopcasting macro, but that kills off the functionality of Escape key everywhere else. You can't close menus and windows with it and shit. And that's annoying. So I did a quick and dirty hack for this.
Download and install this addon: http://www.mediafire...roperEscape.zip
Or, if you already have a scripts & tweaks addon or something, paste this into it:
SpoilerIn short, this overwrites Blizzards Escape key function with an edited version, which doesn't call any protected functions - we can't use any protected functions in scripts or macros in any way whatsoever, because then you could code things that stop casting automatically based on any arbitrary event, basically cheating - but at the same time allowing us to actually use it in any normal macro (since it's not calling anything protected, geddit?).
This version lacks three things:
- Stop casting - intended
- Target clear - unintended, but I can't do anything about this, everything to do with targeting is protected. If you're used to dropping target via Escape key... well, tough shit.
- SetUIVisibility(true) - this enables UI elements in the 3D world (think nameplates and target marks e.g. Skull). I don't know why the fuck the Escape key function calls this, and why the fuck this is protected, but this is handled already by code responsible for things like alt+z, cinematics, etc (I checked). This is probably just a safety net. However, if you do notice the absence of nameplates under any circumstances, it might be because of this addon. Let me know, and try to recall as many circumstances of this as possible, I'll do my best to fix it.
Now, once the addon is running, you need to actually add the double /stopcasting functionality to your escape key. Create a macro, call it "stahp", and put this in it:
/run ToggleGameMenu() /stopcasting /stopcastingThen, to bind Escape key to it (and avoid actionbar clutter), type this via chat:
/run SetBindingMacro("ESCAPE", "stahp") /run SaveBindings(2)Use (1) to save it to global keybindings, (2) to save it to character-specific keybindings.
Whoop de fucking doo, it works.
Sadly there's no way to bring the target canceling functionality along, since in the original code, it would do only 1 action at a time (i.e. first press stopcasts, 2nd press detargets), which is something you can't do with macros and protected functions. If you got the idea to just add /cleartarget to the macro, then sorry, that won't work (it'll just cleartarget on every single press).
Also if there's any interest to this, I'll fix a version which doesn't require you to make a macro or whatever, there are much cleaner ways to do this. I just cba because I forgot basically everything about WoW UI API and want to play instead of cleaning up code, you know. And this is more of a rant about shit working in a really awkward manner.