Public paste
mIRC power
By: Arie | Date: Jun 20 2013 22:02 | Format: mIRC Scripting | Expires: never | Size: 1.43 KB | Hits: 1326

  1. alias power {
  2.   set %power.chan.counter 0
  3.   set %power.powerover 0
  4.   set %power.opchans 0
  5.   set %power.totalnetworks $scon(0)
  6.   set %power.totalnetworks.count 0
  7.   set %power.total.channels 0
  8.   set %power.max.chans 0
  9.   set %power.totalusers 0
  10.   :connectionloop
  11.   inc %power.totalnetworks.count
  12.   if ( %power.totalnetworks.count > %power.totalnetworks ) { goto end }
  13.   scon %power.totalnetworks.count
  14.   set %power.total.channels %power.total.channels + $chan(0)
  15.   set %power.max.chans $chan(0)
  16.   set %power.chan.counter 0
  17.   :loop
  18.   if ( %power.chan.counter > %power.max.chans ) { goto connectionloop }
  19.   set %power.chan.counter $calc( %power.chan.counter + 1 )
  20.   if ( $me isop $chan(%power.chan.counter) ) {
  21.     set %power.powerover %power.powerover + $nick($chan(%power.chan.counter),0)
  22.     inc %power.opchans
  23.   }
  24.   set %power.totalusers $calc(%power.totalusers + $nick($chan(%power.chan.counter),0))
  25.  
  26.   goto loop
  27.   :end
  28.   scon -r
  29.   if ( %power.total.channels = 1 ) var %power.chanword channel
  30.   if ( %power.total.channels > 1 ) var %power.chanword channels
  31.   if ( %power.totalnetworks = 1 ) var %power.netword network
  32.   if ( %power.totalnetworks > 1 ) var %power.netword different networks
  33.   msg $active I am OP'd in < $+ %power.opchans $+ / $+ %power.total.channels $+ >  %power.chanword  on < $+ %power.totalnetworks $+ > %power.netword $+ . I own < $+ %power.powerover $+ / $+ %power.totalusers $+ > ppl
  34.   unset %power.*
  35. }
  36.