From 99ab9bd22be2506c23d1e379f35583ddab4eadf6 Mon Sep 17 00:00:00 2001 From: zlago Date: Fri, 4 Oct 2024 21:38:14 +0200 Subject: map transitions --- src/loader.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/loader.h') diff --git a/src/loader.h b/src/loader.h index 61f9e3c..b16fd28 100644 --- a/src/loader.h +++ b/src/loader.h @@ -2,6 +2,7 @@ #include #include "entity.h" +#include "main.h" typedef char * name_T; @@ -11,8 +12,8 @@ struct blob { }; struct funs { - struct entity *(*newfun)(void); - int (*setfun)(struct entity *const restrict self, char const *const restrict key, char const *const restrict value); + void *(*newfun)(struct entities *entities); + int (*setfun)(void *const restrict self, char const *const restrict key, char const *const restrict value); }; void res_init(void); @@ -30,7 +31,7 @@ void res_free_collision(void); struct blob res_get_collision(name_T const name); void res_free_fun(void); -void res_push_fun(struct entity *(*newfun)(void), int (*setfun)(struct entity *const restrict self, char const *const restrict key, char const *const restrict value), name_T name); +void res_push_fun(void *(*newfun)(struct entities *entities), int (*setfun)(void *const restrict self, char const *const restrict key, char const *const restrict value), name_T name); struct funs res_get_fun(name_T const name); int loadResources(char *filename); -- cgit 1.4.1-2-gfad0