Moved code and assets for the game to a seperate folder. Moved jansson and raylib to third_party.

This commit is contained in:
2025-12-16 11:47:55 +01:00
parent fd2dbf232d
commit 8cdbd5b162
63 changed files with 14 additions and 14 deletions

43
src/game/shared/entity.h Normal file
View File

@@ -0,0 +1,43 @@
#ifndef ENTITY_H
#define ENTITY_H
#include <stdint.h>
#include <stdbool.h>
typedef uint16_t Entity_ID;
#define INVALID_ENTITY_ID (Entity_ID)65535
typedef enum {
Entity_Movement_Direction_None,
Entity_Movement_Direction_Up,
Entity_Movement_Direction_Down,
Entity_Movement_Direction_Right,
Entity_Movement_Direction_Left,
} Entity_Movement_Direction;
typedef enum {
Entity_Type_Snake_Head,
Entity_Type_Snake_Body,
Entity_Type_Food,
} Entity_Type;
typedef struct {
bool active;
// TODO: SS - Maybe add an ID here.
Entity_Type type;
uint16_t x;
uint16_t y;
uint16_t prev_x;
uint16_t prev_y;
Entity_Movement_Direction move_direction;
Entity_ID child;
} Entity;
#endif