$irc->registerActionHandler(SMARTIRC_TYPE_QUERY, '/^identify\\s/', $bot, "msgIdent"); $irc->registerActionHandler(SMARTIRC_TYPE_QUERY, '/^query(2)?\\s.*/', $bot, "msgQuery"); $irc->registerActionHandler(SMARTIRC_TYPE_QUERY, '/^ad\\s/', $bot, "msgAd"); $irc->registerActionHandler(SMARTIRC_TYPE_QUERY, '/^ban\\s/', $bot, "msgBan"); $irc->registerActionHandler(SMARTIRC_TYPE_QUERY, '/^voice\\s/', $bot, "msgVoice"); $irc->registerActionHandler(SMARTIRC_TYPE_QUERY, '/^exit\\s/', $bot, "msgExit"); $irc->registerActionHandler(SMARTIRC_TYPE_QUERY, '/^global\\s/', $bot, "msgGlobal"); $irc->registerActionHandler(SMARTIRC_TYPE_CHANNEL, '.*', $bot, "timedChanMsg"); $irc->registerActionHandler(SMARTIRC_TYPE_ACTION, '.*', $bot, "timedChanMsg"); $irc->registerActionHandler(SMARTIRC_TYPE_JOIN, '/\\#dogec0in$/', $bot, "onJoin"); $irc->registerActionHandler(SMARTIRC_TYPE_JOIN, '/\\#dogec0in-vip$/', $bot, "onJoinVip"); $irc->registerActionHandler(SMARTIRC_TYPE_PART, '.*', $bot, "onPart"); $irc->registerActionHandler(SMARTIRC_TYPE_KICK, '.*', $bot, "onKick"); $irc->registerActionHandler(SMARTIRC_TYPE_QUIT, '.*', $bot, "onQuit"); $irc->registerActionHandler(SMARTIRC_TYPE_NICKCHANGE, '.*', $bot, "onNickChange"); $irc->registerTimeHandler(600000, $bot, "adTick"); while (1) { $irc->connect("localhost", 7000, true); $irc->login("wowsuchdoge", "much coins", 8, "manyshibe", ''); $irc->send("oper username password"); // oline $irc->send("part #services :"); $irc->message(SMARTIRC_TYPE_QUERY, "nickserv", "identify password"); $irc->join(array("#dogec0in", "#dogec0in-vip")); $irc->send("samode #dogec0in +Y wowsuchdoge"); $irc->send("samode #dogec0in-vip +Y wowsuchdoge"); $irc->setModulepath("."); $irc->loadModule("PingFix"); $irc->listen(); $irc->disconnect(); }