I'm trying it with eventscan and I'm not sure how to use it.
I'm capturing the event correctly from an even trigger in the bar auras, but the arg I receive is nil. Also I'm not sure I'm correctly setting the width.
First group custom growth function:
function(newPositions, activeRegions)
local totalWidth = math.min(220,(#activeRegions*40))
local width = math.min((totalWidth / #activeRegions),40)
WeakAuras.ScanEvents("ROTATION_WIDTH_ADJUST",totalWidth)
for i = 1, #activeRegions do
activeRegions[i].region:SetRegionWidth(width)
newPositions[i] = {
i*width - totalWidth/2 - width/2, -- x
0 -- y
}
end
end
And here's the trigger capturing the event:
function(event,totalWidth)
print(totalWidth)
--aura_env.region:SetRegionWidth(totalWidth)
end
At the moment it prints 'nil' three times, so I'm not passing the arg correclty :S