Code: Select all
/msg bot !identify pass
Code: Select all
[02:36] [XAPOH!~pycbocmok@81.198.55.1] !identify password
Code: Select all
/msg bot !identify pass
Code: Select all
[02:36] [XAPOH!~pycbocmok@81.198.55.1] !identify password
and how i can fix it?gb wrote:it most likely happen because you have a (unneded) return 1 at the end of your proc.
Code: Select all
proc maf:identify {n uh h t} {
global mafs mafmsg
if {[onchan $n $mafs(curchannel)]==0} {return 0}
set id [makeid $n]
if {[maf:isidentify $id]==1} {
maf:msg $n "Nick5 $n already identified"
return 0}
if {[maf:isregister $id]==0} {
maf:msg $n "Nick $n unregistered!"
return 0
}
if {[maf:checkpass $id [lindex $t 1]]==0} {
maf:msg $n " sorry, password incorrect"
return 0
}
if {[maf:checkaddress $id $uh]==0} {
maf:msg $n "userhost incorrect"
return 0
}
putlog "[maf:getinfo ident $id] $id"
maf:setinfo ident $id 1
putlog "[maf:getinfo ident $id]"
maf:setinfo identtime $id [clock seconds]
maf:msg $n "nick $n sucefully identified!"
maf:returnplayer $id
if {(([maf:isnickplayer $id]==0)||($mafs(isgame)==0))&&([maf:getlevel $id]>0)} {
}
return 0
}
user wrote:what kind of bind is triggering this proc?
Code: Select all
bind msgm - "!identify*" maf:identify
this work perfectly, big thanks. But, i have not one procedure (!setpass, !setnickpass, !register - too), and this procedures calls 2 times: afteruser wrote:change it to 'bind msg - !identify maf:identify' and change '[lindex $t 1]' to just '$t'
Code: Select all
bind msg - !register maf:register
Code: Select all
if {[lindex "$t" 0]=="!register"} {return 0}