All pastes #756912 Raw Edit

Clone Scan

public text v1 · immutable
#756912 ·published 2007-10-31 20:40 UTC
rendered paste body
alias c { 
  updatenl 
  var %h,%e,%y,%x 1,%* echo -atc info *,%d detected. 
  if $1 { 
    linesep 
    %h = 1 
  } 
  %f = $iif(%h,%*,msg #) 
  $iif(%h,%*,me is) scanning for clones in # $+ , Please wait. 
  while $nick(#,%x) { 
    %a = $address($v1,2) 
    if $ial(%a,0) > 1 && %a !isin %e { 
      %n = 1 
      while $ial(%a,%n).nick { 
        %t = %t $v1 
        inc %n 
        inc %y 
      } 
      %e = %e %a 
    } 
    if (%t) %f $+([,%a,]) %t 
    %t = 
    inc %x 
  } 
  %f $iif(%e,Clone scan complete! $numtok(%e,32) matching address(es) %d %y clone(s) %d,No Clones Detected!) 
  if (%h) linesep 
} 

menu channel {
  Clone Scan
  .Echo:c 1 
  .Channel:c 
}