1
0
mirror of https://github.com/anope/anope.git synced 2026-07-01 02:46:37 +02:00

added protocol support for incoming NOTICEs

This commit is contained in:
DukePyrolator
2013-07-08 05:05:13 +02:00
parent e957c7b2d2
commit 2ea594d677
11 changed files with 66 additions and 22 deletions
+16
View File
@@ -244,6 +244,22 @@ void MOTD::Run(MessageSource &source, const std::vector<Anope::string> &params)
IRCD->SendNumeric(422, source.GetSource(), ":- MOTD file not found! Please contact your IRC administrator.");
}
void Notice::Run(MessageSource &source, const std::vector<Anope::string> &params)
{
Anope::string message = params[1];
User *u = source.GetUser();
/* ignore channel notices */
if (!IRCD->IsChannelValid(params[0]))
{
BotInfo *bi = BotInfo::Find(params[0]);
if (!bi)
return;
FOREACH_MOD(OnBotNotice, (u, bi, message));
}
}
void Part::Run(MessageSource &source, const std::vector<Anope::string> &params)
{
User *u = source.GetUser();