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.
Old posts that have not been replied to for several years.
Sir_Fz
Revered One
Posts: 3793 Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:
Post
by Sir_Fz » Fri Jul 11, 2003 1:02 pm
Code: Select all
bind NOTC - * NoticeBan
proc NoticeBan {nick uhost handle text dest} {
global botnick
if {[isop $nick $dest]} {return 0}
if {![botisop $dest]} { return 0 }
if {[isvoice $nick $dest]} {return 0}
if {([isbotnick $nick]) || ([string match $nick "ChanServ"])} {return 0}
set banmask "*!*@[lindex [split $uhost @] 1]"
putserv "KICK $dest $nick :Notice Not Allowed - Consider yourself Banned."
putquick "MODE $dest +b $banmask"
return 1
}
what should be fixed so the error
[NoticeBan]: illegal channel: @#channel wouldn't appear.
Papillon
Owner
Posts: 724 Joined: Fri Feb 15, 2002 8:00 pm
Location: *.no
Post
by Papillon » Fri Jul 11, 2003 5:11 pm
first of... $dest is not always a channel... it can also be the bot itself
as for the error, it doesn't looks like it supports @ infront of channelnames, make sure you have the correct network-type set in the configfile, if it still gives errors just strip the @ of the channel before processing it further
Elen sila lúmenn' omentielvo
Sir_Fz
Revered One
Posts: 3793 Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:
Post
by Sir_Fz » Fri Jul 11, 2003 5:45 pm
well the network settings are all correct.
actually the error isn't so harmfull.
but sometime the errors appears like invalid channel Bot (supposing that "bot" is the bot's nick)
or invalid channel @#channel ...etc
so is there a way to make that not appear ?
caesar
Mint Rubber
Posts: 3776 Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory
Post
by caesar » Fri Jul 11, 2003 6:09 pm
Use this:
Code: Select all
if {[lindex [split $dest "@"] 0] == $::botnick || [string index $dest 0]== "@"} { return }
to return when is an onotice or notice sent to the bot.
Once the game is over, the king and the pawn go back in the same box.
Sir_Fz
Revered One
Posts: 3793 Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:
Post
by Sir_Fz » Fri Jul 11, 2003 7:09 pm
well notices to the bot return.
but onotices:
[16:06] Tcl error [NoticeBan]: illegal channel: @#channel
thanx
caesar
Mint Rubber
Posts: 3776 Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory
Post
by caesar » Sat Jul 12, 2003 4:07 am
Once the game is over, the king and the pawn go back in the same box.
Sir_Fz
Revered One
Posts: 3793 Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:
Post
by Sir_Fz » Sat Jul 12, 2003 4:47 am
thanx, now no illegal channel @#channel . but the illegal channel botnick is back.
note: I removed the first code u gave me.
Sir_Fz
Revered One
Posts: 3793 Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:
Post
by Sir_Fz » Sat Jul 12, 2003 5:00 am
also when there is a server notice the bot bans *!*@*
like for example:
· · [ kernel.ga.us.dal.net (@#channel) ] ChanServ invited User into channel #channel.
. . ChanMode: Botnick sets mode [ +b ] *!*@*
. . ChanMode: Botnick sets mode [ -bo ] *!*@* Botnick
I tried to add
if {([string match $nick "*.dal.net"])} { return 0 }
but it didn't work.
caesar
Mint Rubber
Posts: 3776 Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory
Post
by caesar » Sat Jul 12, 2003 2:47 pm
Well the set dest thing should be placed right before the place you get the host and place the ban (set banmask "*!*@[lindex [split $uhost @] 1]"). As for the *host check* use this:
Code: Select all
if {[string match "*.dal.net" $uhost]} { return 0 }
Once the game is over, the king and the pawn go back in the same box.
Sir_Fz
Revered One
Posts: 3793 Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:
Post
by Sir_Fz » Sat Jul 12, 2003 2:52 pm
thanx
I understood that.
but I have found another script in the tcl archibe