game.h 539 B

1234567891011121314151617181920212223242526272829
  1. #pragma once
  2. #include "engine/engine.h"
  3. // Screen size
  4. #define SCREEN_WIDTH 128
  5. #define SCREEN_HEIGHT 64
  6. // World size (3x3)
  7. #define WORLD_WIDTH 384
  8. #define WORLD_HEIGHT 192
  9. // from https://github.com/jamisonderek/flipper-zero-tutorials/blob/main/vgm/apps/air_labyrinth/walls.h
  10. typedef struct
  11. {
  12. bool horizontal;
  13. int x;
  14. int y;
  15. int length;
  16. } Wall;
  17. #define WALL(h, y, x, l) \
  18. (Wall) \
  19. { \
  20. h, x * 2, y * 2, l \
  21. }
  22. typedef struct
  23. {
  24. uint32_t score;
  25. } GameContext;