Hm, GetSpellInfo will return the name of the buff, in this case "Tricks of the Trade". So using GetSpellInfo seems to be redundant, as it will only look for the name anyway.
Can you confirm that it works correctly, even if you yourself are a target of TotT?
The reason behind all this 'for macro stuff' is to only cancel the threat transferring buff, and not the damage increasing portion, which you might or might not have at the same time (and which for some stupid reason has the same name, "Tricks of the Trade").
I just gave it a try with /run CancelUnitBuff("player",GetSpellInfo(59628)), and it was able to remove both the threat transfer buff as well as the initial 30 second TotT buff. I didn't have another rogue nearby to give me tricks, but if the command can cancel two out of three buffs, it almost certainly will take out the third as well.
So, in conclusion: GetSpellInfo is done internally; it doesn't check your current buffs for specific spells/abilities.
As far as I can tell, the damage buff does not go away if the threat part of tricks is canceled. Also, I don't think /cancelaura would work 100%; each part of tricks is named the same, so there's the possibility of canceling your tricks before it activated or even canceling another rogue's tricks on you.
I've been using this when tricksing non rogues/tanks: (it is spammable, and will only cancel the threat part of tricks when it activates)
/script local p="player" for i=1,40 do local _,_,_,_,_,_,_,u,_,_,s=UnitBuff(p,i) if u==p and s==59628 then CancelUnitBuff(p,i) break end end
Reading the current conversation, it seems like it removes the buff on you (the threat buff) but keeps the dps buff on the other player, but if both rogues are using the same script, wouldn't the second rogue to cast it lose both buffs? Or are the buffs separate entities in the script?
Reading the current conversation, it seems like it removes the buff on you (the threat buff) but keeps the dps buff on the other player, but if both rogues are using the same script, wouldn't the second rogue to cast it lose both buffs? Or are the buffs separate entities in the script?
The script you're talking about removes this buff, which is the one that transfers threat. The damage increasing buff has a different ID and is unaffected.
Here's another macro which is a bit shorter on the /script part. With a few alterations, it now actually fits with my regular TotT macro (kind of, shortended that as well).
#showtooltip
/cast [@mouseover,help,nodead][help,nodead][@focus,help,nodead][@targettarget,help,nodead]Tricks of the Trade
/in 1 /run local p="player" for i=1,40 do if(select(11,UnitBuff(p,i))==59628)then CancelUnitBuff(p,i)end end
Note that /in is an Ace function, so it won't work without the Ace library (which you'll most like have anyway). /in 1 means that the following part will be run in 1 second.
Unrelated, but maybe somebody knows: is there a way to shorten this further, since the conditions "help,nodead" are repeating in each ... condition?
Also, I believe a /stopmacro [mod:shift] between those two lines would enable you to skip the cancelling part, e.g. when you're planning to use TotT on the tank. It didn't work for me though, because the macro itself wouldn't fire at all. I guess this is due to I'm already using ALT-E as the keybinding for the TotT macro, and SHIFT-ALT-E just didn't register as a key press for me. Maybe it's just Dominos preventing that, or modifiers in macros together with other modifiers as keybindings in general don't work, I don't know.
// Edit
Ok, it seems this is due to that I also have a SHIFT-E keybinding. Shift somehow takes precedence over Alt when pressing Alt and Shift simultaneously, for whatever reason, so that the game wants to use my SHIFT-E keybinding instead of running the macro. Or maybe it's just again Dominos that's behaving that way.
It should work though if you don't have the same setup as me.
I just finished writing an addon that alleviates the need for all these macro variations (I openly acknowledge that I may not be the first), but before I release it I want to change the topic slightly and discuss the future of Tricks of the Trade. I'm currently wondering what would happen if this does become a wipe spread practice, and how Blizzard would react if too many Rogues are exploiting Tricks of the Trade to reduce the threat transfer as much as possible. They could split the functionality like what they did with DK ghouls awhile back, or they could eliminate one of the two functions all together. Either of those two would clearly set back Rogue utility.
I'm also curious about other opinions on the "ethics" of this. I, for one, will be abusing this addon. I'm just not sure how many people agree with me that an addon to manipulate Tricks of the Trade is within the boundries of what Blizzard intended for us. I mean they did supply us with the API and functionality to do so, but this probably wasn't their goal for the ability and usage of it.
They could easily change it to a debuff instead, which cannot be clicked off.
In terms of an addon, you could even do something like this:
/run local p,f="player",CreateFrame("Frame",nil,UIParent);f:SetScript("OnUpdate",function() for i=1,40 do if (select(11,UnitBuff(p,i))==59628) then CancelUnitBuff(p,i) end end end)
Running this would initialize an "addon" that automatically removes the TotT threat buff as soon as you cast it. The downside of this and any other addon is that you now cannot use TotT on the tank anymore, since you wouldn't give him any threat.
This is why I prefer a macro for this, so I can control if the threat transfers. And to be honest, the only time I actually needed to cancel the threat transfer is with our Shadowmourne DK on Sindragosa.
Surely it can be done, via addon ofc, extension of what sp00n suggested will be to cancel the threat buff only if the unit you casted trix to (that better be captured via event instead of running through every player's buffs) is not tanking in the means of UnitDetailedThreatSituation("playerX", "target") and maybe there is 1 second after regen disabled event (so there is an actual tank)
Edit2: thats actually not a bad idea, will add to mah addon
I just finished writing an addon that alleviates the need for all these macro variations (I openly acknowledge that I may not be the first), but before I release it I want to change the topic slightly and discuss the future of Tricks of the Trade. I'm currently wondering what would happen if this does become a wipe spread practice, and how Blizzard would react if too many Rogues are exploiting Tricks of the Trade to reduce the threat transfer as much as possible. They could split the functionality like what they did with DK ghouls awhile back, or they could eliminate one of the two functions all together. Either of those two would clearly set back Rogue utility.
I'm also curious about other opinions on the "ethics" of this. I, for one, will be abusing this addon. I'm just not sure how many people agree with me that an addon to manipulate Tricks of the Trade is within the boundries of what Blizzard intended for us. I mean they did supply us with the API and functionality to do so, but this probably wasn't their goal for the ability and usage of it.
I'm just curious why people want this in the first place. My guild only has 8/12 HM (QQ exam finals and attendance problems) so maybe I'm missing something on LDW, Putricide, Sindy and LK, but in the nights where I'm the only rogue, only on Saurfang have I had to switch tricks targets because the original was getting high on threat. Even switching the difference b/w tricksing a target who does 15k damage and one who does 17k damage is a little more than 300 extra damage.
Unrelated, but maybe somebody knows: is there a way to shorten this further, since the conditions "help,nodead" are repeating in each ... condition?
The first point there would be to wonder whether all the "help, nodead"'s are absolutely neccesary. Do you occasionally focus a non-friendly target? Would there be any reasonable scenario where your TargetOfTarget is dead?
EDIT: Not 100% confident on this one, but would you even need to add any conditionals in the last "option", as they are only intended to let the macro skip to the next option if it'd fail?
Last edited by kargathia : 05/03/10 at 12:08 PM.
"...vincer potero dentro a me l'ardore
ch'i' ebbi a divenir del mondo esperto
e de li vizi umani e del valore"
The first point there would be to wonder whether all the "help, nodead"'s are absolutely neccesary. Do you occasionally focus a non-friendly target? Would there be any reasonable scenario where your TargetOfTarget is dead?
EDIT: Not 100% confident on this one, but would you even need to add any conditionals in the last "option", as they are only intended to let the macro skip to the next option if it'd fail?
the [help][nodead] would be useful if there are indeed situations where you would need to focus an enemy, and thereby would want to have it drop to the next priority in your macro, or if your focus dies. I would dispute the need for [nodead] on the target of target, as you would ideally want this to be the tank... and if the tank is dead, you probably want to tricks someone other than the mobs current target...
I use a priority system on mine to cast on a default rogue if I am missing a focus, since I change my focus during fights and can potentially lose it; or have to focus an enemy for focus interrupts and such.
#showtooltip
/cast [@mouseover,help,nodead][help,nodead][@focus,help,nodead][@targettarget,help,nodead]Tricks of the Trade
/in 1 /run local p="player" for i=1,40 do if(select(11,UnitBuff(p,i))==59628)then CancelUnitBuff(p,i)end end
...
Also, I believe a /stopmacro [mod:shift] between those two lines would enable you to skip the cancelling part, e.g. when you're planning to use TotT on the tank. It didn't work for me though, because the macro itself wouldn't fire at all. I guess this is due to I'm already using ALT-E as the keybinding for the TotT macro, and SHIFT-ALT-E just didn't register as a key press for me. Maybe it's just Dominos preventing that, or modifiers in macros together with other modifiers as keybindings in general don't work, I don't know.
Would it be possible to run those 2 lines as separate macros? Also, instead of putting the /stopmacro [mod], couldn't you just put the mod on the second line, making it such that 'e' fires the tricks, 'alt+e' would fire tricks, then cancelaura?
I know that if a macro [mod] shares slots with a keybind, the keybind takes precedence. I am not sure how that would work with multiple modifiers, but that sounds like it probably is what is causing the problem.
I would dispute the need for [nodead] on the target of target, as you would ideally want this to be the tank... and if the tank is dead, you probably want to tricks someone other than the mobs current target...
The instant the tank dies, the boss will have a new target, meaning your target of target will no longer be the tank. [nodead] can still be useful when applied to your focus target, but your target of target will never be dead because enemies do not target dead players.
@kargathia
Imagine a situation like Vezax hard mode. You need to burn down the add while maintaining a kick rotation on the general himself (using a focus kick macro). The TotT should of course also work in such fights, thus I'd like to keep the [help,nodead] part on the focus (and on the target and mouseover as well).
I agree though that you can eliminate the [nodead] part of targetoftarget.
@Zulkeir
I tried to use [mod] together with /in, with no joy, since /in is no official part of the WoW macro language but rather provided by the Ace framework.
So, currently I'm using two different macros, one with and one without the CancelUnitBuff part. Not an opitmal solution, but as long as Shift-E takes precedence over Alt-E with a Shift [modifier], there seems to be no way around this. Of course the explicit key binding Shift-Alt-E works just fine, but that's a seperate button and thus I need two macros.
As in my previous post it was expressed rather unclear: unless I overlooked something there is no need whatsoever for a conditional in the last "target", as it is the last option, and the conditionals are only intended to not let the macro fail completely when it fails to cast on any of these targets.
Along with that an idea would be reordering the macro to:
#showtooltip
/run local p="player" for i=1,40 do if(select(11,UnitBuff(p,i))==59628)then CancelUnitBuff(p,i)end end
/cast [@mouseover,help,nodead][help,nodead][@focus,help,nodead][@targettarget]Tricks of the Trade
It takes away the requirement for two separate macro's, and instead requires you to hit the button twice, once to cast tricks, once about a second later to remove the buff - if required.
EDIT: tested it myself, and it works like described.
Last edited by kargathia : 05/05/10 at 10:59 AM.
"...vincer potero dentro a me l'ardore
ch'i' ebbi a divenir del mondo esperto
e de li vizi umani e del valore"
As in my previous post it was expressed rather unclear: unless I overlooked something there is no need whatsoever for a conditional in the last "target", as it is the last option, and the conditionals are only intended to not let the macro fail completely when it fails to cast on any of these targets.
Along with that an idea would be reordering the macro to:
#showtooltip
/run local p="player" for i=1,40 do if(select(11,UnitBuff(p,i))==59628)then CancelUnitBuff(p,i)end end
/cast [@mouseover,help,nodead][help,nodead][@focus,help,nodead][@targettarget]Tricks of the Trade
It takes away the requirement for two separate macro's, and instead requires you to hit the button twice, once to cast tricks, once about a second later to remove the buff - if required.
EDIT: tested it myself, and it works like described.
I'm rather new here so forgive me, but I couldn't find the answer anywhere else.
Does this macro cancel the threat generating ID of only the following tott, or of all the totts used afterwords.
Meaning if I were to use this, and we were to wipe on that boss, could my initial tott at the opening of the next attempt be used to give the tank a threat lead?
I'm rather new here so forgive me, but I couldn't find the answer anywhere else.
Does this macro cancel the threat generating ID of only the following tott, or of all the totts used afterwords.
Meaning if I were to use this, and we were to wipe on that boss, could my initial tott at the opening of the next attempt be used to give the tank a threat lead?
It works as stated, you use the macro once to cast tricks, then use it once more to remove the threat transfer about a second later. The 2nd use has to be done every time you wish to stop the threat transfer. It does not keep doing it forever, it's on a per-use basis.
There is a fully functioning addon that does manage threat transfer aspects of Tricks of the Trade. Apologies to the mods if this should have been posted in the UI thread, however I felt the discussion here made this post relevant.
I've been trying to coerce Yawning into adding the autosync functionality (will turn on and off +threat to rogues based on whether or not it detects all other rogues running the addon), so if you have an interest in that please post a comment to him about it too.