Skip to content

Commit

Permalink
Setup for LibAbsorbCounter in Cataclysm
Browse files Browse the repository at this point in the history
  • Loading branch information
d87 committed May 14, 2024
1 parent d709901 commit bc85a3e
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .pkgmeta
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ externals:
Libs/LibAuraTypes:
url: https://github.com/rgd87/LibAuraTypes.git
tag: master
Libs/LibAbsorbCounter:
url: https://github.com/rgd87/LibAbsorbCounter.git
tag: master
Libs/LibDataBroker-1.1: https://github.com/tekkub/libdatabroker-1-1.git
Libs/LibDBIcon-1.0: https://repos.wowace.com/wow/libdbicon-1-0/trunk/LibDBIcon-1.0
Libs/LibTranslit-1.0: https://github.com/Vardex/LibTranslit.git
2 changes: 2 additions & 0 deletions Aptechka-Cata.toc
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ Libs\LibAuraTypes\LibAuraTypes.lua
Libs\LibTargetedCasts\LibTargetedCasts.lua
Libs\LibTargeted\LibTargeted.lua

Libs\LibAbsorbCounter\LibAbsorbCounter.lua

helpers.lua
config.lua
config.cata.lua
Expand Down
9 changes: 9 additions & 0 deletions Aptechka.lua
Original file line number Diff line number Diff line change
Expand Up @@ -600,6 +600,15 @@ function Aptechka.PLAYER_LOGIN(self,event,arg1)
self:RegisterEvent("UNIT_ABSORB_AMOUNT_CHANGED")
self:RegisterEvent("UNIT_HEAL_ABSORB_AMOUNT_CHANGED")
end
if apiLevel == 4 then
local LAC = LibStub("LibAbsorbCounter")
UnitGetTotalAbsorbs = function(unit)
return LAC:UnitGetTotalAbsorbs(unit)
end
LAC.RegisterCallback(self, "UNIT_ABSORB_AMOUNT_CHANGED", function(event, unit)
self:UNIT_ABSORB_AMOUNT_CHANGED(event, unit)
end)
end

self:UpdateTargetedCountConfig()
self:UpdateIncomingCastsConfig()
Expand Down

0 comments on commit bc85a3e

Please sign in to comment.