Hi,
I am looking for a script for a bot that uses the trigger !version <nick>
Then replies to the chanset #channel(s) with: Version Reply: mIRC 6.35 Khaled Mardam-Bey
Or what ever version(s) the user might be using.
Thanks,
play4free2
Code: Select all
set chan "#channel"
bind pub - !version vers_proc
bind ctcr - VERSION return_vers
bind pub - !utime utms_proc
bind ctcr - TIME return_utms
proc vers_proc {nick uhost hand chan arg} {
putserv "PRIVMSG $nick :\001VERSION\001"
}
proc return_vers {nick uhost hand dest key vers} {
global chan
set retvers [join [lrange [split $vers] 0 end]]
putserv "PRIVMSG $chan :$nick is using: $retvers"
}
proc utms_proc {nick uhost hand chan arg} {
putserv "PRIVMSG $nick :\001TIME\001"
}
proc return_utms {nick uhost hand dest key utms} {
global chan
set retutms [join [lrange [split $utms] 0 end]]
putserv "PRIVMSG $chan :$nick's date and time: $retutms"
}
Code: Select all
bind PUB - !version version:pub
bind CTCR - VERSION version:reply
setudef flag version
proc version:pub {nick uhost hand chan arg} {
global temp
if {![channel get $chan version]} { return }
set temp(who) [lindex [split $arg] 0]
set temp(chan) $chan
putserv "PRIVMSG $temp(who) :\001VERSION\001"
}
proc version:reply {nick uhost hand dest key vers} {
global temp
putserv "PRIVMSG $temp(chan) :$nick is using: [join [lrange [split $vers] 0 end]]"
}