trill commented on a Page, Services Windows  -  Apr 19, 2010

you can turn this

on 1:INPUT:@ChanServ*:{
  .msg chanserv $1-
  halt
}
on 1:INPUT:@BotServ*:{
  .msg botserv $1-
  halt
}
on 1:INPUT:@HostServ*:{
  .msg hostserv $1-
  halt
}
on 1:INPUT:@NickServ*:{
  .msg nickserv $1-
  halt
}
on 1:INPUT:@MemoServ*:{
  .msg memoserv $1-
  halt
}
on 1:INPUT:@Operserv*:{
  .msg operserv $1-
  halt
}

into this to make it alil smaller just to give you an idea.

on *:INPUT:*:{ 
  if ($regex($1,/^@((Chan|Bot|Nick|Memo|Host|Oper)Serv?\b)/iS)) { 
    .msg $regml(1) $2- 
    haltdef
  }
}

you can also do much more to shorten the on notices. maybe somthing like this.

on ^*:NOTICE:*:?:{
  if ($regex($nick,/((Chan|Bot|Nick|Memo|Host|Oper)Serv?\b)/i)) {
    if (!$window($+(@,$nick,.,$network))) { window -e0 $+(@,$nick,.,$network) }
    aline -p $+(@,$nick,.,$network) $nick : $1-
    haltdef
  }
}

so the whole code would be

on *:INPUT:*:{ 
  if ($regex($1,/^@((Chan|Bot|Nick|Memo|Host|Oper)Serv?\b)/iS)) { 
    .msg $regml(1) $2- 
    haltdef
  }
}
on ^*:NOTICE:*:?:{
  if ($regex($nick,/((Chan|Bot|Nick|Memo|Host|Oper)Serv?\b)/i)) {
    if (!$window($+(@,$nick,.,$network))) { window -e0 $+(@,$nick,.,$network) }
    aline -p $+(@,$nick,.,$network) $nick : $1-
    haltdef
  }
}

thanks to napa for helping me make this smaller

 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.