hi
"you have been banned. Bye. | ignore $address($2,2)" if banned u have to use /ban not /ignore
and u can do it without repetition
to use only !$2 here is a bad idea if $2 isnot on chan u have to put if $2 ison # and u have to check if $2 is already ignored or not
on 10:TEXT:!warn*:#:{
if ((!$2) || ($2 !ison #)) msg # $nick $+ $chr(44) $iif(!$2,please enter !warn Nick_Here,$2 is not on #)
elseif ($ignore($address($2,2))) msg # $nick $+ $chr(44) $2 is already banned
else {
hinc -m warn $2
var %x $hget(warn,$2),%y 3 - %x
if (%x < 4) msg # 4 $+ $2 $+ , you have been warned for the $ord($v1) time. You have $iif(%y,$iif($v1 == 2,$v1 warns,$v1 warn) left before you will be banned from using me.,no more warnings remaining $+ $chr(44) this is your last chance.)
else {
msg # 4 $+ $2 $+ , you have been banned. Bye.
ignore $address($2,2)
hdel warn $2
}
}
}