shrujus.lua 373 B

1234567891011121314
  1. Shrujus = extend(Manager)
  2. Shrujus.manages = 'shruju'
  3. function Shrujus:init()
  4. Manager.init(self)
  5. end
  6. function Shrujus:update()
  7. if not ctx.tutorial.active and tick % math.floor(1 / ls.tickrate) == 0 and love.math.random() < .0002 then
  8. self:add(data.shruju[love.math.random(1, #data.shruju)], {x = love.math.random(ctx.map.width)})
  9. end
  10. Manager.update(self)
  11. end