source stdhelp.tcl
proc privmsg_unlogged {p ischan params} {
- global bots errorCode errorInfo line_org_1char
+ global bots errorCode errorInfo line_org_endchar
if {$ischan} {
if {[catch {
prefix_nick
set text [lindex $params 1]
- if {"$line_org_1char" == "\001"} {
+ if {"$line_org_endchar" == "\001"} {
if {[regexp {^\?ACTION (.*)\?$} $text dummy text]} {
set towrite "* $n $text"
} else {
set towrite "\[$n] [lindex $params 1]"
}
foreach botid $bots {
- upvar #0 bot/$botid/bnchan ch
+ upvar #0 bot/$botid/chan ch
puts $ch $towrite
}
} emsg]} {
global channel errorCode
if {[regexp {^1002 JOIN ([^ ]+) \w+} $l dummy n]} {
set bnnicks($n) 1
- sendprivmsg $channel "[bnnick_clean $n] has joined $bnchanfn"
+ sendprivmsg $channel "[bnnick_clean $n] has joined $bnchanfn."
} elseif {[regexp {^1003 LEAVE ([^ ]+) \w+$} $l dummy n]} {
if {"$n" == "$bnnick"} return
catch { unset bnnicks($n) }
- sendprivmsg $channel "[bnnick_clean $n] has left $bnchanfn"
+ sendprivmsg $channel "[bnnick_clean $n] has left $bnchanfn."
} elseif {[regexp {^1004 WHISPER ([^ ]+) \w+ "(.*)"$} $l dummy n text]} {
if {[catch {
go_usercommand "$botid $n" $bnchanfn $n $n $text
proc msg_JOIN {p c chan} {
global onchan_nicks
prefix_nick
- tellall "$n has joined $chan"
+ tellall "$n has joined $chan."
set onchan_nicks($n) 1
}
prefix_nick
kill_nick $n
set onchan_nicks($newnick) 1
- tellall "$n has changed nicks to $newnick"
+ tellall "$n has changed nicks to $newnick."
}
proc kill_nick {n} { global onchan_nicks; catch { unset onchan_nicks($n) } }
}
proc msg_PART {p c chan} {
prefix_nick
- tellall "$n has left $chan"
+ tellall "$n has left $chan."
kill_nick $n
}
proc msg_QUIT {p c why} {