thirdparty: add support for superwow spell cast

This commit is contained in:
shagu
2024-05-09 10:49:03 +02:00
parent f7c8fdd886
commit 59878b3f8f
5 changed files with 56 additions and 0 deletions
+6
View File
@@ -90,6 +90,12 @@ pfUI:RegisterModule("castbar", "vanilla:tbc", function ()
cast, nameSubtext, text, texture, startTime, endTime, isTradeSkill = UnitChannelInfo(this.unitstr or this.unitname)
end
-- read enemy casts from SuperWoW if enabled
if superwow_active and this.unitstr and not UnitIsUnit(this.unitstr, 'player') then
local _, guid = UnitExists(this.unitstr)
cast, nameSubtext, text, texture, startTime, endTime, isTradeSkill = UnitCastingInfo(guid)
end
if cast then
local duration = endTime - startTime
local max = duration / 1000