| View previous topic :: View next topic |
| Author |
Message |
darton Op
Joined: 21 Jan 2006 Posts: 155
|
Posted: Mon Apr 17, 2006 5:21 pm Post subject: Echo everything of a certain nick |
|
|
Hello!
My bot is in two channels and in one of these channels there is another bot. Now my bot should repeat everything what the other bot says, but into another channel.
With a mirc-script it's just:
| Code: | | if ($nick == otherbot) { msg #channel2 $1- } |
Can you help me to make this with tcl? |
|
| Back to top |
|
 |
Sir_Fz Revered One

Joined: 27 Apr 2003 Posts: 3793 Location: Lebanon
|
Posted: Mon Apr 17, 2006 5:46 pm Post subject: |
|
|
| Code: | bind pubm - "#channel1 *" relay:bot
proc relay:bot {nick uhost hand chan arg} {
if {[string equal -nocase otherbot $nick]} {
putserv "privmsg #channel2 :$arg"
}
} |
_________________ Follow me on GitHub
- Opposing
Public Tcl scripts |
|
| Back to top |
|
 |
evac1K Voice
Joined: 19 Jun 2006 Posts: 7
|
Posted: Tue Jun 20, 2006 12:34 am Post subject: |
|
|
| what part of that do you edit? |
|
| Back to top |
|
 |
metroid Owner
Joined: 16 Jun 2004 Posts: 771
|
Posted: Tue Jun 20, 2006 3:05 am Post subject: |
|
|
#channel1, otherbot and #channel2.
Is that not very obvious? |
|
| Back to top |
|
 |
evac1K Voice
Joined: 19 Jun 2006 Posts: 7
|
Posted: Tue Jun 20, 2006 11:33 pm Post subject: |
|
|
| still not working :\ |
|
| Back to top |
|
 |
|