diff options
author | Naram Qashat cyberbotx@cyberbotx.com <Naram Qashat cyberbotx@cyberbotx.com@5417fbe8-f217-4b02-8779-1006273d7864> | 2008-10-02 21:31:51 +0000 |
---|---|---|
committer | Naram Qashat cyberbotx@cyberbotx.com <Naram Qashat cyberbotx@cyberbotx.com@5417fbe8-f217-4b02-8779-1006273d7864> | 2008-10-02 21:31:51 +0000 |
commit | 67b96a855ab20402a680bd82645f59a3d9411c3e (patch) | |
tree | 66cd3b6b706a412ae4d6fca7a1b5cc52ecc8dd32 | |
parent | 31c675d3e41939810cbca555e36e67f513ec33c9 (diff) |
Merge branch 'anopeng-uid' of http://git.inspircd.org/git/anope/ into anopeng-uid
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1351 5417fbe8-f217-4b02-8779-1006273d7864
-rw-r--r-- | TODO | 19 | ||||
-rw-r--r-- | include/services.h | 15 |
2 files changed, 25 insertions, 9 deletions
@@ -50,3 +50,22 @@ w00t's CHRISTMAS LIST - Move a (lot) of stuff to class members as a defined interface rather than copypasta everywhere (ns_set, ns_saset!) - prevent deletion of core services via /bs bot - Redo database insanity. + +------- +anopeng-uid branch TODO + +The following (at least, maybe more) need to take BotInfo pointers instead of string senders: + SendMessage + SendNotice + SendPrivmsg + SendGlobalNotice + SendGlobalPrivmsg + SendQuit + SendInvite + SendPart + SendChangeBotNick + SendCTCP + +- add overridden form of SendGlobops accepting BotInfo +- SendAkill should just take a pointer to the Akill class instead of millions of fields + diff --git a/include/services.h b/include/services.h index b9c81290e..4ca5b935a 100644 --- a/include/services.h +++ b/include/services.h @@ -1375,15 +1375,16 @@ class IRCDProto { BotInfo *bi = findbot(source); SendPrivmsgInternal(bi, dest, buf); } - virtual void SendGlobalNotice(const char *source, const char *dest, const char *msg) + virtual void SendGlobalNotice(BotInfo *bi, const char *dest, const char *msg) { send_cmd(UseTS6 ? bi->uid : bi->nick, "NOTICE %s%s :%s", ircd->globaltldprefix, dest, msg); } - virtual void SendGlobalPrivmsg(const char *source, const char *dest, const char *msg) + virtual void SendGlobalPrivmsg(BotInfo *bi, const char *dest, const char *msg) { send_cmd(UseTS6 ? bi->uid : bi->nick, "PRIVMSG %s%s :%s", ircd->globaltldprefix, dest, msg); } virtual void SendBotOp(const char *, const char *) = 0; + virtual void SendQuit(BotInfo *bi, const char *fmt, ...) virtual void SendQuit(const char *source, const char *fmt, ...) { va_list args; @@ -1401,11 +1402,11 @@ class IRCDProto { } virtual void SendJoin(const char *, const char *, time_t) = 0; virtual void SendSQLineDel(const char *) = 0; - virtual void SendInvite(const char *source, const char *chan, const char *nick) + virtual void SendInvite(BotInfo *bi, const char *chan, const char *nick) { send_cmd(UseTS6 ? bi->uid : bi->nick, "INVITE %s %s", nick, chan); } - virtual void SendPart(const char *nick, const char *chan, const char *fmt, ...) + virtual void SendPart(BotInfo *bi, const char *chan, const char *fmt, ...) { if (fmt) { va_list args; @@ -1431,18 +1432,15 @@ class IRCDProto { virtual void SendSQLine(const char *, const char *) = 0; virtual void SendSquit(const char *servname, const char *message) { - if (!servname || !message) return; send_cmd(NULL, "SQUIT %s :%s", servname, message); } virtual void SendSVSO(const char *, const char *, const char *) { } virtual void SendChangeBotNick(const char *oldnick, const char *newnick) { - if (!oldnick || !newnick) return; - send_cmd(oldnick, "NICK %s", newnick); + send_cmd(UseTS6 ? bi->uid : bi->nick, "NICK %s", newnick); } virtual void SendForceNickChange(const char *oldnick, const char *newnick, time_t when) { - if (!oldnick || !newnick) return; send_cmd(NULL, "SVSNICK %s %s :%ld", oldnick, newnick, static_cast<long>(when)); } virtual void SendVhost(const char *, const char *, const char *) { } @@ -1461,7 +1459,6 @@ class IRCDProto { virtual void SendSVID3(User *, const char *) { } virtual void SendCTCP(const char *source, const char *dest, const char *buf) { - if (!buf) return; char *s = normalizeBuffer(buf); send_cmd(UseTS6 ? bi->uid : bi->nick, "NOTICE %s :\1%s\1", dest, s); free(s); |