Hello folks.
I'm trying to do up a text aura in weakauras that will change color when I need to taunt off my cotank. I've got everything working about the aura except the color change. I dug up this old thread via google, but despite the function not throwing any errors, I can't figure out why it isn't changing color.
I have the main color set to white and the "animation" color set to red, with the following under "Custom Function":
Code:
function(r1,g1,b1,a1,r2,g2,b2,a2)
local status = UnitThreatSituation("player", "target")
if status==0 then return r1,g1,b1,a1 else return r2,g2,b2,a2 end
end
Probably-irrelevant details:
The aura itself triggers when it checks my cotank for a tank-swap mechanic debuff (Static Burst is what I'm using to start). It displays a small line of text stating he has Static Burst, with a %c that displays "TAUNT!" if I'm in threat status 0 (not tanking + lower on aggro table). This part works fine, but I am using nearly-identical code to change the color, and it's not working. I'm sure I'm missing something simple and would appreciate any help.
For the sake of testing whether my code even works in the first place, I set up this one to tool around Vale of Eternal Blossoms taunting random unfortunate critters and beasts. If it works, it should always be either a red 3 or a white ?.
Code:
dGZ8caGEvbTlHITPKmBL63q(gqomj7eK2R0UjSFrJsvQ)sjmoHQlR48eLbRYWrOdQKItbGJHOZbqluvvlvjvwSQklhQfbupLQhdQNl40KAQizYkX0r9qHsUQQqpJOY1PyJuI(Sq2mi2UQIpQKsZcPMgG(UsQAzezyusJMs14vLCjvbUfrvxtvP7PkALuk)uOu3gbxYsvNq9L6lLQoeKGD9dNcDv86l6aXTsg18IR)a46WMaJiqnV46qmcywJeVbiTLxE5L3gbR25fyfBc59mVhfAMYoEuSRzJI1iXBWe3kzdgmDEGzfoAyWaK2YlV8YdpSblYlWk2esBJyPUsOjOynsuQ6euArPQZYio1HnbgrOUjmwaJ2iC)xhgTr4)fQ16WOncV2c1ADy0gHT0iGRJh2Gf5bXiGzns8gtshrs)JKwrsJLOJKO)jrRKaiTLxE5L3gbR25fyfBc59mVhfAMYoEuSRzJI1iXBWe3kzdgmDEGzfoAyWaK2YlV8YtdjVaRyt45t5YJTpI8WdBWI8Ws0rs0)KOvs5n7WKhEydwKhMKoIK(hjTImVrSK2gXsDy0gHxtHswhgTr41vOK1HrBeMsgXPoSjWicLlxNX6OObxQ6SmIt9aRytO(8zeC9yHelAwJeH6MWyHrO5(VUjmwO26pt)x3iMpJGRRmmQCD8ePrckzeN688IRVE9cBVw(DvCjjqsYjhqjGacyCGfI8abvxyiqH1rrdouOK11l15jW1Tp6i7CTeiO4FTc67kqGIljbiOvfI8axv)vSHajmCHkp5xR13i1sPQJr7Pu1jy2SUuLlxUC9qDYyagdOyaS(NcLeOvRLBba
Thanks in advance.