noble animations

This commit is contained in:
2024-06-02 20:25:27 +03:00
parent f19610e458
commit 3ca6427583
15 changed files with 218 additions and 192 deletions

View File

@@ -0,0 +1,28 @@
BigBoom = {}
class("BigBoom").extends(AnimatedSprite)
local bigBoomImageTable = Graphics.imagetable.new("assets/sprites/bigboom")
function BigBoom:init()
BigBoom.super.init(self, bigBoomImageTable)
-- Animation properties
self:addState("play", 1, 3, { tickStep = 4, loop = 3 })
self:setDefaultState("play")
self:playAnimation()
self:setCenter(0, 0)
self:setSize(playdate.display.getSize())
self:setZIndex(120)
self:moveTo(0, 0)
self:add()
end
function BigBoom:update()
self:updateAnimation()
end
function BigBoom:stopAnimation()
self:remove()
end