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 

Message everyone in a channel

 
Post new topic   Reply to topic    egghelp.org community Forum Index -> Script Requests
View previous topic :: View next topic  
Author Message
vigilant
Halfop


Joined: 05 Jan 2006
Posts: 48

PostPosted: Wed Mar 14, 2007 1:03 pm    Post subject: Message everyone in a channel Reply with quote

Once i type a command, and there are 7 users in the channel. It excludes chanserv and the bot itself, but messages the rest of the people with a privmsg.. i want to do this. After that once it's messaged, then if someone leaves the channel, it does something... i'll define that later.. lets say ban the person from another chan...
Thanks a whole bunch
_________________
Anser Quraishi
Website: http://www.anserq.com
Back to top
View user's profile Send private message
Sir_Fz
Revered One


Joined: 27 Apr 2003
Posts: 3793
Location: Lebanon

PostPosted: Wed Mar 14, 2007 4:25 pm    Post subject: Reply with quote

Code:
bind pub - !msg msg:all

proc msg:all {nick uhost hand chan arg} {
 foreach n [chanlist $chan] {
  if {[isbotnick $nick] || [string equal -nocase "chanserv" $n]} {continue}
  puthelp "privmsg $n :$arg"
 }
}

!msg <message> will msg all users except the bot and chanserv (public command).
_________________
Follow me on GitHub

- Opposing

Public Tcl scripts
Back to top
View user's profile Send private message Visit poster's website
vigilant
Halfop


Joined: 05 Jan 2006
Posts: 48

PostPosted: Wed Mar 14, 2007 9:29 pm    Post subject: Reply with quote

Thank you Cool
_________________
Anser Quraishi
Website: http://www.anserq.com
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 -> Script Requests 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