I'm a quite newbie on tcl and have a question on a script i created copying parts of another one.
the basic thing i have a problem with is, that i added a public fun-kick command, but i want to prevent global and channel +m and +n as well as bots from being kicked.
so far, global owners and bots dont get kicked.
(i dont understand every option/argument/whatever from this script as i copied the relevant bits, so please have mercy if theres something horribly wrong or complicated with this script)
this is, how far i have come with that target, i'd be thankfull for any help on this.
Code: Select all
set vampy_flags "Bmnfb|Bmnfb"
set no_vampy "#novamp"
.
.
.
bind pub - !beiss pub_beiss
proc pub_beiss {nick uhost hand chan arg} {
global no_vampy vampy_flags
if {[matchattr $arg $vampy_flags $chan] || [matchattr $arg $vampy_flags]} { return 0 }
putlog "$nick used !beiss $arg"
putchan $chan "blablabla with $arg"
puthelp "KICK $chan $arg :moreblabla"
putnotc $arg "still some more blabla"
}
proc vampyflagcheck {user chan} {
global vampy_flags
set protected 0
set user [nick2hand $user]
if {[matchattr $user $vampy_flags $chan] || [matchattr $user $vampy_flags]} {
set protected 1
}
return $protected
}
oh, and i need to prevent the bot from kicking itself ... it does that
<font size=-1>[ This Message was edited by: RaeTheGit on 2002-03-03 21:25 ]</font>