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.

Script that "collects" Channel-Events

Old posts that have not been replied to for several years.
Locked
m
moonchild
Voice
Posts: 4
Joined: Fri Jun 10, 2005 8:09 am

Script that "collects" Channel-Events

Post by moonchild »

Hi, I'm searching for a tcl that Collects channel-events like join, part, kick etc. on the channels the bot is in and then posts the collected information to another channel.

Do you understand what I'm talking about? :D
Does anyone have a ready-to-use script or can help me crating one?

Thanks so far,
moonchild
User avatar
demond
Revered One
Posts: 3073
Joined: Sat Jun 12, 2004 9:58 am
Location: San Francisco, CA
Contact:

Post by demond »

creating one is easy - just bind to events which are of interest to you and inside the handler post to another channel:

Code: Select all

bind join - * pjoin
proc pjoin {n u h c} {
  puthelp "privmsg $::otherchan :$n!$u has joined $c"
}
i
inxs
Voice
Posts: 29
Joined: Fri Jun 10, 2005 5:33 am
Location: India

Post by inxs »

demond which channel will it message .. means will it send join/part/quit/kick?
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

to this channel

Code: Select all

set otherchan "#channel"
demond's code is an example, it relays the joins to #channel. If you want it to relay other events read tcl-commands.doc about binds.
m
moonchild
Voice
Posts: 4
Joined: Fri Jun 10, 2005 8:09 am

Post by moonchild »

Thanks a lot for your answers!
m
moonchild
Voice
Posts: 4
Joined: Fri Jun 10, 2005 8:09 am

Post by moonchild »

I wrote the follwing:
bind join - * pjoin
set otherchan "#smart-change"
proc pjoin {n u h c} {
puthelp "privmsg $::otherchan :$n!$u has joined $c"
}
but nothing happens... Am I just too stupid?
i
inxs
Voice
Posts: 29
Joined: Fri Jun 10, 2005 5:33 am
Location: India

Post by inxs »

this code only works on join can u give me the code on quit ? :D
User avatar
^DooM^
Owner
Posts: 772
Joined: Tue Aug 26, 2003 5:40 pm
Location: IronForge
Contact:

Post by ^DooM^ »

Question:
inxs wrote:this code only works on join can u give me the code on quit ?
Answer:
Sir_Fz wrote:If you want it to relay other events read tcl-commands.doc about binds.
:wink:
The lifecycle of a noob is complex. Fledgling noobs gestate inside biometric pods. Once a budding noob has matured thru gestation they climb out of their pod, sit down at a PC, ask a bunch of questions that are clearly in the FAQ, The Noob is born
m
moonchild
Voice
Posts: 4
Joined: Fri Jun 10, 2005 8:09 am

Post by moonchild »

Hi, the code you give me does not work... whenever a user joins to the channel the bot does not report that Join-event to the relay channel :- :(
Locked