1 #ifndef __MODULE_LOAD_H__
2 #define __MODULE_LOAD_H__
3
4
5
6 #include "module_def.h"
7
8 #define MAX_NUM_LOADED_MODULES 10
9
10
11
12
13
14
15
16
17 typedef struct
18 {
19 base_interface_t** lib;
20 base_interface_t* default_lib;
21 _version_t version;
22
23 char* name;
24 } module_handler_t;
25
26 typedef struct
27 {
28 flat_hdr* hdr;
29 unsigned int hName;
30 module_handler_t* hMod;
31 } module_entry;
32
33
34
35
36 flat_hdr* module_preload(const char *path, const char *name, _version_t ver);
37 int module_load(module_handler_t* hMod);
38 void module_unload(const char* name);
39
40 void get_module_info(const char *name, ModuleInfo *mi, char *modName, int modNameLen);
41
42 int module_run(char* name);
43
44 module_entry* module_get_adr(unsigned int idx);
45
46
47
48 void module_exit_alt();
49 void module_tick_unloader();
50
51
52 void module_log_clear();
53
54 #endif