eggdrop's CTCP
Platform: mIRC
Published Nov 20, 2010
Updated Nov 20, 2010
Grabbed from eggdrop source code :P
and ported for mIRC bots.
alias traffic {
signal traffic $1
}
on *:START: {
ignore -tw *
}
on *:LOGON:*: {
debug -i logs/traffic.log traffic
}
on *:SIGNAL:traffic: {
if ($1 == <-) {
if ($(PRIVMSG & :*) iswm $3-) {
var %nick = $gettok($mid($2,2),1,33), %address = $gettok($mid($2,2),2,33), %target = $4, %key = $gettok($mid($5-,3,-1),1,32), %arg = $gettok($mid($5-,3,-1),2-,32)
tokenize 32 %arg
if (%key == SED) { }
if (%key == VERSION) ctcpreply %nick %key eggdrop v1.6.20
if (%key == CLIENTINFO) {
if ($1 == SED) ctcpreply %nick %key SED contains simple_encrypted_data
elseif ($1 == VERSION) ctcpreply %nick %key VERSION shows client type, version and environment
elseif ($1 == CLIENTINFO) ctcpreply %nick %key CLIENTINFO gives information about available CTCP commands
elseif ($1 == USERINFO) ctcpreply %nick %key USERINFO returns user settable information
elseif ($1 == ERRMSG) ctcpreply %nick %key ERRMSG returns error messages
elseif ($1 == FINGER) ctcpreply %nick %key FINGER shows real name, login name and idle time of user
elseif ($1 == TIME) ctcpreply %nick %key TIME tells you the time on the user's host
elseif ($1 == ACTION) ctcpreply %nick %key ACTION contains action descriptions for atmosphere
elseif ($1 == DCC) ctcpreply %nick %key DCC requests a direct_client_connection
elseif ($1 == UTC) ctcpreply %nick %key UTC substitutes the local timezone
elseif ($1 == PING) ctcpreply %nick %key PING returns the arguments it receives
elseif ($1 == ECHO) ctcpreply %nick %key ECHO returns the arguments it receives
elseif (%arg) ctcpreply %nick ERRMSG CLIENTINFO: $1 is not a valid function
else ctcpreply %nick %key SED VERSION CLIENTINFO USERINFO ERRMSG FINGER TIME ACTION DCC UTC PING ECHO :Use CLIENTINFO <COMMAND> to get more specific information
}
if (%key == USERINFO) ctcpreply %nick %key eggdrop v1.6.20
if (%key == ERRMSG) ctcpreply %nick %key
if (%key == FINGER) ctcpreply %nick %key eggdrop v1.6.20
if (%key == TIME) ctcpreply %nick %key $time
if (%key == ACTION) { }
if (%key == DCC) { }
if (%key == UTC) { }
if (%key == PING) ctcpreply %nick %key %arg
if (%key == ECHO) ctcpreply %nick %key %arg
}
}
}