X-Git-Url: https://git.distorted.org.uk/~mdw/ircbot/blobdiff_plain/1642e0e0eab8d48eac46befc06d414905487bfe5..refs/tags/mergeup-1-2001-10-09-tell:/bot.tcl diff --git a/bot.tcl b/bot.tcl index 4685581..1060027 100755 --- a/bot.tcl +++ b/bot.tcl @@ -1198,9 +1198,27 @@ def_ucmd identpass { ucmdr "Pleased to see you, $username." {} } +def_ucmd kill { + global nick + prefix_nick + set target [ta_nick] + if {![nickdb_exists $target]} { error "$target is not a registered nick." } + set wantu [nickdb_get $target username] + if {![string length $wantu]} { error "$target is insecurely registred." } + upvar #0 nick_username([irctolower $n]) nu + if {![info exists nu]} { error "You must identify yourself first." } + if {"$wantu" != "$nu"} { + error "You are the wrong user, $nu - $target belongs to $wantu." + } + set reason "at request of user $nu" + if {[ta_anymore]} { append reason "; $text" } + sendout KILL $target $reason +} + def_ucmd summon { set target [ta_word] ta_nomore + # fixme would be nice if the rest of the text was passed on instead check_username $target prefix_nick @@ -1369,6 +1387,10 @@ proc ensure_globalsecret {} { } proc connected {} { + global operuserpass + if {[info exists operuserpass]} { + eval sendout OPER $operuserpass + } foreach chan [chandb_list] { if {[chandb_get $chan autojoin]} { dojoin $chan } }