Hello guys, any suggestion how to make this hash badword to give ban to hostmask of user when is match the badword,
and how to make the badword to be add like /bwadd /bwdel *azz* *azz azz* to match the word azzhole azz hole azz-hole azz`hole, like user say ffff i want to !bwadd *ff* or ff* or *ff

on *:start:{
if !$hget(Badwords) { .hmake Badwords 100 }
if $exists(Badwords.txt) {
.hload -n Badwords Badwords.txt
}
}
on *:text:*:#:{
var %bw.code = $strip($1-)
%bw.code = $replace(%bw.code,$chr(44),$chr(32))
tokenize 32 %bw.code
if $1 == !bwadd {
if !$2 {
.notice $nick Usage: !bwadd <list of bad words to be added, space or comma separated)
}
else {
tokenize 32 $2-
var %a = $0
while %a {
if !$hfind(Badwords,$($+($,%a),2),1).data {
.hadd -m Badwords $calc($hget(Badwords,0).item + 1) $($+($,%a),2)
}
dec %a
}
.hsave -n Badwords Badwords.txt
}
}
elseif $1 == !bwdel {
if !$2 {
.notice $nick Usage: !bwdel <list of bad words to be deleted, space or comma separated)
}
else {
tokenize 32 $2-
var %a = $0
while %a {
.hdel Badwords $hfind(Badwords,$($+($,%a),2),1).data
}
dec %a
}
.hsave -n Badwords Badwords.txt
}
elseif $1 == !bwlist {
.hsave -n Badwords Badwords.txt
.msg $nick Warning the Badwords file currently has $hget(Badwords,0).item entries
.play $nick Badwords.txt
}
}