diff options
author | rob rob@31f1291d-b8d6-0310-a050-a5561fc1590b <rob rob@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864> | 2004-05-11 17:31:25 +0000 |
---|---|---|
committer | rob rob@31f1291d-b8d6-0310-a050-a5561fc1590b <rob rob@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864> | 2004-05-11 17:31:25 +0000 |
commit | da4db9a711ae22dbec4cc08d6cb3637212cd7841 (patch) | |
tree | a4b7cf6a997f73a2d2645b55bac483bc6fb141b1 /messages.c | |
parent | b6210244dd8bbd2c9ad62ef8b7459385802c662c (diff) |
BUILD : 1.7.2 (93) BUGS : 46 NOTES : Applied the Rage2 IRCD patch provided by al
git-svn-id: svn://svn.anope.org/anope/trunk@93 31f1291d-b8d6-0310-a050-a5561fc1590b
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@69 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'messages.c')
-rw-r--r-- | messages.c | 53 |
1 files changed, 51 insertions, 2 deletions
diff --git a/messages.c b/messages.c index 1a1da4d75..571bf6286 100644 --- a/messages.c +++ b/messages.c @@ -304,7 +304,7 @@ static int m_nick(char *source, int ac, char **av) set_umode(user, 1, &av[3]); #else #if defined(IRC_BAHAMUT) -#if defined(IRC_ULTIMATE3) +#if defined(IRC_ULTIMATE3) || defined(IRC_RAGE2) User *user = do_nick(source, av[0], av[4], av[5], av[6], av[9], strtoul(av[2], NULL, 10), strtoul(av[7], NULL, 0), @@ -382,6 +382,26 @@ static int m_client(char *source, int ac, char **av) /*************************************************************************/ +#ifdef IRC_RAGE2 + +static int m_snick(char *source, int ac, char **av) +{ + if (ac != 2) { + User *user = do_nick(source, av[0], av[3], av[4], av[8], av[10], + strtoul(av[1], NULL, 10), strtoul(av[7], NULL, + 0), + strtoul(av[5], NULL, 0), av[6]); + if (user) { + set_umode(user, 1, &av[9]); + } + } + return MOD_CONT; +} + +#endif + +/*************************************************************************/ + #ifdef IRC_BAHAMUT static int m_ns(char *source, int ac, char **av) @@ -663,6 +683,7 @@ static int m_server(char *source, int ac, char **av) } /*************************************************************************/ + #if defined(IRC_ULTIMATE3) static int m_sethost(char *source, int ac, char **av) @@ -687,6 +708,30 @@ static int m_sethost(char *source, int ac, char **av) /*************************************************************************/ +#ifdef IRC_RAGE2 + +static int m_vhost(char *source, int ac, char **av) +{ + User *u; + + if (ac != 2) + return MOD_CONT; + + u = finduser(av[0]); + if (!u) { + if (debug) + alog("user: VHOST for nonexistent user %s", av[0]); + return MOD_CONT; + } + + change_user_host(u, av[1]); + return MOD_CONT; +} + +#endif + +/*************************************************************************/ + #if defined(IRC_ULTIMATE) || defined(IRC_UNREAL) || defined(IRC_VIAGRA) static int m_chghost(char *source, int ac, char **av) @@ -806,7 +851,7 @@ static int m_setname(char *source, int ac, char **av) /*************************************************************************/ -#if defined(IRC_BAHAMUT) || defined(IRC_HYBRID) || defined(IRC_PTLINK) +#if defined(IRC_BAHAMUT) || defined(IRC_HYBRID) || defined(IRC_PTLINK) || defined(IRC_RAGE2) static int m_sjoin(char *source, int ac, char **av) { @@ -1181,6 +1226,10 @@ void moduleAddMsgs(void) { m = createMessage("CLIENT", m_client); addCoreMessage(IRCD,m); m = createMessage("SMODE", NULL); addCoreMessage(IRCD,m); #endif +#ifdef IRC_RAGE2 + m = createMessage("SNICK", m_snick); addCoreMessage(IRCD,m); + m = createMessage("VHOST", m_vhost); addCoreMessage(IRCD,m); +#endif } /* *INDENT-ON* */ |