(50c0271)
[carveJwlIkooP6JGAAIwe30JlM.git] / entity.h
index d67c5f35d81683fda4bec559a5d7b344eb170357..80f4df7573fc7b62c440b9ba2cd29e4af024ddc4 100644 (file)
--- a/entity.h
+++ b/entity.h
@@ -38,6 +38,25 @@ typedef struct ent_list ent_list;
 typedef struct ent_glider ent_glider;
 typedef struct ent_npc ent_npc;
 
+typedef struct ent_call ent_call;
+struct ent_call{
+   u32 id;
+   i32 function;
+   void *data;
+};
+
+typedef enum entity_call_result entity_call_result;
+enum entity_call_result 
+{
+   k_entity_call_result_OK,
+   k_entity_call_result_unhandled,
+   k_entity_call_result_invalid
+};
+
+typedef enum entity_call_result 
+   (*fn_entity_call_handler)( world_instance *, ent_call *);
+
+
 enum entity_alias{
    k_ent_none        = 0,
    k_ent_gate        = 1,
@@ -527,13 +546,6 @@ struct ent_cubemap {
        framebuffer_id, renderbuffer_id, placeholder[2];
 };
 
-typedef struct ent_call ent_call;
-struct ent_call{
-   u32 id;
-   i32 function;
-   void *data;
-};
-
 struct ent_miniworld {
    mdl_transform transform;
    u32 pstr_world;