Refonte pour utiliser le systeme de GUI #112
1 changed files with 2 additions and 1 deletions
|
@ -37,6 +37,7 @@ function BaseWidget:new(menuName)
|
|||
self.canvas = {}
|
||||
self.canvas.texture = nil
|
||||
self.canvas.needRedraw = true
|
||||
self.canvas.isAnimated = false
|
||||
|
||||
self.order = 0
|
||||
self:register()
|
||||
|
@ -74,7 +75,7 @@ function BaseWidget:register()
|
|||
end
|
||||
|
||||
function BaseWidget:redraw()
|
||||
if (self.canvas.needRedraw) then
|
||||
if (self.canvas.needRedraw or self.canvas.isAnimated) then
|
||||
self:generateTexture()
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue