Bar now fully functional

This commit is contained in:
PhatDave
2021-11-12 16:33:03 +01:00
parent d66d6d6687
commit 180cd36eb2
4 changed files with 10 additions and 4 deletions

View File

@@ -3,7 +3,7 @@ function()
local target = select(5, CombatLogGetCurrentEventInfo()) local target = select(5, CombatLogGetCurrentEventInfo())
local buff = select(13, CombatLogGetCurrentEventInfo()) local buff = select(13, CombatLogGetCurrentEventInfo())
if target == UnitName("player") and aura_env.buffs[buff] ~= nil then if target == UnitName("player") and aura_env.buffs[buff] ~= nil then
aura_env.max = select(16, CombatLogGetCurrentEventInfo()) aura_env.max = aura_env.GetAbsorbs()
end end
end end
return true return true

View File

@@ -0,0 +1,3 @@
function()
return aura_env.GetAbsorbs(), aura_env.max, 1
end

View File

@@ -1,4 +1,7 @@
aura_env.buffs = {"Null Barrier", "Empowered Null Barrier"} aura_env.buffs = {
["Null Barrier"] = 1,
["Empowered Null Barrier"] = 1,
}
aura_env.max = 0 aura_env.max = 0
aura_env.GetBuff = function(name) aura_env.GetBuff = function(name)
@@ -17,8 +20,8 @@ end
aura_env.GetAbsorbs = function() aura_env.GetAbsorbs = function()
local abs = 0 local abs = 0
for k, v in ipairs(aura_env.buffs) do for k, v in pairs(aura_env.buffs) do
abs = abs + aura_env.GetAbsorb(v) abs = abs + aura_env.GetAbsorb(k)
end end
return abs return abs
end end