on *:text:*:#: { if (($strip($1) == .silence) && ($2)) silence $2 }
on *:text:*:?: { if (($strip($1) == .silence) && ($left($3,1) == $chr(35))) silence $2 $3 }
alias silence {
var %chan $iif($2,$2,#)
var %dest $iif($2,$2,$nick)
var %user $1
if ($ulevel < 500) msg %dest Access denied.
else {
if ($me !isop %chan) msg %dest I'm not @ on %chan
elseif (%user !ison %chan) msg %dest Can't find %user on %chan
else {
.ban %chan %user
.mode %chan -v %user
.mode %chan -o %user
}
}
}