/[cvs]/eggdrop1.4/src/modules.h
ViewVC logotype

Contents of /eggdrop1.4/src/modules.h

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1.1.1 - (show annotations) (download) (as text) (vendor branch)
Wed Jun 23 19:51:31 1999 UTC (22 years, 4 months ago) by segfault
Branch: eggdev
CVS Tags: start
Changes since 1.1: +0 -0 lines
File MIME type: text/x-csrc
Eggdrop 1.3.28 CVS Code

1 /*
2 * modules.h - support for code modules in eggdrop
3 * by Darrin Smith (beldin@light.iinet.net.au)
4 */
5 /*
6 * This file is part of the eggdrop source code
7 * copyright (c) 1997 Robey Pointer
8 * and is distributed according to the GNU general public license.
9 * For full details, read the top of 'main.c' or the file called
10 * COPYING that was distributed with this code.
11 */
12
13 /*
14 * module related structures
15 */
16
17 #ifndef _MODULE_H_
18 #define _MODULE_H_
19
20 #include "mod/modvals.h"
21
22 #ifndef MAKING_NUMMODS
23 /* modules specific functions */
24 /* functions called by eggdrop */
25 void do_module_report(int, int, char *);
26
27 int module_register(char *name, Function * funcs,
28 int major, int minor);
29 const char *module_load(char *module_name);
30 char *module_unload(char *module_name, char *nick);
31 module_entry *module_find(char *name, int, int);
32 Function *module_depend(char *, char *, int major, int minor);
33 int module_undepend(char *);
34 void *mod_malloc(int size, char *modname, char *filename, int line);
35 void mod_free(void *ptr, char *modname, char *filename, int line);
36 void add_hook(int hook_num, void *func);
37 void del_hook(int hook_num, void *func);
38 void *get_next_hook(int hook_num, void *func);
39 extern struct hook_entry {
40 struct hook_entry *next;
41 int (*func) ();
42 } *hook_list[REAL_HOOKS];
43
44 #define call_hook(x) { struct hook_entry *p; \
45 for (p = hook_list[x]; p; p = p->next) p->func(); }
46 int call_hook_cccc(int, char *, char *, char *, char *);
47
48 #endif
49
50 typedef struct _dependancy {
51 struct _module_entry *needed;
52 struct _module_entry *needing;
53 struct _dependancy *next;
54 int major;
55 int minor;
56 } dependancy;
57 extern dependancy *dependancy_list;
58
59 #endif /* _MODULE_H_ */

webmaster@eggheads.org
ViewVC Help
Powered by ViewVC 1.1.23