Code: Select all
proc notmemobot {from keyword arg} {
global botnick memochan chnmemnick memsrvnick lchnmemnick lmemsrvnick cserv_ip sendmemoserv fusernote fusermemo fnduname perfnick perfip optype opperf opnick acctype accnick utlcfmlg
set nick [lindex [split $from !] 0] ; set uhost [lindex [split $from !] 1]
if {[string match "*.*" $nick]} {return 0}
if {[string match "@" $chnmemnick]} {set lchnmemnick [lindex [split $chnmemnick @] 0]} else {set lchnmemnick $chnmemnick}
if {![string match *[string tolower $cserv_ip]* [string tolower $uhost]]} {return 0}
if {[string match "*op * add*" $arg] || [string match "*op * del*" $arg] || [string match "*akick * add*" $arg] || [string match "*akick * del*" $arg]} {
set chan [lindex [split [string tolower [lindex $arg 0]] @] 1]
if {[string toupper $chan] != [string toupper $memochan]} {return 0}
set perfhost [lindex $arg 2] ; set perfnick [string trim [lindex [split $perfhost !] 0] ""] ; set perfip [lindex [split $perfhost !] 1]
set optype [lindex $arg 6] ; set opperf [lindex $arg 4] ; set opnick [lindex $arg 7]
putquick "PRIVMSG $chnmemnick :why $chan $perfnick" ; putquick "PRIVMSG $chnmemnick :info $chan"
putlog "$utlcfmlg doing /$lchnmemnick why $chan $perfnick and /$nick info for $chan" ; return 0
}
if {[string match "*has * access*" $arg]} {
set acctype [lindex $arg 3]
if {[string match "*FOUNDER*" [string toupper $acctype]]} {set accnick [string trim [lrange $arg 13 end] "."]} else {set accnick [lrange $arg 11 12]}
putlog "$utlcfmlg $perfnick has $acctype access on channel: $memochan, identify to: $accnick" ; return 0
}
if {[string match "*FOUNDER*" [string toupper $arg]] && ![string match "*emo *eve*" [string toupper $arg]]} {
set chanfnd [lindex $arg 3]
if {![info exist perfnick] || ![info exist perfip] || ![info exist optype] || ![info exist opperf] || ![info exist opnick] || ![info exist acctype] || ![info exist accnick]} {return 0}
if {$sendmemoserv} {
if {[string match "@" $memsrvnick]} {set lmemsrvnick [lindex [split $memsrvnick @] 0]} else {set lmemsrvnick $memsrvnick}
putquick "PRIVMSG $memsrvnick :send $chanfnd $utlcfmlg $acctype: $perfnick [$perfip] (Identify to: $accnick) $optype [string toupper $opperf] for: $opnick on channel: $memochan"
putlog "$utlcfmlg doing /$lmemsrvnick send $chanfnd $acctype: $perfnick [$perfip] (Identify to: $accnick) $optype [string toupper $opperf] for: $opnick on channel: $memochan"
}
if {$fusermemo} {
foreach fusername1 $fnduname {
putquick "PRIVMSG $memsrvnick :send $fusername1 $utlcfmlg $acctype: $perfnick [$perfip] (Identify to: $accnick) $optype [string toupper $opperf] for: $opnick on channel: $memochan"
putlog "$utlcfmlg doing /$lmemsrvnick send $fusername1 $acctype: $perfnick [$perfip] (Identify to: $accnick) $optype [string toupper $opperf] for: $opnick on channel: $memochan"
}
}
if {$fusernote} {
foreach fusername2 $fnduname {
if {[validuser $fusername2]} {
sendnote $botnick $fusername2 "$utlcfmlg $acctype: $perfnick [$perfip] (Identify to: $accnick) $optype [string toupper $opperf] for: $opnick on channel: $memochan"
putlog "$utlcfmlg Sending personal NOTES to: $fusername2"
}
}
} ; unset perfnick ; unset perfip ; unset optype ; unset opperf ; unset opnick ; unset acctype ; unset accnick ; return 0
} ; return 0
}
The error is:
Code: Select all
[16:05] TCL error [notmemobot]: extra characters after close-quote