Skip to content

Commit

Permalink
Removed LibHealComm for 2.5.2
Browse files Browse the repository at this point in the history
  • Loading branch information
d87 committed Sep 13, 2021
1 parent 31ddae5 commit e31a965
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 39 deletions.
1 change: 0 additions & 1 deletion .pkgmeta
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,4 @@ externals:
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
Libs/LibHealComm-4.0: https://github.com/Azilroka/LibHealComm-4.0.git
Libs/LibClassicDurations: https://repos.curseforge.com/wow/libclassicdurations
4 changes: 1 addition & 3 deletions Aptechka-BCC.toc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
## Interface: 20501
## Interface: 20502
## Title: Aptechka
## Notes: Raid Frames
## Version: @project-version@
Expand Down Expand Up @@ -26,8 +26,6 @@ Libs\LibAuraTypes\LibAuraTypes.lua
Libs\LibTargetedCasts\LibTargetedCasts.lua
Libs\LibTargeted\LibTargeted.lua

Libs\LibHealComm-4.0\LibHealComm-4.0.xml

helpers.lua
config.lua
config.tbc.lua
Expand Down
36 changes: 1 addition & 35 deletions Aptechka.lua
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ if apiLevel <= 2 then
UnitHasVehicleUI = dummyFalse
UnitInVehicle = dummyFalse
UnitUsingVehicle = dummyFalse
UnitGetIncomingHeals = dummy0
UnitGetTotalAbsorbs = dummy0
UnitGetTotalHealAbsorbs = dummy0
UnitPhaseReason = dummyFalse
Expand Down Expand Up @@ -359,22 +358,7 @@ function Aptechka.PLAYER_LOGIN(self,event,arg1)
end

if config.enableIncomingHeals then
if apiLevel <= 2 then
HealComm = LibStub:GetLibrary("LibHealComm-4.0",true);
local incomingHealIgnoreHots = true
if HealComm then
if incomingHealIgnoreHots then
HealComm.AptechkaHealType = HealComm.CASTED_HEALS
else
HealComm.AptechkaHealType = HealComm.ALL_HEALS
HealComm.RegisterCallback(self, "HealComm_HealUpdated", "HealUpdated"); -- hots
end
HealComm.RegisterCallback(self, "HealComm_HealStarted", "HealUpdated");
HealComm.RegisterCallback(self, "HealComm_HealStopped", "HealUpdated");
end
else
self:RegisterEvent("UNIT_HEAL_PREDICTION")
end
self:RegisterEvent("UNIT_HEAL_PREDICTION")
end

if LibClassicDurations then
Expand Down Expand Up @@ -1013,24 +997,6 @@ function Aptechka.UNIT_HEAL_PREDICTION(self,event,unit)
end

if apiLevel <= 2 then
function Aptechka:HealUpdated(event, casterGUID, spellID, healType, endTime, ...)
for i=1,select('#', ...) do
local targetGUID = select(i, ...)
local unit = guidMap[targetGUID]
if unit then
Aptechka:UNIT_HEAL_PREDICTION(nil, unit, targetGUID)
end
end
end

local incomingHealTimeframe = 3

GetIncomingHealsCustom = function (unit, excludePlayer)
local guid = UnitGUID(unit)
local heal = HealComm:GetHealAmount(guid, HealComm.AptechkaHealType, GetTime()+incomingHealTimeframe)
return heal or 0
end

function Aptechka.UNIT_HEAL_PREDICTION(self,event,unit)
self:UNIT_HEALTH(event, unit)

Expand Down

0 comments on commit e31a965

Please sign in to comment.