ecsnet
Loading...
Searching...
No Matches
ecs_types.h
1#ifndef ECS_TYPES_H
2#define ECS_TYPES_H
3
4#include <stdint.h>
5#include "config.h"
6#ifdef __cplusplus
7extern "C" {
8#endif
13typedef struct ecs_t ecs_t;
14
20typedef uint32_t entity_t;
21
27typedef uint32_t component_t;
28
38typedef uint64_t component_signature_t;
39
48typedef void (*system_func_t)(ecs_t *ecs, float dt);
49
58typedef void (*serialize_func_t)(const void *data_in, uint8_t *buffer_out);
59
68typedef void (*deserialize_func_t)(const uint8_t *buffer_in, void *data_out);
69
77typedef struct component_descriptor_t {
78 size_t size;
79 const char *name;
80 serialize_func_t serialize;
81 deserialize_func_t deserialize;
83
90
91#ifdef __cplusplus
92}
93#endif
94
95
96#endif
Definition ecs_types.h:77
const char * name
Definition ecs_types.h:79
serialize_func_t serialize
Definition ecs_types.h:80
deserialize_func_t deserialize
Definition ecs_types.h:81
size_t size
Definition ecs_types.h:78
Storage container for a single component type. Each registered component type gets its own storage st...
Definition ecs_internal.h:26
Internal structure representing the ECS world state. This holds:
Definition ecs_internal.h:44