WoW API: UnitAura
Jump to navigation
Jump to search
This function will be introduced in Patch 3.0. It will serve as an all-in-one solution for querying unit buffs and debuffs. UnitBuff and UnitDebuff will serve as aliases with built-in harmful/helpful filters.
The new parameters and return values are: name, rank, icon, count, debuffType, duration, expirationTime, isMine, isStealable = UnitAura("unit", [index] or ["name", "rank"][, "filter"])
Parameters
Arguments
- unit
- String - The unit you want debuff information for.
- index
- Number - The index of the debuff to retrieve info for. Starts at 1, maximum 40.
- filter
- This parameter can be any of "HELPFUL", "HARMFUL", "PLAYER", "RAID", "CANCELABLE", "NOT_CANCELABLE". You can also specify several filters separated by a space or | character to chain multiple filters together (e.g. "HELPFUL|RAID" == helpful buffs that you can cast on your raid). By default UnitAura has "HELPFUL" as an implicit filter - you cannot get back BOTH helpful and harmful at the same time. Neither "HELPFUL" or "HARMFUL" have meaning for UnitBuff/UnitDebuff, and will be ignored.
Returns
- name
- String - The name of the spell or effect of the debuff. This is the name shown in yellow when you mouse over the icon.
- rank
- String - The rank of the spell or effect that caused the debuff. Returns "" if there is no rank.
- icon
- count
- Number - The number of times the debuff has been applied to the target. Returns 0 for any debuff which doesn't stack. ( Changed in 1.11 ).
- debuffType
- String - The type of the debuff: Magic, Disease, Poison, Curse, or nothing for those with out a type.
- duration
- Number - The full duration of the debuff in seconds; nil if the debuff was not cast by the player.
History
- Patch 3.0 combined UnitDebuff and UnitBuff into this command.