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.

List of channels

Old posts that have not been replied to for several years.
Locked
S
Shmupsik
Voice
Posts: 23
Joined: Sat May 15, 2004 1:54 pm
Location: Russia

List of channels

Post by Shmupsik »

How can I get in TCL-script list of channels the bot is currently on? And if possible send it to list, to retrive next with command lindex?
Now, this Bell tolling softly for another, saies to me, Thou must die.
O
Ofloo
Owner
Posts: 953
Joined: Tue May 13, 2003 1:37 am
Location: Belguim
Contact:

Post by Ofloo »

i think that should do

Code: Select all

bind !channels channels:pub

proc channels:pub {nick host hand chan arg} {
  global botnick
  putserv "PRIVMSG $chan :$botnick is on: [channels]"
}
or

Code: Select all

bind !channels channels:pub

proc channels:pub {nick host hand chan arg} {
  global botnick
  foreach {a b c d} [channels] {
    putserv "PRIVMSG $chan :$botnick is on: $a $b $c $d."
  }
}
to retrive next with command lindex?
Explain closer
XplaiN but think of me as stupid
User avatar
strikelight
Owner
Posts: 708
Joined: Mon Oct 07, 2002 10:39 am
Contact:

Post by strikelight »

bind requires a type, and flags, to bind to, Ofloo...
S
Shmupsik
Voice
Posts: 23
Joined: Sat May 15, 2004 1:54 pm
Location: Russia

Post by Shmupsik »

2 Ofloo:

all working.. nothing else... 10x... :)
Now, this Bell tolling softly for another, saies to me, Thou must die.
d
dollar
Op
Posts: 178
Joined: Tue Oct 28, 2003 3:47 pm
Location: Netherlands

Post by dollar »

strikelight wrote:bind requires a type, and flags, to bind to, Ofloo...
LOL, what a mistake to make. Btw, Ofloo, what's Belguim? :P
dollar (or something similar) at:
#eggdrop / #tcl - undernet
#egghelp / #tcl / #eggtcl - efnet
#eggdrop.support / #tcl - quakenet
#eggdrop - ircnet
Locked