mirror of
https://gitlab.com/MaddoScientisto/cirnofarm.git
synced 2026-06-03 23:25:55 +00:00
33 lines
No EOL
510 B
Lua
33 lines
No EOL
510 B
Lua
--local actor = require("actor2")
|
|
|
|
-- barrel = setmetatable({}, {__index = actor})
|
|
-- function barrel:new(actor)
|
|
-- local instance = setmetatable({
|
|
-- x = 0,
|
|
-- })
|
|
-- end
|
|
|
|
-- return barrel
|
|
|
|
barrel = {}
|
|
barrel.__index = barrel
|
|
function barrel:new(x,y)
|
|
local o = setmetatable({}, barrel)
|
|
o.x=x
|
|
o.y=y
|
|
o.life=100
|
|
o.spriteIndex=0
|
|
return o
|
|
end
|
|
|
|
function barrel:update()
|
|
|
|
end
|
|
|
|
function barrel:draw()
|
|
spr(self.spriteIndex,self.x,self.y)
|
|
end
|
|
|
|
--M.actor = actor
|
|
|
|
return barrel |