Merge branch 'update' of https://github.com/NoM0Re/WeakAuras-WotLK into update

This commit is contained in:
NoM0Re 2025-01-27 17:05:03 +01:00
commit 31bcef0dc7
3 changed files with 6 additions and 5 deletions

View file

@ -308,9 +308,9 @@ function lib.GetUnitNameplate(unit)
local nameplate = C_NamePlate.GetNamePlateForUnit(unit)
if nameplate then
-- credit to Exality for https://wago.io/explosiveorbs
if nameplate.unitFrame and nameplate.unitFrame.Health then
if nameplate.UnitFrame and nameplate.UnitFrame.Health then
-- elvui
return nameplate.unitFrame.Health
return nameplate.UnitFrame.Health
elseif nameplate.unitFramePlater and nameplate.unitFramePlater.healthBar then
-- plater
return nameplate.unitFramePlater.healthBar

View file

@ -2447,6 +2447,7 @@ local function removeNameplateUnits(data)
end
end
end
end
end
local oldDataStub = {
@ -2652,7 +2653,7 @@ function WeakAuras.PreAdd(data, snapshot)
end
validateUserConfig(data, data.authorOptions, data.config)
if not(WeakAuras.isAwesomeEnabled()) then
removeNameplateUnits(data)
removeNameplateUnitsAndAnchors(data)
end
data.init_started = nil
data.init_completed = nil

View file

@ -121,7 +121,7 @@ local function GetCustomTriggerOptions(data, triggernum)
end
elseif trueEvent:match("^UNIT_") then
local unit = string.lower(i)
if not (OptionsPrivate.Private.baseUnitId[unit] and OptionsPrivate.Private.multiUnitId[unit]) and not unit:find("^nameplate%d+$") then
if not ((OptionsPrivate.Private.baseUnitId[unit] and OptionsPrivate.Private.multiUnitId[unit]) or unit ~= "nameplate") then
return "|cFFFF0000"..L["Unit %s is not a valid unit for RegisterUnitEvent"]:format(unit)
end
elseif trueEvent == "TRIGGER" then
@ -169,7 +169,7 @@ local function GetCustomTriggerOptions(data, triggernum)
end
elseif trueEvent:match("^UNIT_") then
local unit = string.lower(i)
if not (OptionsPrivate.Private.baseUnitId[unit] or unit:find("^nameplate%d+$")) then
if not (OptionsPrivate.Private.baseUnitId[unit] or unit ~= "nameplate") then
return false
end
elseif trueEvent == "TRIGGER" then