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.
Help for those learning Tcl or writing their own scripts.
-
l.kleijn
- Voice
- Posts: 33
- Joined: Sun May 18, 2014 10:02 am
Post
by l.kleijn »
I'm searching for a script that when i type '/msg botnick bots'
That i get a list with all linked bots.
Can someone help me with this ?
-
CrazyCat
- Revered One
- Posts: 1306
- Joined: Sun Jan 13, 2002 8:00 pm
- Location: France
-
Contact:
Post
by CrazyCat »
Really short:
Code: Select all
bind msg n bots getbots
proc getbots {nick uhost handle text} {
foreach lbot [botlist] {
putserv "PRIVMSG $nick :[lindex $lbot 0] is connected to [lindex $lbot 1]"
}
}
-
willyw
- Revered One
- Posts: 1205
- Joined: Thu Jan 15, 2009 12:55 am
Post
by willyw »
If you don't want the extra info, and are ok with just the bare list of bots on the botnet, experiment with substituting:
for
Code: Select all
foreach lbot [botlist] {
putserv "PRIVMSG $nick :[lindex $lbot 0] is connected to [lindex $lbot 1]"
}
Reference:
https://docs.eggheads.org/mainDocs/tcl- ... .html#bots
For a fun (and popular) Trivia game, visit us at: irc.librairc.net #science-fiction . Over 300K Q & A to play in BogusTrivia !
-
Arnold_X-P
- Master
- Posts: 226
- Joined: Mon Oct 30, 2006 12:19 am
- Location: DALnet - Trinidad - Beni - Bolivia
-
Contact:
Post
by Arnold_X-P »
CrazyCat wrote:Really short:
Code: Select all
bind msg n bots getbots
proc getbots {nick uhost handle text} {
foreach lbot [botlist] {
putserv "PRIVMSG $nick :[lindex $lbot 0] is connected to [lindex $lbot 1]"
}
}
use the code and it doesn't work....and it does not generate any error
but it works this way for me
Code: Select all
bind msg n bots getbots
proc getbots {nick uhost handle text} {
foreach lbot [split botlist] {
putserv "PRIVMSG $nick :[lindex $lbot 0] is connected to [lindex $lbot 1]"
}
}