[srvx-commits] CVS: services/src chanserv.c,1.256,1.257
Brought to you by:
entrope
|
From: Entrope <en...@us...> - 2002-08-03 02:37:46
|
Update of /cvsroot/srvx/services/src
In directory usw-pr-cvs1:/tmp/cvs-serv23236/src
Modified Files:
chanserv.c
Log Message:
remove extra space from CSMSG_TRIMMED_BANS (thanks for noticing, Geenius)
change !say and !emote to be allow non-channel targets
Index: chanserv.c
===================================================================
RCS file: /cvsroot/srvx/services/src/chanserv.c,v
retrieving revision 1.256
retrieving revision 1.257
diff -C2 -r1.256 -r1.257
*** chanserv.c 1 Aug 2002 03:20:05 -0000 1.256
--- chanserv.c 3 Aug 2002 02:37:43 -0000 1.257
***************
*** 199,203 ****
#define CSMSG_BAN_EXTENDED "Extended ban for $b%s$b expires in %s."
#define CSMSG_BAN_REMOVED "Matching ban(s) for $b%s$b removed."
! #define CSMSG_TRIMMED_BANS "Trimmed $b%d bans$b from the %s ban list that were inactive for at least %s."
#define CSMSG_REDUNDANT_BAN "$b%s$b is already banned in %s."
#define CSMSG_INVALID_DURATION "Timed bans must last for $b%s$b %s."
--- 199,203 ----
#define CSMSG_BAN_EXTENDED "Extended ban for $b%s$b expires in %s."
#define CSMSG_BAN_REMOVED "Matching ban(s) for $b%s$b removed."
! #define CSMSG_TRIMMED_BANS "Trimmed $b%d bans$b from the %s ban list that were inactive for at least %s."
#define CSMSG_REDUNDANT_BAN "$b%s$b is already banned in %s."
#define CSMSG_INVALID_DURATION "Timed bans must last for $b%s$b %s."
***************
*** 4507,4517 ****
static CHANSERV_FUNC(cmd_say)
{
! (void)user;
!
! REQUIRE_PARAMS(2);
!
! unsplit_string(argv + 1, argc - 1);
! send_channel_message(channel, chanserv, "%s", argv[1]);
!
return 1;
}
--- 4507,4521 ----
static CHANSERV_FUNC(cmd_say)
{
! assert(argc >= 2); (void)user;
! if (channel) {
! unsplit_string(argv + 1, argc - 1);
! send_channel_message(channel, cmd->parent->bot, "%s", argv[1]);
! } else if (GetUserH(argv[1])) {
! unsplit_string(argv + 2, argc - 2);
! send_target_message(1, argv[1], cmd->parent->bot, "%s", argv[2]);
! } else {
! send_message(user, cmd->parent->bot, "You must specify the name of a channel or user.");
! return 0;
! }
return 1;
}
***************
*** 4519,4530 ****
static CHANSERV_FUNC(cmd_emote)
{
! (void)user;
!
! REQUIRE_PARAMS(2);
!
! /* CTCP is so annoying. */
! unsplit_string(argv + 1, argc - 1);
! send_channel_message(channel, chanserv, "\001ACTION %s\001", argv[1]);
!
return 1;
}
--- 4523,4538 ----
static CHANSERV_FUNC(cmd_emote)
{
! assert(argc >= 2); (void)user;
! if (channel) {
! /* CTCP is so annoying. */
! unsplit_string(argv + 1, argc - 1);
! send_channel_message(channel, cmd->parent->bot, "\001ACTION %s\001", argv[1]);
! } else if (GetUserH(argv[1])) {
! unsplit_string(argv + 2, argc - 2);
! send_target_message(1, argv[1], cmd->parent->bot, "\001ACTION %s\001", argv[2]);
! } else {
! send_message(user, cmd->parent->bot, "You must specify the name of a channel or user.");
! return 0;
! }
return 1;
}
***************
*** 7054,7059 ****
DEFINE_COMMAND(version, 1, 0, "flags", "+nolog", NULL);
! DEFINE_COMMAND(say, 2, MODCMD_REQUIRE_CHANNEL, "flags", "+oper", NULL);
! DEFINE_COMMAND(emote, 2, MODCMD_REQUIRE_CHANNEL, "flags", "+oper", NULL);
DEFINE_COMMAND(expire, 1, 0, "flags", "+oper", NULL);
DEFINE_COMMAND(write, 1, MODCMD_REQUIRE_AUTHED, "flags", "+oper", NULL);
--- 7062,7067 ----
DEFINE_COMMAND(version, 1, 0, "flags", "+nolog", NULL);
! DEFINE_COMMAND(say, 2, 0, "flags", "+oper,+acceptchan", NULL);
! DEFINE_COMMAND(emote, 2, 0, "flags", "+oper,+acceptchan", NULL);
DEFINE_COMMAND(expire, 1, 0, "flags", "+oper", NULL);
DEFINE_COMMAND(write, 1, MODCMD_REQUIRE_AUTHED, "flags", "+oper", NULL);
***************
*** 7062,7071 ****
DEFINE_COMMAND(unvisited, 1, 0, "account_flags", "+g", "flags", "+nolog", NULL);
! DEFINE_COMMAND(unf, 1, 0, "flags", "+nolog,+toy", NULL);
! DEFINE_COMMAND(ping, 1, 0, "flags", "+nolog,+toy", NULL);
! DEFINE_COMMAND(wut, 1, 0, "flags", "+nolog,+toy", NULL);
! DEFINE_COMMAND(8ball, 1, 0, "flags", "+nolog,+toy", NULL);
! DEFINE_COMMAND(d, 1, 0, "flags", "+nolog,+toy", NULL);
! DEFINE_COMMAND(huggle, 1, 0, "flags", "+nolog,+toy", NULL);
set_func_dict = dict_new();
--- 7070,7079 ----
DEFINE_COMMAND(unvisited, 1, 0, "account_flags", "+g", "flags", "+nolog", NULL);
! DEFINE_COMMAND(unf, 1, 0, "flags", "+nolog", NULL);
! DEFINE_COMMAND(ping, 1, 0, "flags", "+nolog", NULL);
! DEFINE_COMMAND(wut, 1, 0, "flags", "+nolog", NULL);
! DEFINE_COMMAND(8ball, 1, 0, "flags", "+nolog", NULL);
! DEFINE_COMMAND(d, 1, 0, "flags", "+nolog", NULL);
! DEFINE_COMMAND(huggle, 1, 0, "flags", "+nolog", NULL);
set_func_dict = dict_new();
|