;############################################ ; Ping Reply Module For All-Out-War Coded By Blink, Edited by LgZ-optical (adminblink@msn.com) ;############################################ on *:text:*:#:{ if $1 == !ping { if $2 != $null { if $2 ison $chan { ctcp $2 version set %ping $ticks halt } } ctcp $nick version set %Ping $ticks } } on 1:ctcpreply:*: { if %ping == $null { halt } %dif = $calc(($ticks - %ping)/1000 ) msg #all-out-war 7[PING]3 $nick 10has a ping reply of3 %dif 10secs 7( $+ $rating(%dif) $+ 7) unset %dif unset %ping } alias rating { %ping.reply = $1 if %ping.reply <= 0.1 { return 9No lag } if %ping.reply < 0.5 { return 9Minimal lag } if %ping.reply < 1 { return 3Average lag } if %ping.reply < 1.5 { return 3Average to moderate lag } if %ping.reply < 2 { return 8Moderate lag } if %ping.reply < 2.5 { return 8Moderate to high lag } if %ping.reply < 4 { return 4High lag } if %ping.reply > 4.0000000000001 { return 4Critical lag } }