1
0
mirror of https://github.com/unrealircd/unrealircd.git synced 2026-06-12 19:14:46 +02:00

made /knock without a reason work and some /knock clean ups

This commit is contained in:
codemastr
2000-08-04 19:32:00 +00:00
parent 13790b01e3
commit 1ebe25c025
2 changed files with 6 additions and 8 deletions
+1
View File
@@ -512,3 +512,4 @@
- Fixed a little /chghost bug
- Fixed a SJ3 bug with ban syncing to SJ2 servers
- Fixed some cloak bugs(???)
- Made it so you can /knock without a reason, and a few /knock cleanups
+5 -8
View File
@@ -4268,7 +4268,7 @@ int m_knock(cptr, sptr, parc, parv)
{
aChannel *chptr;
if (parc < 3 || *parv[1] == '\0')
if (parc < 2 || *parv[1] == '\0')
{
sendto_one(sptr, err_str(ERR_NEEDMOREPARAMS),
me.name, parv[0], "KNOCK");
@@ -4281,7 +4281,7 @@ int m_knock(cptr, sptr, parc, parv)
if (check_channelmask(sptr, cptr, parv[1]))
return 0;
/* bugfix for /knock PRv Please? */
if (*parv[1] != '#' && *parv[1] != '&')
if (*parv[1] != '#')
{
sendto_one(sptr, err_str(ERR_CANNOTKNOCK),
me.name,
@@ -4313,10 +4313,7 @@ int m_knock(cptr, sptr, parc, parv)
return 0;
}
if (chptr->mode.mode & MODE_INVITEONLY)
{
}
else
if (!(chptr->mode.mode & MODE_INVITEONLY))
{
sendto_one(sptr, err_str(ERR_CANNOTKNOCK),
me.name,
@@ -4346,9 +4343,9 @@ int m_knock(cptr, sptr, parc, parv)
me.name, chptr->chname, sptr->name,
sptr->user->username,
(IsHidden(sptr) ? sptr->user->virthost : sptr->user->realhost),
parv[2]);
parv[2] ? parv[2] : "no reason specified");
sendto_one(sptr, ":%s NOTICE %s :Knocked on to %s", me.name,
sendto_one(sptr, ":%s NOTICE %s :Knocked on %s", me.name,
sptr->name, chptr->chname);
return 0;
}