This site works best with JavaScript enabled. Please enable JavaScript to get the best experience from this site.
What steps will reproduce the problem?1. Setup buff statuses in the SV-file for the same buff, once with mine=true, once with false, e.g. like this:["buffs"] = { ["vigilance"] = { "Vigilance", -- [1] false, -- [2] 0, -- [3] 0.6, -- [4] 0, -- [5] }, ["vigilance-mine"] = { "Vigilance", -- [1] true, -- [2] 0, -- [3] 1, -- [4] 0, -- [5] },},
2. Link an indicator to these statuses, e.g:["buffs"] = { ["corner-bottomleft"] = { ["buff-vigilance-mine"] = 99, ["buff-vigilance"] = 80, },},
3. Load Grid2
What is the expected output? What do you see instead?I would expect to see the color of the indicator whether the buff was cast by me or by someone else. Instead I get an error.
What version of the product are you using?r48
Do you have an error log of what happened?Message: ..\AddOns\Grid2\GridStatus.lua line 62: assertion failed!Debug: (tail call): ? [C]: assert() Grid2\GridStatus.lua:62: RegisterStatus() Grid2\GridDefaults.lua:181: SetupAuraStatus() Grid2\GridDefaults.lua:227: Setup()...
Please provide any additional information below.Maybe it is not intended to setup statuses like that, but I would like to have them this way and the problem is easily fixed.In GridDefaults.lua the status creation starts with:
function Grid2:SetupAuraStatus(setup) for name, info in pairs(setup.buffs ) do local name, mine = info[1], info[2] local status = self:CreateBuffStatus(name, mine) status.name = "buff-"..name -- force name
One can see that inside the for loop, the loop-variable name is shadowed by another local variable. If one of these variables gets renamed, i.e. like this:
for statusname, info in pairs(setup.buffs ) do local name, mine = info[1], info[2] local status = self:CreateBuffStatus(name, mine) status.name = "buff-"..statusname -- force name
the above setup works to my satisfaction.
Fixed in Revision 50
Thanks.
To post a comment, please login or register a new account.