#Raid Role Death Count

9 messages · Page 1 of 1 (latest)

summer elm
#

https://wago.io/CHVvKqqlN

This weakaura should (when it's finished) display how many of each role are dead in a raid

eg. 1 tank dead, 2 healers dead and 3 dps should be 1/2/3

But atm it doesn't work and was hoping someone here could help out?

Wago.io is a database of sharable World of Warcraft addon elements

summer elm
#

function()
local rolesTables = {}

rolesTables["TANK"] = 0
rolesTables["HEALER"] = 0
rolesTables["DAMAGER"] = 0

for i=1,40 do
    local role = UnitGroupRolesAssigned("raid" .. i)
    local dead = UnitIsDead('raid'.. i)
    if role ~= "NONE" and dead == true then
        rolesTables[role] = rolesTables[role] + 1
    end
end

aura_env.rolesTables = rolesTables
aura_env.trigger = rolesTables["TANK"] ~= 0 or rolesTables["HEALER"] ~= 0 or rolesTables["DAMAGER"] ~= 0

return aura_env.trigger

end

#

This is the code for the main trigger

astral olive
#

you check only when you die?

summer elm
#

The trigger updates on events, those events being when roles are assigned and when players die

summer elm
#

It works in combat if I set it to update every frame

#

but not on event

astral olive
#

because event tracks only when you die

summer elm