hexyz is tower defense game, and a lua library for dealing with hexagonal grids
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.

31 lines
1.1 KiB

4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
  1. function load_textures()
  2. TEX_MARQUIS = am.texture2d("res/marquis.png")
  3. TEX_BUTTON1 = am.texture2d("res/button1.png")
  4. TEX_WIDER_BUTTON1 = am.texture2d("res/wider_button1.png")
  5. TEX_TAB_ICON = am.texture2d("res/tab_icon.png")
  6. TEX_ARROW = am.texture2d("res/arrow.png")
  7. TEX_RADAR1 = am.texture2d("res/radar.png")
  8. TEX_SATELLITE = am.texture2d("res/satelite.png")
  9. TEX_WALL_CLOSED = am.texture2d("res/wall_closed.png")
  10. TEX_MOAT1 = am.texture2d("res/moat1.png")
  11. TEX_TOWER1 = am.texture2d("res/tower1.png")
  12. TEX_TOWER2 = am.texture2d("res/tower2.png")
  13. TEX_MOB1_1 = am.texture2d("res/mob1_1.png")
  14. TEX_MOB2_1 = am.texture2d("res/mob2_1.png")
  15. end
  16. function pack_texture_into_sprite(texture, width, height)
  17. return am.sprite{
  18. texture = texture,
  19. s1 = 0, s2 = 1, t1 = 0, t2 = 1,
  20. x1 = 0, x2 = width, width = width,
  21. y1 = 0, y2 = height, height = height
  22. }
  23. end