Talk:API UnitAura
Back to page
UnitAura arguments
Edit
Nexiuz Asks:
It seems that this function doesn't have the rank anymore. Or at least the first 3 arguments are now Unit, Index, Filter (3th is filter, not the 4th). Can someone check this also and maybe check if the 4th argument is rank.
Kitjan Answers
The reference is a little confusing, but UnitAura works in two ways:
- "unit", index, "filter"
- "unit", "name", "rank", "filter"
Examples:
/script print(UnitAura("player", 1, "HELPFUL"))/script print(UnitAura("player", "Lightning Shield", nil, "HELPFUL"))/script print(UnitAura("player", "Lightning Shield", "Rank 2", "HELPFUL"))
I just verified that all three of those work (wow 3.3.5.12340) I have seen a couple addons try to hook UnitAura and only support the first form, which ended up breaking my addon.