Pages

Sunday, August 28, 2011

ping me.tcl

################################################################
# Ping TCL                                                     #
# Author:                                                      #
#    FlyBoyUSA                                                 # 
#                                                              #
# Edited and add some enhancement by:                          #
#    g0eZ               (eggoez@ps-x.net)                        #
#                                                              #
# I hate ripper, so please included the copyright stuff        #
# when you modified it. at least give credit to real author    #
#                                                              #
################################################################

bind pub - .ping ping_me
bind pub - ping ping_me
bind ctcr - PING ping_me_reply

proc ping_me {nick uhost hand chan arg} {
     global pingchan pingwho
     set arg [string toupper $arg]
     if {$arg == "" || [string match "#*" $arg]} {
          puthelp "NOTICE $nick :15!04egG04o04! Gunakan: !ping me atau !ping nick lain 15!04PiN04g!"
          return 0
     } elseif {$arg == "ME"} {
          putserv "PRIVMSG $nick :\001PING [unixtime]\001"
          set pingwho 0
          set pingchan $chan
          return 1
     } else { 
          putserv "PRIVMSG $arg :\001PING [unixtime]\001"
          set pingwho 1
          set pingchan $chan
          return 1
     }
}

proc ping_me_reply {nick uhost hand dest key arg} {
     global pingchan pingwho
     if {$pingwho == 0} {
          puthelp "PRIVMSG $pingchan :03P14ing 3R14eply  $nick15:14 ± [expr [unixtime] - $arg] sec."
          return 0
     } elseif {$pingwho == 1} {
          puthelp "PRIVMSG $pingchan :03P14ing 3R14eply  $nick15:14 ± [expr [unixtime] - $arg] sec."
          return 0
     }
}

############
#End of TCL#
############

putlog "Ping Me By g0eZ egGo Loaded Successfully.."

No comments:

Post a Comment