xbot/lib/events.h

23 lines
484 B
C
Raw Normal View History

2015-03-24 17:48:11 +00:00
#ifndef EVENTS_H
#define EVENTS_H
#include "irc.h"
2015-03-26 23:20:59 +00:00
#define PRIVMSG_SELF 1
#define PRIVMSG_CHAN 2
#define JOIN 3
struct handler
{
int type;
int count;
void **handlers;
};
void init_events();
void add_handler(int type, void *handler);
2015-03-24 17:48:11 +00:00
void handle_chan_privmsg(struct irc_conn *bot, char *user, char *chan, char *text);
void handle_self_privmsg(struct irc_conn *bot, char *user, char *text);
2015-03-26 23:20:59 +00:00
void handle_join(struct irc_conn *bot, char *user, char *chan);
2015-03-24 17:48:11 +00:00
#endif