#include "BanNode.h"
#include "ModeNode.h"
#include "tools.h"
+#include "bots.h"
struct irc_cmd *irc_commands = NULL;
static struct UserNode *registering_users = NULL;
return 1;
}
+static IRC_CMD(raw_nojoin) {
+ if(from == NULL || argc < 3) return 0;
+ struct ChanNode *chan = getChanByName(argv[1]);
+ if(chan == NULL) return 0;
+ if(client->flags & SOCKET_FLAG_REQUEST_INVITE)
+ requestInvite(client->user, chan);
+ return 1;
+}
+
void init_parser() {
//all the raws we receive...
register_irc_function("437", raw_437);
register_irc_function("324", raw_324);
register_irc_function("332", raw_332);
register_irc_function("367", raw_367);
+ register_irc_function("471", raw_nojoin);
+ register_irc_function("473", raw_nojoin);
+ register_irc_function("474", raw_nojoin);
+ register_irc_function("475", raw_nojoin);
register_irc_function("INVITE", raw_invite);
register_irc_function("NOTICE", raw_notice);
register_irc_function("TOPIC", raw_topic);