Всем Привет, немного не по адрессу, но нужно обновление аддона под Dragon Flight, до выхода 10.0 все работало много лет. Помогите обновить.
hooksecurefunc("TargetFrame_UpdateAuraPositions", function(self, auraName, numAuras, numOppositeAuras,largeAuraList, updateFunc, maxRowWidth, offsetX)
local AURA_OFFSET_Y = 3
local LARGE_AURA_SIZE = 30 — развер ВАШИХ баффов/дебаффов.
local SMALL_AURA_SIZE = 20 — развер чужих баффов/дебаффов.
local size
local offsetY = AURA_OFFSET_Y
local rowWidth = 0
local firstBuffOnRow = 1
for i=1, numAuras do
if ( largeAuraList[i] ) then
size = LARGE_AURA_SIZE
offsetY = AURA_OFFSET_Y + AURA_OFFSET_Y
else
size = SMALL_AURA_SIZE
end
if ( i == 1 ) then
rowWidth = size
self.auraRows = self.auraRows + 1
else
rowWidth = rowWidth + size + offsetX
end
if ( rowWidth > maxRowWidth ) then
updateFunc(self, auraName, i, numOppositeAuras, firstBuffOnRow, size, offsetX, offsetY)
rowWidth = size
self.auraRows = self.auraRows + 1
firstBuffOnRow = i
offsetY = AURA_OFFSET_Y
else
updateFunc(self, auraName, i, numOppositeAuras, i - 1, size, offsetX, offsetY)
end
end
end)

hooksecurefunc("ActionButton_OnEvent",function(sel f, event, ...)
if ( event == "PLAYER_TARGET_CHANGED" ) then
self.newTimer = self.rangeTimer
end
end)

hooksecurefunc("ActionButton_UpdateUsable",functio n(self)
local icon = _G[self:GetName().."Icon"]
local valid = IsActionInRange(self.action)

if ( valid == false ) then
icon:SetVertexColor(1.0, 0.1, 0.1)
end
end)

hooksecurefunc("ActionButton_OnUpdate",function(se lf, elapsed)
local rangeTimer = self.newTimer

if ( rangeTimer ) then
rangeTimer = rangeTimer - elapsed

if ( rangeTimer <= 0 ) then
ActionButton_UpdateUsable(self)
rangeTimer = TOOLTIP_UPDATE_TIME
end

self.newTimer = rangeTimer
end
end)

hooksecurefunc("PlayerFrame_UpdateStatus", function()
if IsResting("player") then
PlayerStatusTexture:Hide()
PlayerRestIcon:Hide()
PlayerRestGlow:Hide()
PlayerStatusGlow:Hide()
elseif PlayerFrame.inCombat then
PlayerStatusTexture:Hide()
PlayerAttackIcon:Hide()
PlayerRestIcon:Hide()
PlayerAttackGlow:Hide()
PlayerRestGlow:Hide()
PlayerStatusGlow:Hide()
PlayerAttackBackground:Hide() end end)

PlayerPrestigeBadge:SetAlpha(0)
PlayerPrestigePortrait:SetAlpha(0)
TargetFrameTextureFramePrestigeBadge:SetAlpha(0)
TargetFrameTextureFramePrestigePortrait:SetAlpha(0 )
FocusFrameTextureFramePrestigeBadge:SetAlpha(0)
FocusFrameTextureFramePrestigePortrait:SetAlpha(0)