lookjapan.COM - IRC ve mIRC dünyasının forumu!

lookjapan.COM - IRC ve mIRC dünyasının forumu! (http://www.lookjapan.com/index.php)
-   TCL Scriptler (http://www.lookjapan.com/forumdisplay.php?f=69)
-   -   DNS. Tcl (http://www.lookjapan.com/showthread.php?t=1444)

No_FeaR 22 Mart 2015 11:04

DNS. Tcl
 
Kod:

bind pub mnf|oaf !dns resolver_dns

proc resolver_dns {nick uhost hand chan text} {
        if {![channel get $chan dns]} { return }
        set q [lindex [split $text] 0]
        if {[llength $q] eq 0} {
                putserv "privmsg $chan :Usage : \002$::lastbind <host/nick>\002"
                return 0
        }
        if {(![string match "*.*" $text]) && ([onchan $text $chan]) \
                        && ([regexp -line -- {!?([a-f0-9]{1,4})\:([a-f0-9]{1,4})\:([a-f0-9]{1,4})\:.*$} $q] ne 1)} {
                set q [lindex [split [getchanhost [lindex [split $text] 0] $chan] @] 1]
                if {[string length $q]} { set text $q }
        }
        if {([regexp -line -- {!?([\d]{1,3}\.[\d]{1,3}\.[\d]{1,3}\.[\d]{1,3})$} $q] ne 0) \
                        || ([regexp -line -- {!?([a-f0-9]{1,4})\:([a-f0-9]{1,4})\:([a-f0-9]{1,4})\:.*$} $q] eq 1)} {
                putserv "privmsg $chan :Only valid \"host\" or \"nick\" please. k thnx"
                return
        }
        if {[regexp -line -- {!?([\d]{1,3}\.[\d]{1,3}\.[\d]{1,3}\.[\d]{1,3})$} $q] eq 0} {
                putserv "privmsg $chan :\00304->\003 [dnslookup $q f]"
        }
        return
}

proc f {a b c} { if {$c} { return \002$a\002 } { return \002$b\002 }}

setudef flag dns

putlog "ok..."


Yapımcısı ; saywhat


All times are GMT +3. The time now is 02:50.

Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.