Public feed #890972

Untitled

public text v1 · immutable
Raw Edit
·published 2008-02-04 06:30 UTC
rendered paste body
alias pc1 return $+($chr(3),12,$1-)
alias pc2 return $+($chr(3),03,$1-)
alias pc3 return $+($chr(3),04,$1-)
alias power {
  if (!$chan(0)) {
    echo -tsa $pc1(You aren't on) $pc2(on any) $pc3(channels!)
  }
  else {
    var %p = 1
    while (%p <= $chan(0)) {
      inc %users $nick($chan(%p),0)
      inc %users $nick($chan,%p)
      if ($me isop $chan(%p)) {
        inc %ops
      }
      if ($me ishop $chan(%p)) {
        inc %hops
      }
      if ($me isvoice $chan(%p)) {
        inc %voices
      }
      if ($me isreg $chan(%p)) {
        inc %regs
      }
      inc %p
    }
    say $pc1(I am on) $pc3($chan(0)) $pc2(channels) $pc1(with) $pc3(%users) $pc2(people) $+ . $pc1(I am op on) $pc3($iif(%ops,%ops,0) $+ / $+ $chan(0)) $pc2(channels) $+ , $pc1(Halfop on) $pc3($iif(%hops,%hops,0) $+ / $+ $chan(0)) $pc2(channels) $pc1(voice on)  $pc3($iif(%voices,%voices,0) $+ / $+ $chan(0))  $pc2(channels) $pc1(and regular on) $pc3($iif(%regs,%regs,0) $+ / $+ $chan(0)) $pc1(channels)
    unset %ops
    unset %hops
    unset %voices
    unset %regs
    unset %users
  }
}