| View previous topic :: View next topic |
| Author |
Message |
scyzernix Voice
Joined: 08 Aug 2010 Posts: 9
|
Posted: Sun Aug 22, 2010 3:59 am Post subject: Joining a channel |
|
|
I know it's kinda a dumb question
but seriously, how do I assign my bot to a channel.
Been searching everywhere but cant seem to find out. |
|
| Back to top |
|
 |
nml375 Revered One
Joined: 04 Aug 2006 Posts: 2857
|
Posted: Sun Aug 22, 2010 8:56 am Post subject: |
|
|
Hi,
Though not a 'dumb' kind of question, it might be a RTFM kind..
That said, up until 1.6.19 (inclusive), the usual way of adding (static) channels were through the config file using the 'channel add' command. Further channels could also be added on-the-fly using the .+chan dcc-partyline command.
As I roughly recall, the .+chan command is the preferred way since 1.6.20. _________________ NML_375, idling at #eggdrop@IrcNET |
|
| Back to top |
|
 |
blake Master
Joined: 23 Feb 2009 Posts: 201
|
Posted: Sun Aug 22, 2010 1:44 pm Post subject: Re: Joining a channel |
|
|
| scyzernix wrote: | I know it's kinda a dumb question
but seriously, how do I assign my bot to a channel.
Been searching everywhere but cant seem to find out. |
You may find this useful it safes having to enter the partyline to add channels in the bots private message just type addchan #channelname
| Code: | bind msg n addchan addchan
proc addchan {nick host hand text} {
set chan [join [lindex [split $text] 0]]
if {![string length $chan]} {
putserv "PRIVMSG $nick :You need to specify which channel to join."
return 0
}
if {[validchan $chan]} {
if {[channel get $chan "inactive"]} {
channel set $chan -inactive
return 0
}
putserv "PRIVMSG $nick :I am already on $chan."
return 0
}
channel add $chan
}
bind msg n delchan delchan
proc delchan {nick host hand text} {
set chan [join [lindex [split $text] 0]]
if {![string length $chan]} {
putserv "PRIVMSG $nick :You need to specify which channel to remove."
return 0
}
if {![validchan $chan]} {
putserv "PRIVMSG $nick :Unknown channel: $chan."
return 0
}
channel remove $chan
}
|
_________________ Blake
UKEasyHosting UKStormWatch |
|
| Back to top |
|
 |
scyzernix Voice
Joined: 08 Aug 2010 Posts: 9
|
Posted: Tue Aug 24, 2010 10:02 am Post subject: |
|
|
| nml375 wrote: | Hi,
Though not a 'dumb' kind of question, it might be a RTFM kind..
That said, up until 1.6.19 (inclusive), the usual way of adding (static) channels were through the config file using the 'channel add' command. Further channels could also be added on-the-fly using the .+chan dcc-partyline command.
As I roughly recall, the .+chan command is the preferred way since 1.6.20. |
Lol. That, I know. Thanks for answering the RTMF ques.
| blake wrote: | | scyzernix wrote: | I know it's kinda a dumb question
but seriously, how do I assign my bot to a channel.
Been searching everywhere but cant seem to find out. |
You may find this useful it safes having to enter the partyline to add channels in the bots private message just type addchan #channelname
| Code: | bind msg n addchan addchan
proc addchan {nick host hand text} {
set chan [join [lindex [split $text] 0]]
if {![string length $chan]} {
putserv "PRIVMSG $nick :You need to specify which channel to join."
return 0
}
if {[validchan $chan]} {
if {[channel get $chan "inactive"]} {
channel set $chan -inactive
return 0
}
putserv "PRIVMSG $nick :I am already on $chan."
return 0
}
channel add $chan
}
bind msg n delchan delchan
proc delchan {nick host hand text} {
set chan [join [lindex [split $text] 0]]
if {![string length $chan]} {
putserv "PRIVMSG $nick :You need to specify which channel to remove."
return 0
}
if {![validchan $chan]} {
putserv "PRIVMSG $nick :Unknown channel: $chan."
return 0
}
channel remove $chan
}
|
|
Thanks, I have to try this one out. The code should be pasted in the .conf correct? |
|
| Back to top |
|
 |
blake Master
Joined: 23 Feb 2009 Posts: 201
|
Posted: Tue Aug 24, 2010 11:20 am Post subject: |
|
|
Eather add it to the end of the config or add it as a script _________________ Blake
UKEasyHosting UKStormWatch |
|
| Back to top |
|
 |
|