fpv/source/scripts/selectionSprite.lua
2024-06-10 01:50:27 +03:00

19 lines
441 B
Lua

Selection = {}
class("Selection").extends(NobleSprite)
function Selection:init(x, y)
Selection.super.init(self, "assets/sprites/selectionanim", true)
-- Animation properties
self.animation:addState("run", 1, 11)
self.animation.run.frameDuration = 1
self.animation:setState("run")
-- Collision properties
self:setZIndex(ZIndex.alert)
self:setSize(41, 40)
self:add()
self:moveTo(x or 0, y or 0)
end