Thread Tools Display Modes
09-20-10, 06:44 AM   #1
yj589794
A Rage Talon Dragon Guard
AddOn Author - Click to view addons
Join Date: Mar 2009
Posts: 314
Vengeance (Tanking Specialization)

Hiya everyone,

I've been looking at writing a small mod to be able to handle the stacking Attack Power buff that tanks get when receiving damage.


Has anyone seen any API calls that could give the current Attack Power increase from this buff?

Scanning the aura tooltip is an option, but I would prefer not to do this.


Thanks
 
09-20-10, 06:46 AM   #2
zork
A Pyroguard Emberseer
 
zork's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2008
Posts: 1,740
Maybe it's static and you can multiply the number of stacks with sth.

*errr* you don't.

http://cata.wowhead.com/spell=84839

Each time you take damage, you gain 5% of the damage taken as attack power, up to a maximum of 10% of your health.
Maybe UnitAura has a new value as result. You could print all the UnitAura values and see if there is anything valuable in there.
__________________
| Simple is beautiful.
| WoWI AddOns | GitHub | Zork (WoW)

"I wonder what the non-pathetic people are doing tonight?" - Rajesh Koothrappali (The Big Bang Theory)

Last edited by zork : 09-20-10 at 06:50 AM.
 
09-20-10, 06:51 AM   #3
yj589794
A Rage Talon Dragon Guard
AddOn Author - Click to view addons
Join Date: Mar 2009
Posts: 314
Unfortunately it does not appear to stack in the normal way.

As each 'stack' is based off the amount of damage taken, then the buff value is extremely dynamic.

My guess is that there is a server side calculation, and the client gets told of the new AP value.

Tooltip scanning is a nasty cludge, and I'd prefer to have a nice API call. Unfortunately I believe it will not be that easy
 
09-20-10, 06:52 AM   #4
zork
A Pyroguard Emberseer
 
zork's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2008
Posts: 1,740
If Blizzard has to do it aswell: maybe some hint can be found in FrameXML/BuffFrame.lua, who knows.

Oh...hmm
http://www.wowwiki.com/API_GameTooltip_SetUnitAura
http://wowprogramming.com/docs/widge...ip/SetUnitAura

So the tooltip is actually done server side.

But maybe there is a new value in http://wowprogramming.com/docs/api/UnitAura that has the numbers.
__________________
| Simple is beautiful.
| WoWI AddOns | GitHub | Zork (WoW)

"I wonder what the non-pathetic people are doing tonight?" - Rajesh Koothrappali (The Big Bang Theory)

Last edited by zork : 09-20-10 at 07:01 AM.
 
09-20-10, 07:15 AM   #5
yj589794
A Rage Talon Dragon Guard
AddOn Author - Click to view addons
Join Date: Mar 2009
Posts: 314
Hmmm, quick google search brought this up:
New in Cataclysm:
Code:
local spellAuraDesc = GetSpellAuraDescription(spellId)
which was swiftly followed by this:
Originally Posted by Adirelle
Wait, what ? Is that a way to get information without tooltip scanning ?
Indeed. Sadly, the last beta removed the single use of this function in the default UI, so this new API might never make it to release, but it allows to get the description text of the Aura related to a given spell. It was used in the Talent UI to get the different Mastery descriptions.

So close to something useful, will have to check if it does still exist.
 
09-20-10, 03:39 PM   #6
yj589794
A Rage Talon Dragon Guard
AddOn Author - Click to view addons
Join Date: Mar 2009
Posts: 314
I've done some testing tonight, and UNIT_AURA does fire on a change of the Attack Power value from the Vengeance buff.

It's fairly simple to read the value by scanning the tooltip, but I would still prefer to have a direct API call to retrieve the value.
I'll carry out some further testing when I have more time.
 
 

WoWInterface » AddOns, Compilations, Macros » Cataclysm Beta » Vengeance (Tanking Specialization)


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