diff options
| author | UnavailableDev <69792062+UnavailableDev@users.noreply.github.com> | 2023-04-03 11:39:08 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-04-03 11:39:08 +0200 |
| commit | 68862666219c07ee62c9e59dd6866c1c7b26cc00 (patch) | |
| tree | b0224b1516a362c27903efd4797f9bdf1a7eabc6 /src/engine/types.h | |
| parent | cc23564547b736125fe7e7869de277ea4d4455ab (diff) | |
| parent | f761624a95de538bb2be8f9449ed0edb8ae067ad (diff) | |
Merge pull request #49 from UnavailableDev/dev
Game stuff
Diffstat (limited to 'src/engine/types.h')
| -rw-r--r-- | src/engine/types.h | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/src/engine/types.h b/src/engine/types.h new file mode 100644 index 0000000..00b381b --- /dev/null +++ b/src/engine/types.h @@ -0,0 +1,44 @@ +#pragma once + +#include "engine/maths.h" + +typedef uint8_t hh_ppu_fg_idx; +// typedef uint16_t hh_bg_idx; + +typedef enum { + fire, ice, poison +}hh_e_damage_t; + + +typedef struct { + int8_t hp; + int8_t dmg; + hh_e_damage_t dmg_type; + int8_t speed_x, speed_y; + +} hh_s_atributes; + + +typedef struct { + hh_s_ppu_loc_fam_entry fam; //screen + uint16_t frame0; + uint16_t palette; + uint16_t ppu_foreground_index; + +}hh_s_rendering; + +typedef struct { + vec2 pos, vel, size; + bool is_grounded; + bool is_hit; + uint8_t radius; + int8_t hp; + int8_t speed; + hh_s_rendering render; + +}hh_entity; + +typedef struct { + hh_entity p; + hh_s_atributes atr; +}hh_s_player; |