diff options
| author | nathan <nathansmith@disroot.org> | 2025-12-18 10:23:19 +0000 |
|---|---|---|
| committer | nathan <nathansmith@disroot.org> | 2025-12-18 10:23:19 +0000 |
| commit | bcdd09d5075c9755538a93db8e3ca2690a803cc1 (patch) | |
| tree | 25a9e2e307bcc7d0908a81f7de6f365ab9230ff1 /src/entity.h | |
| parent | edaafadf2c5de7f23dfc20d420e973ed9dc92039 (diff) | |
| download | FindThings-bcdd09d5075c9755538a93db8e3ca2690a803cc1.tar.gz FindThings-bcdd09d5075c9755538a93db8e3ca2690a803cc1.tar.bz2 FindThings-bcdd09d5075c9755538a93db8e3ca2690a803cc1.zip | |
Finally getting interaction stuff done
Diffstat (limited to 'src/entity.h')
| -rw-r--r-- | src/entity.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/entity.h b/src/entity.h index 3a707c9..a71b5ff 100644 --- a/src/entity.h +++ b/src/entity.h @@ -7,6 +7,8 @@ #define ENTITY_COUNT 14 +#define ENTITY_NAME_MAX 16 + #define INTERACTION_MENU_MAX 9 #define INTERACTION_LABEL_MAX 6 #define INTERACTION_CHAT_MAX 256 @@ -53,7 +55,7 @@ enum Selection { SELECTION_INTERACT, SELECTION_NEXT_MESSAGE, SELECTION_MENU_ITEM, // +x to select any given menu entry - SELECTION_LEAVE + SELECTION_LEAVE = SELECTION_MENU_ITEM + 16 }; struct Entity { @@ -65,6 +67,7 @@ struct Entity { }; typedef struct { + char name[ENTITY_NAME_MAX]; InitEntityCallback initCallback; UpdateEntityCallback updateCallback; CloseEntityCallback closeCallback; @@ -81,6 +84,8 @@ Entity createEntity(EntityId id, Vector3 position); void updateEntity(Entity* entity, Game* game); void closeEntity(Entity* entity); +const char* getEntityName(EntityId id); + void setEntityPosition(Entity* entity, Vector3 position); void placeEntityOnGround(Entity* entity, const World* world); |
