WorldDMT commented on a Page, Channel Modes for Justin.tv  -  Jul 24, 2010

to avoid repetition u can use $iif() and u can use tokenize and use $1 untead of $regml(1)
and /ban -k to kick ban user

on @$*:text:/^(\!purge|[+-](f|m))\b/iS:#:{
  if !%f {
    inc -u4 %f
    tokenize 32 $strip($1-)
    if ($1 == !purge) && ($2 ison #) {
      ban -k # $2 2
      notice $2 message's been purged.
    }
    var %x $pos($1,+,1),%y $right($1,1)
    elseif ((%x) && (%y !isincs $chan(#).mode)) || ((!%x) && (%y isincs $chan(#).mode)) {
      mode # $1
      msg # $nick $+ , # is $iif(%x,now,no longer) $iif(%y = m,in slow mode.,in friends only mode.)
    }
  }
}
 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.