|
|
@ -49,7 +49,7 @@ hook ctcprequest(sender, target, command, message) |
|
|
|
|
|
|
|
|
|
|
|
if (command == "TIME" && response_CTCP_TIME) { |
|
|
|
if (command == "TIME" && response_CTCP_TIME) { |
|
|
|
t = now("yyyy/MM/dd hh:mm:ss t"); |
|
|
|
t = now("yyyy/MM/dd hh:mm:ss t"); |
|
|
|
/ctcpreply %sender TIME %t |
|
|
|
/ctcpreply TIME %sender %t |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
@ -88,15 +88,21 @@ menu private { |
|
|
|
"Whois" => /whois %nickname |
|
|
|
"Whois" => /whois %nickname |
|
|
|
divide |
|
|
|
divide |
|
|
|
"CTCP" { |
|
|
|
"CTCP" { |
|
|
|
"Ping" => /ctcp %nickname PING |
|
|
|
"Ping" => /ctcp PING %nickname |
|
|
|
"Version" => /ctcp %nickname VERSION |
|
|
|
"Version" => /ctcp VERSION %nickname |
|
|
|
"Time" => /ctcp %nickname TIME |
|
|
|
"Time" => /ctcp TIME %nickname |
|
|
|
divide |
|
|
|
divide |
|
|
|
"Custom..." => { |
|
|
|
"Custom..." => { |
|
|
|
msg = input("Custom CTCP message", "Message:"); |
|
|
|
msg = input("Custom CTCP message", "Message:"); |
|
|
|
if (msg == void) return; |
|
|
|
if (msg == void) return; |
|
|
|
if (msg == "") return; |
|
|
|
if (msg == "") return; |
|
|
|
/ctcp %nickname %msg |
|
|
|
sidx = strfind(msg, " "); |
|
|
|
|
|
|
|
if (sidx < 0) /ctcp %msg %nickname |
|
|
|
|
|
|
|
else { |
|
|
|
|
|
|
|
command = strmid(msg, 0, sidx); |
|
|
|
|
|
|
|
message = strmid(msg, sidx + 1, strlen(msg) - strlen(command) - 1); |
|
|
|
|
|
|
|
/ctcp %command %nickname %message |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -235,7 +241,7 @@ menu memberlist { |
|
|
|
i = 0; |
|
|
|
i = 0; |
|
|
|
while (selected[i] != void) { |
|
|
|
while (selected[i] != void) { |
|
|
|
nick = selected[i]; |
|
|
|
nick = selected[i]; |
|
|
|
/ctcp %nick PING |
|
|
|
/ctcp PING %nick |
|
|
|
i = i + 1; |
|
|
|
i = i + 1; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -251,7 +257,7 @@ menu memberlist { |
|
|
|
i = 0; |
|
|
|
i = 0; |
|
|
|
while (selected[i] != void) { |
|
|
|
while (selected[i] != void) { |
|
|
|
nick = selected[i]; |
|
|
|
nick = selected[i]; |
|
|
|
/ctcp %nick VERSION |
|
|
|
/ctcp VERSION %nick |
|
|
|
i = i + 1; |
|
|
|
i = i + 1; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -267,7 +273,7 @@ menu memberlist { |
|
|
|
i = 0; |
|
|
|
i = 0; |
|
|
|
while (selected[i] != void) { |
|
|
|
while (selected[i] != void) { |
|
|
|
nick = selected[i]; |
|
|
|
nick = selected[i]; |
|
|
|
/ctcp %nick TIME |
|
|
|
/ctcp TIME %nick |
|
|
|
i = i + 1; |
|
|
|
i = i + 1; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
@ -284,10 +290,22 @@ menu memberlist { |
|
|
|
} |
|
|
|
} |
|
|
|
msg = input("Custom CTCP message", "Message:"); |
|
|
|
msg = input("Custom CTCP message", "Message:"); |
|
|
|
if (msg == void || msg == "") return; |
|
|
|
if (msg == void || msg == "") return; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
command = ""; |
|
|
|
|
|
|
|
message = ""; |
|
|
|
|
|
|
|
sidx = strfind(msg, " "); |
|
|
|
|
|
|
|
if (sidx < 0) { |
|
|
|
|
|
|
|
command = msg; |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
else { |
|
|
|
|
|
|
|
command = strmid(msg, 0, sidx); |
|
|
|
|
|
|
|
message = strmid(msg, sidx + 1, strlen(msg) - strlen(command) - 1); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
i = 0; |
|
|
|
i = 0; |
|
|
|
while (selected[i] != void) { |
|
|
|
while (selected[i] != void) { |
|
|
|
nick = selected[i]; |
|
|
|
nick = selected[i]; |
|
|
|
/ctcp %nick %msg |
|
|
|
/ctcp %command %nick %message |
|
|
|
i = i + 1; |
|
|
|
i = i + 1; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|