It should work with
lua Code:
if ( UnitAura(unit, "Weakened Soul","HARMFUL") ) then
text = text .. format("|cffffff00%s|r", "WS")
end
Originally Posted by Terranell
As a side note, can anyone explain what the benefits are to ~= nil over == true in terms of checking auras?
|
UnitAura does not return a boolean - true/false - value, but
name, rank, icon, count, debuffType, duration, expirationTime, unitCaster, isStealable, shouldConsolidate, spellId
= UnitAura("unit", index or "name"[, "rank"[, "filter"]])
|
So you can not check for true, because it doesn't return true in its first return value (it's the name).
But a name - a string to be specific - is something different than "nil", so you can check if it is not nil.