You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

menu.lua 577 B

3 years ago
3 years ago
3 years ago
3 years ago
1234567891011121314151617181920
  1. menu = Class{}
  2. local M = {}
  3. function menu.update(dt)
  4. if animationSecsLeft > 0 then
  5. animationSecsLeft = animationSecsLeft - dt
  6. end
  7. end
  8. function menu.draw(dt)
  9. if animationSecsLeft > 0 then
  10. love.graphics.setColor(1,1,1,1-1/(animationSecsLeft+0.000001))
  11. love.graphics.draw(logo, 0,0)
  12. else
  13. love.graphics.setFont(titlefont)
  14. love.graphics.printf("NuclearGravity", 0, 20, WINDOW_WIDTH, "center")
  15. menu:butt(buttons, WINDOW_WIDTH, WINDOW_HEIGHT, WINDOW_WIDTH/2, WINDOW_HEIGHT/2, 40, WINDOW_WIDTH/3)
  16. end
  17. end
  18. return menu