This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.
For more information, see this announcement post . Click the X in the top right-corner of this box to dismiss this message.
Old posts that have not been replied to for several years.
RaDoM
Voice
Posts: 17 Joined: Mon Mar 10, 2003 2:32 pm
Location: uNd3rGr0uNd C1Ty
Post
by RaDoM » Mon May 26, 2003 6:59 pm
hi,
i want to do a tcl for my eggdrop and i want when i type in a chan any trigger (ex. !damn), the bot reply me with a text?
thanks in advance
. :: Ra Do M : :.
The future is nearby!
user
Posts: 1452 Joined: Tue Mar 18, 2003 9:58 pm
Location: Norway
Post
by user » Mon May 26, 2003 7:20 pm
Did you even TRY searching for an answer?
ReaLz
Op
Posts: 121 Joined: Sat Oct 19, 2002 5:33 am
Location: Athens, Greece
Post
by ReaLz » Tue May 27, 2003 1:34 am
it's much more easier than you think.
here is an example:
Code: Select all
bind pub o !damn damn:pub
proc damn:pub {nick host handle chan args} {
puthelp "NOTICE $nick :Hey there!"
return 1
}
the bot will reply with a notice to you "Hey there!"
if you want the bot to reply in the channel replace
with
if you read the tcl-commands.doc or just read some tcl scripts that contain a pub bind you will be able to make your own tcl scripts
«A fantastic spaghetti is a spaghetti that does not exist»
RaDoM
Voice
Posts: 17 Joined: Mon Mar 10, 2003 2:32 pm
Location: uNd3rGr0uNd C1Ty
Post
by RaDoM » Tue May 27, 2003 2:13 am
ohh, thanks i'll try again
. :: Ra Do M : :.
The future is nearby!
RaDoM
Voice
Posts: 17 Joined: Mon Mar 10, 2003 2:32 pm
Location: uNd3rGr0uNd C1Ty
Post
by RaDoM » Tue May 27, 2003 3:28 am
and if i want to add anothers lines for reply, what have i add?
. :: Ra Do M : :.
The future is nearby!
ReaLz
Op
Posts: 121 Joined: Sat Oct 19, 2002 5:33 am
Location: Athens, Greece
Post
by ReaLz » Tue May 27, 2003 4:49 am
you can add other binds or do something like this:
Code: Select all
bind pub o !damn damn:pub
proc damn:pub {nick host handle chan args} {
if {$args == hi} {
puthelp "NOTICE $nick :Hey there!"
}
if {$args == bye} {
puthelp "NOTICE $nick :Bye. c ya later!"
}
return 1
}
with a script like that if an op (+o flag) says !damn hi the bot will reply with a notice "Hey there!"
and if he says !damn bye the bot will reply with a notice "Bye. c ya later!"
or you can test with TCL with a script like this....
Code: Select all
bind pub o !mode mode:pub
proc mode:pub {nick host handle chan args} {
set args [lindex $args 0]
set mode [lindex $args 0]
set target [lindex $args 1]
if {$mode == op} {
putserv "MODE $chan +o $target"
}
if {$mode == deop} {
putserv "MODE $chan -o $target"
}
}
and that's it
«A fantastic spaghetti is a spaghetti that does not exist»
RaDoM
Voice
Posts: 17 Joined: Mon Mar 10, 2003 2:32 pm
Location: uNd3rGr0uNd C1Ty
Post
by RaDoM » Tue May 27, 2003 4:56 am
heeheh, thankss
hmmm, another thing, where can i get for learn to tcl scripting?
thx
. :: Ra Do M : :.
The future is nearby!
ReaLz
Op
Posts: 121 Joined: Sat Oct 19, 2002 5:33 am
Location: Athens, Greece
Post
by ReaLz » Tue May 27, 2003 5:13 am
you can find some useful sites
here .
«A fantastic spaghetti is a spaghetti that does not exist»
RaDoM
Voice
Posts: 17 Joined: Mon Mar 10, 2003 2:32 pm
Location: uNd3rGr0uNd C1Ty
Post
by RaDoM » Tue May 27, 2003 6:44 pm
heheh, thank u very much for all.
but another question, it's possible that eggdrop connected to a ftp server and execute a command (egg has all permissions)?
thx in advance
. :: Ra Do M : :.
The future is nearby!
caesar
Mint Rubber
Posts: 3778 Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory
Post
by caesar » Wed May 28, 2003 2:23 am
Yes, it's possible. Use a tcl script that was designed to do so. See the TCL Archive for one..
Once the game is over, the king and the pawn go back in the same box.
RaDoM
Voice
Posts: 17 Joined: Mon Mar 10, 2003 2:32 pm
Location: uNd3rGr0uNd C1Ty
Post
by RaDoM » Wed May 28, 2003 3:21 am
yes but anybody does i want it
for example, i type !lol, then send a command via ftp (ex. site help) and reply with the result (in this case the help).
. :: Ra Do M : :.
The future is nearby!