| Threat Meters in WLK
To answer all the speculation: The Technical This is based off of the current WLK beta build. Things could change between now and release
There are two threat functions, tied to events that fire during combat (UNIT_THREAT_LIST_UPDATE, UNIT_THREAT_SITUATION_UPDATE)
First, they define two terms: raw percentage The percentage of the threat when divided by he threat of the mob's current primary target. Using raw percentage You will pull aggro when your threat percentage is 110%/130% scaled percentage Your theat scaled such that 100% means you will pull aggro, and thus this % cannot be higher than 100% under normal circumstances. (That is, this one has been divided by 110% or 130% as appropriate.)
Now, two functions: state = UnitThreatSituation(unit, mob)
Returns the unit's "threat situation" with respect to the given mob.
state can be one of the following values:
nil = you aren't on the mob's hatelist
0 = you are not tanking and are under 100% raw threat (good to go)
1 = you are in the 100-110% or 100-130% range (danger)
2 = you are currently the aggro target, hopefully the tank, but someone is catching up and has passed 100% of your threat
3 = you are currently the aggro target, and everyone else is under 100% threat isTanking, state, scaledPercent, rawPercent, threatValue = UnitDetailedThreatSituation(unit, mob)
Returns several values with detailed information about your threat for the mob: isTanking is true if the unit the primary target of the mob state is the unit's threat situation, as above. scaledPercent is the current percent threat of the unit, scaled in the 0-100% range based on distance from target. rawPercent is the current percent threat of the unit relative to the primary target of the mob. threatValue is the amount of threat that the unit has on the mob's threat list. This is roughly approximate to the amount of damage and healing the unit has done. How that plays out in game
As far as I can tell, the default UI implements only a simple graphic threat indicator on the unit frames, based on your threat situation (the first function above):
0 = No indicator (why not a green indicator, I dunno)
1 = Yellow indicator
2 = Orange indicator
3 = Red indicator
That's pretty simple and will do for many people.
Some people will want more, of course, so they have provided the detailed function which will allow Omen to keep going and be much simplified than it is currently, and also make it a lot easier for alternative addons to be created.
The biggest simplification is the threatValue return from the UnitDetailedThreatSituation. That alone will remove a huge amount of code from Omen, since it no longer needs to calculate itself. Omen really just becomes a fancier display wrapper for these functions than the simple one Blizzard provides in the default UI, which is in line with the base UI design policy.
I'm sure we'll see a number of Omen alternatives released with varying degrees of complexity. I'll probably be looking for something that gives a top-10 name/percentage list and that will be that.
Edit: Some have commented on a screenshot that's going around showing an apparent threat indicator in floating combat text. I can find nothing like that in the code for Blizzard's default UI combat text, so I can only assume it is from a beta version of SCT/Parrot/Mik's
|