core/assets: add a way to deactivate sprite animation

This commit is contained in:
Kazhnuz 2019-02-15 18:30:23 +01:00
parent 1cc8acd4c3
commit d30f28322a

View file

@ -42,6 +42,8 @@ function Assets:new()
self:clearTileset() self:clearTileset()
self.images = {} self.images = {}
self.isActive = true
end end
function Assets:init() function Assets:init()
@ -68,7 +70,9 @@ function Assets:clear()
end end
function Assets:update(dt) function Assets:update(dt)
self:animationsUpdate(dt) if (self.isActive) then
self:animationsUpdate(dt)
end
end end
-- SFX et Musique -- SFX et Musique