proc kickban {nik uhost hand chn txt} {
global botnick
set nick [lindex $txt 0]
set reas [lrange $txt 1 end]
set target [getchanhost $nick $chn]
set banmask "*!*[string trimleft [string range $target [string first "!" $target] end] ?^~-_+?]"
if {[string tolower $nick] != [string tolower $botnick]} {
if {![string length [string trim $reas]]} {
set reas "banned by \[${hand}/\002${nik}\002] - Geen reden opgegeven..."} else {
set reas "banned by \[${hand}/\002${nik}\002] - $reas"}
putserv "mode $chn +b $banmask"
putserv "kick $chn $nick $reas"
}
}