NeatPlates

NeatPlates

7M Downloads

Errors on retail

ihme opened this issue ยท 2 comments

commented

I have deleted the addon and cleared up leftover files to try and fix this error that is causing in-game lag.

`261x [string "--[==[ Error in 'NamePlateGlow - Unit TSU':..."]:134: Usage: :SetHeight(height)
[string "--[==[ Error in 'NamePlateGlow - Unit TSU':'initialization' ]==] return function() local aura_env = aura_env
local key = aura_env.id

aura_env.unitTable = {}
aura_env.iconTable = {}

local function deconstructIDs(unitIDs, iconIDs, index)
local units = {}
local icons = {}
for i in string.gmatch(unitIDs, "%d+") do
units[#units+1] = tonumber(i)
end
for i in string.gmatch(iconIDs, "%d+") do
icons[#icons+1] = tonumber(i)
end
for a, b in pairs(units) do
aura_env.unitTable[b] = {icons[a], index}
end
end
local i = 1
while i < 100 do
if(aura_env.config["unit" .. i]) then
deconstructIDs(aura_env.config["unit" .. i], aura_env.config["icon" .. i], i)
else
i = 100
end
i = i + 1
end

aura_env.autoGlowUnit = function(unit)
local GUID = UnitGUID(unit)
local tempID = select(6, strsplit("-", GUID))
local npcID = tonumber(tempID)
local frame = C_NamePlate.GetNamePlateForUnit(unit)
local index = 0;
local visibility = false;
if(aura_env.unitTable[npcID]) then
index = aura_env.unitTable[npcID][2] or 0
visibility = true;
local icon = aura_env.unitTable[npcID][1];
if(icon) then
aura_env.iconTable[icon] = (aura_env.iconTable[aura_env.unitTable[npcID][1]] or 0) + (visibility == true and 1 or -1)
end
end
aura_env.glow(aura_env.subFrame(frame), index, visibility)
end

aura_env.deGlowUnit = function(unit, addCount)
local frame = C_NamePlate.GetNamePlateForUnit(unit)
if(frame) then
aura_env.glow(aura_env.subFrame(frame), 0, false)
if(addCount == true) then
local GUID = UnitGUID(unit)
local tempID = select(6, strsplit("-", GUID))
local npcID = tonumber(tempID)
if(aura_env.unitTable[npcID]) then
local icon = aura_env.unitTable[npcID][1]
if(icon) then
aura_env.iconTable[icon] = (aura_env.iconTable[icon] or 0) - 1
end
end
end
end
end

local LCG = LibStub-1.0.2-70000("LibCustomGlow-1.0-15")
local glowTypes = {"Standard","Pixel","AutoCast"}
glowTypes[0] = "Clear"

aura_env.glow = function(frame,index,show)
local glowType = glowTypes[aura_env.config["glow"..index] or 0];
if show then
if glowType == "AutoCast" then
LCG.AutoCastGlow_Start(
frame,
aura_env.config["color"..index],
aura_env.config["particles"..index],
aura_env.config["frequency"..index],
aura_env.config["scale"..index],
0,
0,
key
)
elseif glowType == "Pixel" then
LCG.PixelGlow_Start(
frame,
aura_env.config["color"..index],
aura_env.config["particles"..index],
aura_env.config["frequency"..index],
aura_env.config["length"..index],
aura_env.config["thickness"..index],
0,
0,
false,
key
)
elseif glowType == "Standard" then
LCG.ButtonGlow_Start(
frame,
aura_env.config["color"..index],
aura_env.config["frequency"..index],
key
)
end
else
if glowType == "AutoCast" then
LCG.AutoCastGlow_Stop(frame, key)
elseif glowType == "Pixel" then
LCG.PixelGlow_Stop(frame, key)
elseif glowType == "Standard" then
LCG.ButtonGlow_Stop(frame, key)
elseif glowType == "Clear" then
LCG.AutoCastGlow_Stop(frame, key)
LCG.PixelGlow_Stop(frame, key)
LCG.ButtonGlow_Stop(frame, key)
end
end
end

aura_env.subFrame = function(nameplate)
if not nameplate then return end
if nameplate.unitFrame and nameplate.unitFrame.Health then
-- elvui
return nameplate.unitFrame.Health
elseif nameplate.unitFrame and nameplate.unitFrame.HealthBar then
-- elvui old
return nameplate.unitFrame.HealthBar
elseif nameplate.kui then
-- kui
return nameplate.kui.HealthBar
elseif nameplate.extended then
-- tidyplates
nameplate.extended.visual.healthbar:SetHeight(tidyplatesHeight)
return nameplate.extended.visual.healthbar
elseif nameplate.TPFrame then
-- tidyplates: threat plates
return nameplate.TPFrame.visual.healthbar
elseif nameplate.ouf then
-- bdNameplates
return nameplate.ouf.Health
elseif nameplate.UnitFrame then
-- default
return nameplate.UnitFrame.healthBar
else
return nameplate
end
end

if(aura_env.region.runOnce == nil) then
hooksecurefunc(WeakAuras, "OpenOptions", function()
for i=1,40 do
local unit = "nameplate"..i
aura_env.deGlowUnit(unit)
end
end)
end
aura_env.region.runOnce = 1
end"]:134: in function `subFrame'
[string "--[==[ Error in 'NamePlateGlow - Unit TSU':'initialization' ]==] return function() local aura_env = aura_env
local key = aura_env.id

aura_env.unitTable = {}
aura_env.iconTable = {}

local function deconstructIDs(unitIDs, iconIDs, index)
local units = {}
local icons = {}
for i in string.gmatch(unitIDs, "%d+") do
units[#units+1] = tonumber(i)
end
for i in string.gmatch(iconIDs, "%d+") do
icons[#icons+1] = tonumber(i)
end
for a, b in pairs(units) do
aura_env.unitTable[b] = {icons[a], index}
end
end
local i = 1
while i < 100 do
if(aura_env.config["unit" .. i]) then
deconstructIDs(aura_env.config["unit" .. i], aura_env.config["icon" .. i], i)
else
i = 100
end
i = i + 1
end

aura_env.autoGlowUnit = function(unit)
local GUID = UnitGUID(unit)
local tempID = select(6, strsplit("-", GUID))
local npcID = tonumber(tempID)
local frame = C_NamePlate.GetNamePlateForUnit(unit)
local index = 0;
local visibility = false;
if(aura_env.unitTable[npcID]) then
index = aura_env.unitTable[npcID][2] or 0
visibility = true;
local icon = aura_env.unitTable[npcID][1];
if(icon) then
aura_env.iconTable[icon] = (aura_env.iconTable[aura_env.unitTable[npcID][1]] or 0) + (visibility == true and 1 or -1)
end
end
aura_env.glow(aura_env.subFrame(frame), index, visibility)
end

aura_env.deGlowUnit = function(unit, addCount)
local frame = C_NamePlate.GetNamePlateForUnit(unit)
if(frame) then
aura_env.glow(aura_env.subFrame(frame), 0, false)
if(addCount == true) then
local GUID = UnitGUID(unit)
local tempID = select(6, strsplit("-", GUID))
local npcID = tonumber(tempID)
if(aura_env.unitTable[npcID]) then
local icon = aura_env.unitTable[npcID][1]
if(icon) then
aura_env.iconTable[icon] = (aura_env.iconTable[icon] or 0) - 1
end
end
end
end
end

local LCG = LibStub-1.0.2-70000("LibCustomGlow-1.0-15")
local glowTypes = {"Standard","Pixel","AutoCast"}
glowTypes[0] = "Clear"

aura_env.glow = function(frame,index,show)
local glowType = glowTypes[aura_env.config["glow"..index] or 0];
if show then
if glowType == "AutoCast" then
LCG.AutoCastGlow_Start(
frame,
aura_env.config["color"..index],
aura_env.config["particles"..index],
aura_env.config["frequency"..index],
aura_env.config["scale"..index],
0,
0,
key
)
elseif glowType == "Pixel" then
LCG.PixelGlow_Start(
frame,
aura_env.config["color"..index],
aura_env.config["particles"..index],
aura_env.config["frequency"..index],
aura_env.config["length"..index],
aura_env.config["thickness"..index],
0,
0,
false,
key
)
elseif glowType == "Standard" then
LCG.ButtonGlow_Start(
frame,
aura_env.config["color"..index],
aura_env.config["frequency"..index],
key
)
end
else
if glowType == "AutoCast" then
LCG.AutoCastGlow_Stop(frame, key)
elseif glowType == "Pixel" then
LCG.PixelGlow_Stop(frame, key)
elseif glowType == "Standard" then
LCG.ButtonGlow_Stop(frame, key)
elseif glowType == "Clear" then
LCG.AutoCastGlow_Stop(frame, key)
LCG.PixelGlow_Stop(frame, key)
LCG.ButtonGlow_Stop(frame, key)
end
end
end

aura_env.subFrame = function(nameplate)
if not nameplate then return end
if nameplate.unitFrame and nameplate.unitFrame.Health then
-- elvui
return nameplate.unitFrame.Health
elseif nameplate.unitFrame and nameplate.unitFrame.HealthBar then
-- elvui old
return nameplate.unitFrame.HealthBar
elseif nameplate.kui then
-- kui
return nameplate.kui.HealthBar
elseif nameplate.extended then
-- tidyplates
nameplate.extended.visual.healthbar:SetHeight(tidyplatesHeight)
return nameplate.extended.visual.healthbar
elseif nameplate.TPFrame then
-- tidyplates: threat plates
return nameplate.TPFrame.visual.healthbar
elseif nameplate.ouf then
-- bdNameplates
return nameplate.ouf.Health
elseif nameplate.UnitFrame then
-- default
return nameplate.UnitFrame.healthBar
else
return nameplate
end
end

if(aura_env.region.runOnce == nil) then
hooksecurefunc(WeakAuras, "OpenOptions", function()
for i=1,40 do
local unit = "nameplate"..i
aura_env.deGlowUnit(unit)
end
end)
end
aura_env.region.runOnce = 1
end"]:45: in function `autoGlowUnit'
[string "--[==[ Error in 'NamePlateGlow - Unit TSU' ]==] return function(allstates, event, unit)
if(event == "NAME_PLATE_UNIT_ADDED" and unit == nil) then -- WA Options closed
aura_env.iconTable = {}
for i = 1, 40 do
local unit = "nameplate"..i
aura_env.deGlowUnit(unit)
if UnitExists(unit) then
aura_env.autoGlowUnit(unit)
end
end
end
if event == "NAME_PLATE_UNIT_ADDED" and unit then
aura_env.autoGlowUnit(unit)
elseif event == "NAME_PLATE_UNIT_REMOVED" and unit then
aura_env.deGlowUnit(unit, true)
end

for icon, count in pairs(aura_env.iconTable) do
    if(count and icon) then
        local state = allstates[icon]
        if(count > 0) then
            if(not state) then
                state = {}
                allstates[icon] = state
            end
            state.show = true
            state.changed = true
            state.progressType = "static"
            state.icon = icon
            state.stacks = count
        else
            if(state) then
                state.show = false
                state.changed = true
            end
        end
    end
end

return true

end"]:13: in function <[string "--[==[ Error in 'NamePlateGlow - Unit TSU' ..."]:1>
[string "=[C]"]: in function xpcall' [string "@WeakAuras\GenericTrigger.lua"]:539: in function <WeakAuras\GenericTrigger.lua:532> [string "@WeakAuras\GenericTrigger.lua"]:721: in function ScanEventsInternal'
[string "@WeakAuras\GenericTrigger.lua"]:682: in function ScanEvents' [string "@WeakAuras\GenericTrigger.lua"]:826: in function <WeakAuras\GenericTrigger.lua:811>

commented

This error is from some weakaura you are using, I'd look into disabling it or checking if there is an update for it.

commented

Doing a bit of cleaning up and closing issues that are stale, or has been resolved by never confirmed to be resolved. If you believe this is in error, please comment and I'll re-open the issue again.