Threat-2.0
From WowAce Wiki
Contents
|
[edit]
Changes from Threat-1.0
[edit]
Internal changes
- All spell names are being replaces with spell IDs or tables of spell IDs. This removes the dependency on Babble-Spell, and provides implicit rank info.
- Class core API and transactional changes
- Transactions are no longer implicitly started. Instead, you start one by calling a transactional threat method.
- AddTargetThreat -> AddTargetThreatTransactional
- MultiplyTargetThreat -> MultiplyTargetThreatTransactional
- AddThreat -> AddThreatTransactional
- MultiplyThreat -> MultiplyThreatTransactional
- SetTargetThreat -> SetTargetThreatTransactional
- ReduceAllThreat -> ReduceAllThreatTransactional
- _addTargetThreat -> AddTargetThreat
- _multiplyTargetThreat -> MultiplyTargetThreat
- _addThreat -> AddThreat
- _multiplyThreat -> MultiplyThreat
- _setTargetThreat -> SetTargetThreat
- _reduceAllThreat -> ReduceAllThreat
- NPC modules now expect to be registered with NPCIDs
- NPC modules now have :RegisterSpellHandler(spell1ID, spell2ID, ..., spellNID, func)
- func is of the signature function(mobGUID, targetUnitID), where targetUnitID is "player" or "pet".
- ClassCore.SpecialCastHandlers -> ClassCore.CastLandedHandlers
- ClassCore.ClassBuffs -> ClassCore.BuffHandlers
[edit]
External Changes
- All interfaces that previously took unit names now take unit GUIDs
[edit]
:GetThreat("playerGUID", "targetGUID")
Returns a player's (or pet's) threat on a given target.
[edit]
Arguments
- "playerGUID"
- string - GUID of the party member to get threat for
- "targetGUID"
- string - GUID of the target to get threat on
[edit]
Returns
- integer - threat level of the given player (or pet) on the given target
[edit]
:IterateGroupThreatForTarget("targetGUID")
Gives you an iterator for the group's threat on a given target.
[edit]
Arguments
- "targetGUID"
- string - GUID of the target to get threat on
[edit]
Returns
- function - an iterator that can be used to iterate the group's threat on the given target
[edit]
:IteratePlayerThreat("playerGUID")
Gives you an iterator for the player's threat on all known targets.
[edit]
Arguments
- "playerGUID"
- string - GUID of the player to get threat for
[edit]
Returns
- function - an iterator that can be used to iterate the player's threat on all known targets
[edit]
:GetMaxThreatOnTarget("targetGUID")
Returns the maximum threat level on the target. This is not necessarily the threat of the aggro holder due to the 110%/130% aggro threshold.
[edit]
Arguments
- "targetGUID"
- string - GUID of the target to get max threat on
[edit]
Returns
- integer - maximum threat on this target.

