Thread Tools Display Modes
10-21-14, 06:28 AM   #1
duhwhat
A Wyrmkin Dreamwalker
Join Date: Aug 2008
Posts: 51
Secure Ability Toggle... in reverse!

Would it be possible, via add ons, to give DE toggle protection to abilities, or in effect, retoggle prevention. When trying to cancel Burning Rush or Blade Flurry, I often end up retoggling the ability. Just as Secure Ability Toggle gives you a minicooldown on the ability to prevent immediate canceling, I need something that will give me a mini cooldown after canceling the effect, so as to prevent immediate reactivation.
  Reply With Quote
10-21-14, 07:34 AM   #2
Duugu
Premium Member
 
Duugu's Avatar
AddOn Author - Click to view addons
Join Date: Nov 2006
Posts: 851
With default action bars? Or bound to a key? Or click casting?
  Reply With Quote
10-21-14, 08:38 AM   #3
semlar
A Pyroguard Emberseer
 
semlar's Avatar
AddOn Author - Click to view addons
Join Date: Sep 2007
Posts: 1,060
You couldn't really do this securely because you can't get any time information in the secure environment.

You could block the mouse from being able to click on the button temporarily after you de-activate it or you could probably intercept all key presses briefly after canceling the buff by auto-focusing an edit box.

It might be a better idea to just bind /cancelaura to something if you only want to remove the buff.
  Reply With Quote
10-21-14, 09:10 AM   #4
duhwhat
A Wyrmkin Dreamwalker
Join Date: Aug 2008
Posts: 51
This would be a keybind yes. I realize that this is hard or even impossible to implement. Yes, the cancelaura is a solution, but unfortunately requires an extra bind. Oh well. So close, yet so far away. Interested in a proof of concept semlar?
  Reply With Quote
10-21-14, 09:16 AM   #5
Tonyleila
A Molten Giant
 
Tonyleila's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2010
Posts: 758
Originally Posted by duhwhat View Post
Would it be possible, via add ons, to give DE toggle protection to abilities, or in effect, retoggle prevention. When trying to cancel Burning Rush or Blade Flurry, I often end up retoggling the ability. Just as Secure Ability Toggle gives you a minicooldown on the ability to prevent immediate canceling, I need something that will give me a mini cooldown after canceling the effect, so as to prevent immediate reactivation.
Blade Flurry has an 9 sec CD after you disable it I don't know about Burning Rush thought

If you write a macro with the /cast and rewrite the abilitie as often as possible it will add a very short (only some ms) cooldown to it.
__________________
Author of: LeilaUI and Aurora: Missing Textures
__________________
  Reply With Quote
10-21-14, 09:39 AM   #6
sirann
A Flamescale Wyrmkin
Join Date: Mar 2007
Posts: 142
/cast [nomod] !Blade Flurry
/cancelaura [mod:shift] Blade Flurry

Spammable macro to turn it on, shift modifier to turn it off. That's what I do, as for a one key solution, that could be a lot trickier/nigh on impossible.
  Reply With Quote
10-21-14, 09:41 AM   #7
duhwhat
A Wyrmkin Dreamwalker
Join Date: Aug 2008
Posts: 51
Originally Posted by Tonyleila View Post
Blade Flurry has an 9 sec CD after you disable it I don't know about Burning Rush thought

If you write a macro with the /cast and rewrite the abilitie as often as possible it will add a very short (only some ms) cooldown to it.
Basically, if I have blade flurry active and I want to cancel it, and I am a little twitchy (admittedly) so the keypress to cancel the effect will sometimes end up being a double tap, thereby turning it back on when I wanted to turn it off. Hence, I need secure ability toggle in reverse: prevent an ability from being activated for a short time (think burning rush's pseudo gcd) after being cancelled.
  Reply With Quote
10-21-14, 10:31 AM   #8
sirann
A Flamescale Wyrmkin
Join Date: Mar 2007
Posts: 142
The problem(s) you're running into would probably just be easiest to alleviate by using a different hot key to cancel it.
  Reply With Quote
10-21-14, 10:46 AM   #9
semlar
A Pyroguard Emberseer
 
semlar's Avatar
AddOn Author - Click to view addons
Join Date: Sep 2007
Posts: 1,060
Originally Posted by duhwhat View Post
Interested in a proof of concept semlar?
Can't really test anything with the servers down but something like this..
Lua Code:
  1. local ShouldBlock = { -- [spellID] = spellName, List of spells to activate on
  2.     [111400] = 'Burning Rush',
  3.     [13877] = 'Blade Flurry',
  4. }
  5.  
  6. local LOCKDOWN_LIMIT = 0.2 -- Seconds to block keypresses after casting a spell on the list
  7. local Lockdown = CreateFrame('Frame')
  8. Lockdown:Hide()
  9. Lockdown:SetPropagateKeyboardInput(false)
  10.  
  11. local TimeSince = 0
  12. Lockdown:SetScript('OnUpdate', function(self, elapsed)
  13.     TimeSince = TimeSince + elapsed
  14.     if TimeSince >= LOCKDOWN_LIMIT then self:Hide() end -- Stop blocking input
  15. end)
  16.  
  17. Lockdown:SetScript('OnKeyDown', function() end)
  18.  
  19. Lockdown:SetScript('OnEvent', function(self, unitID, spellName, _, _, _, spellID)
  20.     if ShouldBlock[spellID] then -- We just cast a spell on the list
  21.         TimeSince = 0
  22.         self:Show() -- Start blocking input
  23.     end
  24. end)
  25. Lockdown:RegisterUnitEvent('UNIT_SPELLCAST_SUCCEEDED', 'player')
Should briefly block ALL key presses after you successfully cast one of the spells on the list.

Won't prevent mouse buttons though, if that's a problem.

Last edited by semlar : 10-21-14 at 12:27 PM.
  Reply With Quote
10-21-14, 03:18 PM   #10
duhwhat
A Wyrmkin Dreamwalker
Join Date: Aug 2008
Posts: 51
I'm curious, could it block key presses after an arbitrary command? Such as execute /cancelaura blade flurry? Also, this will still allow mouse running during the block?
  Reply With Quote
10-21-14, 03:26 PM   #11
duhwhat
A Wyrmkin Dreamwalker
Join Date: Aug 2008
Posts: 51
Originally Posted by sirann View Post
The problem(s) you're running into would probably just be easiest to alleviate by using a different hot key to cancel it.
Of course... But this adds an extra bind.
  Reply With Quote
10-21-14, 05:14 PM   #12
semlar
A Pyroguard Emberseer
 
semlar's Avatar
AddOn Author - Click to view addons
Join Date: Sep 2007
Posts: 1,060
Originally Posted by duhwhat View Post
I'm curious, could it block key presses after an arbitrary command? Such as execute /cancelaura blade flurry? Also, this will still allow mouse running during the block?
Yes, the problem is it blocks all key presses, which generally is going to interfere with gameplay.
  Reply With Quote

WoWInterface » AddOns, Compilations, Macros » AddOn Search/Requests » Secure Ability Toggle... in reverse!


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