| View previous topic :: View next topic |
| Author |
Message |
kartofeln Voice
Joined: 01 Feb 2006 Posts: 2
|
Posted: Wed Feb 01, 2006 1:04 pm Post subject: .tcl script that makes bot to say something... |
|
|
Hi,
Iīm looking for a .tcl so when I write for example: !hello im my channel, the eggdrop will say what I wrote previously in a .txt or what I predefined in the same .tcl
I was looking TCL tutorials and webs and didnīt found nothing similar.
Would be great if someone can help me
regards |
|
| Back to top |
|
 |
demond Revered One

Joined: 12 Jun 2004 Posts: 3073 Location: San Francisco, CA
|
Posted: Thu Feb 02, 2006 12:59 am Post subject: |
|
|
you didn't look hard enough
| Code: |
set t {}
foreach e [split [read [open file.txt]] \n] {lappend t $e}
proc foo {n u h c t} {foreach e $::t {puthelp "privmsg $c :$e"}}
bind pub - !hello foo
|
_________________ connection, sharing, dcc problems? click <here>
before asking for scripting help, read <this>
use [code] tag when posting logs, code |
|
| Back to top |
|
 |
kartofeln Voice
Joined: 01 Feb 2006 Posts: 2
|
Posted: Thu Feb 02, 2006 5:38 pm Post subject: |
|
|
| thanks a lot!!! *^^* |
|
| Back to top |
|
 |
|