summaryrefslogtreecommitdiff
path: root/include/services.h
diff options
context:
space:
mode:
authorRobin Burchell w00t@inspircd.org <Robin Burchell w00t@inspircd.org@5417fbe8-f217-4b02-8779-1006273d7864>2008-09-30 18:45:11 +0000
committerRobin Burchell w00t@inspircd.org <Robin Burchell w00t@inspircd.org@5417fbe8-f217-4b02-8779-1006273d7864>2008-09-30 18:45:11 +0000
commit58ab9f234cdabbf1a181fcd4d090a7b7b98836cc (patch)
treeafa29b4847f1c67c11ece155e6469c533b1bcbee /include/services.h
parent6e0bee3ab1cd085f7ef572c7762ea9425e6dd418 (diff)
Added cmd_message() function to IRCDProtoNew class. (Replaces cmd_notice)
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1227 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'include/services.h')
-rw-r--r--include/services.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/include/services.h b/include/services.h
index c868c6d5a..61b967b64 100644
--- a/include/services.h
+++ b/include/services.h
@@ -1059,7 +1059,6 @@ typedef struct ircd_proto_ {
void (*ircd_cmd_372_error)(const char *source);
void (*ircd_cmd_375)(const char *source);
void (*ircd_cmd_376)(const char *source);
- void (*ircd_cmd_notice)(const char *source, const char *dest, const char *buf);
void (*ircd_cmd_notice2)(const char *source, const char *dest, const char *msg);
void (*ircd_cmd_serv_notice)(const char *source, const char *dest, const char *msg);
void (*ircd_cmd_serv_privmsg)(const char *source, const char *dest, const char *msg);
@@ -1306,6 +1305,12 @@ class IRCDProtoNew {
virtual void cmd_bot_nick(const char *, const char *, const char *, const char *, const char *) = 0;
virtual void cmd_kick(const char *source, const char *chan, const char *user, const char *buf) = 0;
virtual void cmd_notice_ops(const char *, const char *dest, const char *buf) = 0;
+ virtual void cmd_message(const char *source, const char *dest, const char *buf)
+ {
+ if (!buf || !dest) return;
+ if (NSDefFlags & NI_MSG) cmd_privmsg(source, dest, buf);
+ else send_cmd(source, "NOTICE %s :%s", dest, buf);
+ }
virtual void cmd_privmsg(const char *source, const char *dest, const char *buf)
{
if (!buf || !dest) return;