Been trying to do a layout based on oUF_P3lim.
I make a frame for Power in my shared function, and I set
everything works fine at this point, no issues.
But if I then set
after previous line, the powerbar no longer updates the value. So even if I have 50% power, the bar is completely filled.
local function Shared(self, unit)
local Power = CreateFrame('StatusBar', nil, self)
Power.frequentUpdates = true
Power.colorClass = false
Power.colorPower = true
local PowerBG = Power:CreateTexture(nil, 'BORDER')
PowerBG.multiplier = .3
local PowerValue = Power:CreateFontString(nil, 'OVERLAY')
PowerValue:SetPoint('LEFT', 5, 0)
PowerValue.frequentUpdates = 0.1
local PowerPercent = Power:CreateFontString(nil, "OVERLAY")
PowerPercent:SetPoint("RIGHT", -5, 0)
PowerPercent.frequentUpdates = 0.1
Power.PowerPercent = PowerPercent
Power.bg = PowerBG
Power.PowerValue = PowerValue
self.Power = Power
self.Power.Smooth = true
||02-17-14 03:25 PM
Is oUF_Smooth listed under OptionalDeps in your layout's .toc?
Even if it's not, adding a "Smooth = true" key on your power bar shouldn't stop it from updating.
Most likely you are getting a Lua error. Install BugSack
Already have BugSack, it does not give me any error except for when I target a unit without power, but that is natural since I am not checking for it atm.
But yea, no lua errors in BugSack for player frame.
||02-18-14 01:07 PM
oUF should display an empty power bar when the unit has no power. Post that error.
Problem was that it was calling function from both embedded version and standalone version of oUF_Smooth. Found that out when I looked again at the LUA error that the directories were different for each call.
Thanks for the help, silly of me to not check this ^^
Also post your entire code, not some random snippet that itself references other parts of your code that you didn't post. :rolleyes:
|All times are GMT -6. The time now is 06:46 PM.
vBulletin © 2020, Jelsoft Enterprises Ltd
© 2004 - 2020 MMOUI