diff options
author | UnavailableDev <ggwildplay@gmail.com> | 2023-04-03 10:04:54 +0200 |
---|---|---|
committer | UnavailableDev <ggwildplay@gmail.com> | 2023-04-03 10:04:54 +0200 |
commit | 7373a9529659d4591e9fd921ef3a4771ec378965 (patch) | |
tree | 7d31d5bf353137e35d562bc18105a343174f75cf /src | |
parent | cd41b5310bc3cb14dc41f6abe7923ad14339fc9f (diff) |
misc/cleanup
Diffstat (limited to 'src')
-rw-r--r-- | src/engine/bullet.c | 2 | ||||
-rw-r--r-- | src/engine/draw_screen.c | 6 | ||||
-rw-r--r-- | src/engine/types.h | 8 |
3 files changed, 12 insertions, 4 deletions
diff --git a/src/engine/bullet.c b/src/engine/bullet.c index 5aa9e51..b97ed5c 100644 --- a/src/engine/bullet.c +++ b/src/engine/bullet.c @@ -22,7 +22,7 @@ void updateBullet(Bullet* bullet, int deltaTime){ if (bullet->x - latestLocationBullet > 32) { // Set bullet's status to inactive bullet->isActive = false; - drawBullet(&(Bullet){.x = -16,.y = -16. }); + drawBullet(&(Bullet){.x = -16,.y = -16}); } } else{ diff --git a/src/engine/draw_screen.c b/src/engine/draw_screen.c index 0c31bf6..a34a20b 100644 --- a/src/engine/draw_screen.c +++ b/src/engine/draw_screen.c @@ -1,6 +1,12 @@ #include "engine/draw_screen.h" #include "engine/sprite_controller.h" +static struct draw_screen +{ + void* levels[12] +}; + + uint8_t hh_world_to_tile(vec2 pos){ //TODO: remove magic file name here FILE* level = fopen("static/level1_test.bin", "rb"); /* open binary file */ diff --git a/src/engine/types.h b/src/engine/types.h index 241d706..00b381b 100644 --- a/src/engine/types.h +++ b/src/engine/types.h @@ -2,7 +2,8 @@ #include "engine/maths.h" -typedef uint8_t hh_idx_t; +typedef uint8_t hh_ppu_fg_idx; +// typedef uint16_t hh_bg_idx; typedef enum { fire, ice, poison @@ -20,8 +21,9 @@ typedef struct { typedef struct { hh_s_ppu_loc_fam_entry fam; //screen - hh_idx_t frame0; - hh_idx_t palette; + uint16_t frame0; + uint16_t palette; + uint16_t ppu_foreground_index; }hh_s_rendering; |