egghelp.org community Forum Index
[ egghelp.org home | forum home ]
egghelp.org community
Discussion of eggdrop bots, shell accounts and tcl scripts.
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

#channel exist ?

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help
View previous topic :: View next topic  
Author Message
BoaR
Halfop


Joined: 20 Jul 2007
Posts: 48

PostPosted: Sat Aug 04, 2007 3:47 pm    Post subject: #channel exist ? Reply with quote

i would like to see something that would check if the word has # in front of the word and if the channel exists in the bots channel list .

i have this to get the 2nd word:

set chan [lindex [split $text] 1]
Back to top
View user's profile Send private message
nml375
Revered One


Joined: 04 Aug 2006
Posts: 2857

PostPosted: Sat Aug 04, 2007 4:03 pm    Post subject: Reply with quote

Use the validchan command.
doc/tcl-commands.doc wrote:
validchan <channel>
Description: checks if the bot has a channel record for the specified
channel. Note that this does not necessarily mean that the bot is ON
the channel.
Returns: 1 if the channel exists, 0 if not
Module: channels

_________________
NML_375, idling at #eggdrop@IrcNET
Back to top
View user's profile Send private message
BoaR
Halfop


Joined: 20 Jul 2007
Posts: 48

PostPosted: Sat Aug 04, 2007 6:20 pm    Post subject: Reply with quote

thanks Very Happy
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    egghelp.org community Forum Index -> Scripting Help All times are GMT - 4 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Forum hosting provided by Reverse.net

Powered by phpBB © 2001, 2005 phpBB Group
subGreen style by ktauber