#include <eggdrop/eggdrop.h>
Go to the source code of this file.
Functions | |
int | eggdrop_init (void) |
int | eggdrop_shutdown (void) |
int | eggdrop_event (const char *event) |
int | eggdrop_set_params (const char **params, int nparams) |
const char * | eggdrop_get_param (const char *key) |
Variables | |
static const char | rcsid [] = "$Id: eggdrop.c,v 1.27 2006-11-14 14:51:23 sven Exp $" |
static bind_table_t * | BT_event = NULL |
static const char ** | eggparams = NULL |
static int | neggparams = 0 |
int eggdrop_event | ( | const char * | event | ) |
Definition at line 68 of file eggdrop.c.
References bind_check(), and NULL.
Referenced by core_secondly(), disconnect_server(), got001(), got_hup(), got_quit(), got_term(), script_die(), and server_on_connect().
00069 { 00070 return bind_check(BT_event, NULL, event, event); 00071 }
const char* eggdrop_get_param | ( | const char * | key | ) |
Definition at line 82 of file eggdrop.c.
References eggparams, neggparams, and NULL.
00083 { 00084 int i, nparams; 00085 00086 nparams = neggparams - 1; 00087 for (i = 0; i < nparams; i += 2) { 00088 if (!strcasecmp(eggparams[i], key)) return(eggparams[i+1]); 00089 } 00090 return(NULL); 00091 }
int eggdrop_init | ( | void | ) |
Definition at line 33 of file eggdrop.c.
References BIND_STACKABLE, bind_table_add(), botnet_init(), BTN_EVENT, config_init(), egg_net_init(), help_init(), logging_init(), MATCH_MASK, module_init(), partyline_init(), script_init(), timer_init(), and user_init().
Referenced by core_init().
00034 { 00035 BT_event = bind_table_add(BTN_EVENT, 1, "s", MATCH_MASK, BIND_STACKABLE); /* DDD */ 00036 00037 config_init(); 00038 timer_init(); 00039 egg_net_init(); 00040 logging_init(); 00041 user_init(); 00042 script_init(); 00043 partyline_init(); 00044 botnet_init(); 00045 module_init(); 00046 help_init(); 00047 00048 00049 return 1; 00050 }
int eggdrop_set_params | ( | const char ** | params, | |
int | nparams | |||
) |
Definition at line 74 of file eggdrop.c.
References eggparams, and neggparams.
Referenced by do_args().
00075 { 00076 eggparams = params; 00077 neggparams = nparams; 00078 return(0); 00079 }
int eggdrop_shutdown | ( | void | ) |
Definition at line 52 of file eggdrop.c.
References bind_table_del(), botnet_shutdown(), config_shutdown(), egg_net_shutdown(), logging_shutdown(), module_shutdown(), partyline_shutdown(), script_shutdown(), timer_shutdown(), and user_shutdown().
Referenced by core_shutdown_or_restart().
00053 { 00054 module_shutdown(); 00055 botnet_shutdown(); 00056 partyline_shutdown(); 00057 script_shutdown(); 00058 user_shutdown(); 00059 logging_shutdown(); 00060 egg_net_shutdown(); 00061 timer_shutdown(); 00062 config_shutdown(); 00063 bind_table_del(BT_event); 00064 00065 return 1; 00066 }
bind_table_t* BT_event = NULL [static] |
const char** eggparams = NULL [static] |
Definition at line 30 of file eggdrop.c.
Referenced by eggdrop_get_param(), and eggdrop_set_params().
int neggparams = 0 [static] |
Definition at line 31 of file eggdrop.c.
Referenced by eggdrop_get_param(), and eggdrop_set_params().
const char rcsid[] = "$Id: eggdrop.c,v 1.27 2006-11-14 14:51:23 sven Exp $" [static] |