Hammer types:
/ctcp Mike` PING
mIRC sends:
PRIVMSG : $+ $chr(1) $+ PING $ctime $+ $chr(1)
PRIVMSG Mike` :PING 645266253
Mike` receives it and sends back whatever follows PING unchanged:
ctcp *:PING*:?: ctcpreply $nick PING $1-
/ctcpreply Hammer PING 645266253
NOTICE Hammer :PING 645266253
Hammer receives it and subtracts the numeric value after the PING from his current $ctime to retrieve the difference between the ctime he sent the ping and when he got the response back.
on *:CTCPREPLY:PING*: echo $color(ctcp) -ati2 * Ping response from $nick is $duration($calc($ctime - $2)) $+ .