Code: Select all
bind mode - "* +o" why:nick
bind notc - "*Identification to the nickname*" nick:whyed
proc why:nick {nick uhost hand chan mc vict} {
global whyed
putserv "PRIVMSG chanserv@services.dal.net :why $chan $vict"
set whyed([string tolower $vict])
}
proc nick:whyed {nick uhost hand text dest} {
global whyed
if {![info exists whyed([string tolower [lindex [split $text] 0]])]} { return 0 }
if {![string equal -nocase [lindex [split $text] 0] [string trimright [lindex [split $text] end] .]]} {
putquick "KICK [stripcodes b [string trimright [lindex [split $text] 5] .]] [string trimright [lindex [split $text] end] .] :You're using someone else's access"
unset whyed([string tolower [lindex [split $text] 0]])
}
Code: Select all
setudef flag deop
bind mode - "* +o" why:nick
bind notc - "*Identification to the nickname*" nick:whyed
proc why:nick {nick uhost hand chan mc vict} {
global whyed
if {![channel get $chan deop]} { return 0 }
putserv "PRIVMSG chanserv@services.dal.net :why $chan $vict"
set whyed([string tolower $vict])
}
proc nick:whyed {nick uhost hand text dest} {
global whyed
if {![info exists whyed([string tolower [lindex [split $text] 0]])]} { return 0 }
if {![string equal -nocase [lindex [split $text] 0] [string trimright [lindex [split $text] end] .]]} {
putquick "KICK [stripcodes b [string trimright [lindex [split $text] 5] .]] [string trimright [lindex [split $text] end] .] :You're using someone else's access"
unset whyed([string tolower [lindex [split $text] 0]])
}
Code: Select all
missing close-brace
while executing
"proc nick:whyed {nick uhost hand text dest} {
global whyed
if {![info exists whyed([string tolower [lindex [split $text] 0]])]} { return 0 }
if {![..."
(file "scripts/deop.tcl" line 13)
invoked from within
"source scripts/deop.tcl"
Code: Select all
if {![string equal -nocase [lindex [split $text] 0] [string trimright [lindex [split $text] end] .]]}
Code: Select all
if {![string equal -nocase [lindex [split $text] 0]] [string trimright [lindex [split $text] end] .]}
add a } at the end of the proc.missing close-brace
Code: Select all
........
unset whyed([string tolower [lindex [split $text] 0]])
}
}
Code: Select all
setudef flag deop
bind mode - "* +o" why:nick
bind notc - "*Identification to the nickname*" nick:whyed
proc why:nick {nick uhost hand chan mc vict} {
global whyed
if {![channel get $chan deop]} { return 0 }
putserv "PRIVMSG chanserv@services.dal.net :why $chan $vict"
set whyed([string tolower $vict])
}
proc nick:whyed {nick uhost hand text dest} {
global whyed
if {![info exists whyed([string tolower [lindex [split $text] 0]])]} { return 0 }
if {![string equal -nocase [lindex [split $text] 0] [string trimright [lindex [split $text] end] .]]} {
putquick "KICK [stripcodes b [string trimright [lindex [split $text] 5] .]] [string trimright [lindex [split $text] end] .] :You're using someone else's access"
unset whyed([string tolower [lindex [split $text] 0]])
}
}
Code: Select all
Tcl error [why:nick]: can't read "whyed(metallica-)": no such variable
Code: Select all
setudef flag deop
bind mode - "* +o" why:nick
bind notc - "*Identification to the nickname*" nick:whyed
proc why:nick {nick uhost hand chan mc vict} {
global whyed
if {![channel get $chan deop]} { return 0 }
putserv "PRIVMSG chanserv@services.dal.net :why $chan $vict"
set whyed([string tolower $vict]) 1
}
proc nick:whyed {nick uhost hand text dest} {
global whyed
if {![info exists whyed([string tolower [lindex [split $text] 0]])]} { return 0 }
if {![string equal -nocase [lindex [split $text] 0] [string trimright [lindex [split $text] end] .]]} {
putquick "KICK [stripcodes b [string trimright [lindex [split $text] 5] .]] [string trimright [lindex [split $text] end] .] :You're using someone else's access"
unset whyed([string tolower [lindex [split $text] 0]])
}
}
Code: Select all
Tcl error [nick:whyed]: invalid command name "stripcodes"
Code: Select all
proc stripcodes {str} {
regsub -all -- {\003[0-9]{0,2}(,[0-9]{0,2})?|\017|\037|\002|\026|\006|\007} $str "" str
return $str
}
Code: Select all
setudef flag deop
bind mode - "* +o" why:nick
bind notc - "*Identification to the nickname*" nick:whyed
proc stripcodes {str} {
regsub -all -- {\003[0-9]{0,2}(,[0-9]{0,2})?|\017|\037|\002|\026|\006|\007} $str "" str
return $str
}
proc why:nick {nick uhost hand chan mc vict} {
global whyed
if {![channel get $chan deop]} { return 0 }
putserv "PRIVMSG chanserv@services.dal.net :why $chan $vict"
set whyed([string tolower $vict]) 1
}
proc nick:whyed {nick uhost hand text dest} {
global whyed
if {![info exists whyed([string tolower [lindex [split $text] 0]])]} { return 0 }
if {![string equal -nocase [lindex [split $text] 0] [string trimright [lindex [split $text] end] .]]} {
putquick "KICK [stripcodes b [string trimright [lindex [split $text] 5] .]] [string trimright [lindex [split $text] end] .] :You're using someone else's access"
unset whyed([string tolower [lindex [split $text] 0]])
}
}
Code: Select all
Tcl error [nick:whyed]: wrong # args: should be "stripcodes str"
Code: Select all
setudef flag deop
bind mode - "*+o*" why:nick
bind notc - "*Identification to the nickname*" nick:whyed
proc why:nick {nick uhost hand chan mc vict} {
global whyed
if {![channel get $chan deop]} { return 0 }
putserv "PRIVMSG chanserv@services.dal.net :why $chan $vict"
set whyed([string tolower $vict]) 1
}
proc nick:whyed {nick uhost hand text dest} {
global whyed
if {![info exists whyed([string tolower [lindex [split $text] 0]])]} { return 0 }
if {![string equal -nocase [lindex [split $text] 0] [string trimright [lindex [split $text] end] .]]} {
putquick "KICK [stripcodes [string trimright [lindex [split $text] 5] .]] [string trimright [lindex [split $text] end] .] :You're using someone else's access"
unset whyed([string tolower [lindex [split $text] 0]])
}
proc stripcodes {str} {
regsub -all -- {\003[0-9]{0,2}(,[0-9]{0,2})?|\017|\037|\002|\026|\006|\007} $str "" str
return $str
}