Code: Select all
proc pub:join {nick host hand chan arg} {
set chan [lindex $arg 0]
#set match [string map {\\ \\\\ [ \\\[ ] \\\] \{ \\\{ \} \\\}} $match]
#proc icodes str { regexp {r:\d{1,3}\sb:\d{1,3}\su:\d{1,3}\sc:\d{1,3}} $str }
if {[matchattr $hand A] == 0} {noaccess2 $nick ; return}
if {$chan == $match} {notice $nick "You must provide a valid channel name." ; return}
if {![llength [split $arg]] || [validchan [set channel [lindex [split $arg] 0]]]} {
putquick "NOTICE $nick :\002join\002\: requires more parameters."
} else {
cmdlog $chan $nick $hand "join $chan"
channel add $chan
putquick "NOTICE $nick :I have joined \002$chan\002"
putlog "\[[ctime [unixtime]]\] ($chan|$host) \[$nick:$hand\]: join $chan"
}
}
Code: Select all
proc pub:join {nick host hand chan arg} {
set chan [string map {\\ \\\\ [ \\\[ ] \\\] \{ \\\{ \} \\\} $ \\\$ \" \\\"} [string tolower [lindex $arg 0]]]
if {[string equal "0" [matchattr $hand A]]} {noaccess2 $nick; return 0}
if {[string equal -nocase $match $chan]} {putserv "NOTICE $nick :You must provide a valid channel name." ; return 0}
if {![llength [split $arg]] || [validchan $chan]} {
putquick "NOTICE $nick :\002join\002\: requires more parameters."
} else {
cmdlog $chan $nick $hand "join $chan"
channel add $chan
putquick "NOTICE $nick :I have joined \002$chan\002"
putlog "\[[ctime [unixtime]]\] ($chan|$host) \[$nick:$hand\]: join $chan"
}
}
Code: Select all
if {[string match {*[`~@]*} [string index $chan 0]] || [string equal "##" [string range $chan 0 2]]} { return 0 }
Which will return invalid channel.(trigger)join #
Which will return invalid channel.(trigger)join #any sort of character
Bot joins the channel.(trigger)join #word
Code: Select all
proc pub:join {nick host hand chan text} {
if {[lindex $text 0] == ""} {
putserv "PRIVMSG $chan :Please provide a channel name"; return 0
}
set chan [string map {\\ \\\\ [ \\\[ ] \\\] \{ \\\{ \} \\\} $ \\\$ \" \\\"} [string tolower [lindex $text 0]]]
if {[string match {*[`~@$"]*} $chan] || [string match "* *" $chan] || ([regexp -all {\#} $chan] > 1)} {
putserv "PRIVMSG $chan :Please provide a valid channel name"; return 0
}
if {[string equal "#" [string index $chan 0]] && [string match "#*" $chan] && [regexp -nocase {[0-9a-z]} [string range $chan 1 end]] && ([string length $chan] >= 2)} {
channel add $chan
putserv "PRIVMSG $chan :I have joined \002$chan\002."
}
}
It's *\[ab\]* and not */[ab/]*. With or without quotes makes no difference.dq wrote:Ahh, I understand.. but what's the difference between using "*/[ab/]*" and just */[ab/]* as that's what I was using and it was breaking the bot?
thx[13:09] Tcl error in file 'baghira.conf':
[13:09] unmatched open quote in list
while executing
"lrange $apl 2 end"
(procedure "rd" line 5)
invoked from within
"rd"
(procedure "load" line 50)
invoked from within
"load"
(in namespace eval "::AllProtection" script line 2567)
invoked from within
"namespace eval AllProtection {
# Basic declarations: (don't touch)
variable declr
foreach declr {textl textc notcl notcc capsp repeatf codesf adexemp..."
(file "scripts/allprotection4.6b7.tcl" line 140)
invoked from within
"source scripts/allprotection4.6b7.tcl"
(file "baghira.conf" line 1350)
[13:09] * KONFIGURATIONSDATEI NICHT GELADEN (NICHT GEFUNDEN ODER FEHLER)
tybchans global #example1 #example2 #example3
bnicks global *porno* *horny* *horney* *[censored]* *asshole* *dick* *bitch* *fagget* *shithead* *shitter* *penis* *pussy* *fukker* *camsex* *hure* *nutte* *fick* *[censored]*
bidents global *porno* *horny* *horney* *[censored]* *asshole* *dick* *bitch* *fagget* *shithead* *shitter* *penis* *pussy* *fukker*
bwords global *[censored]* "*bastard *" *cock* "* [censored] *" *ommak* *fag* "* fick*" *fick* *asshole* *bitch* *pussy* "* whore *" "* slut *" *dickhead* *horny* "* shithead *" *fagget* "* dick? *" "* fag? *" "* fuker *" *penis* "* fuk *" *hure* *fotze* *nutte*
adexempts global %chan www.egghelp.org
droneexempts global "*example1*!*@*" "*!*example2*@*" "*!*@example3.net"
bctcrs global "*exploitation script*"
adwords global "*join *" "*plz visit*" "*http://*
ptextl punish 12:6
ptextc punish 750:6
pnotil punish 6:3
pnotic punish 600:4
pctcpf punish 4:20