Channel Stats
alias chanstats {
set %temp.op 0
set %temp.voice 0
set %temp.half 0
set %temp.reg 0
set %temp.total 0
set %temp.ircop 0
set %temp.away 0
set %temp.clones 0
set %temp.chan #
.who %temp.chan
.enable #c.stat
}
#c.stat off
raw 352:*:{
if (@ isin $7) || (~ isin $7) { inc %temp.op }
if (~ !isin $7) && (+ isin $7) && (@ !isin $7) && (% !isin $7) { inc %temp.voice }
if (~ !isin $7) && (+ !isin $7) && (@ !isin $7) && (% isin $7) { inc %temp.half }
if (~ !isin $7) && (+ !isin $7) && (@ !isin $7) && (% !isin $7) { inc %temp.reg }
if (G isin $7) { inc %temp.away }
if (* isin $7) { inc %temp.ircop }
if ($ialchan($+(*!*@,$4),%temp.chan,0) > 1) { inc %temp.clones }
inc %temp.total
halt
}
raw 315:*:{
echo $color(info) %temp.chan -
echo %temp.chan Ops Total: $+(,%temp.op,) $+([,$remove($round($calc((%temp.op / %temp.total)*100),1),.0),%,])
echo %temp.chan Halfops Total: $+(,%temp.half,) $+([,$remove($round($calc((%temp.half / %temp.total)*100),1),.0),%,])
echo %temp.chan Voiced Total: $+(,%temp.voice,) $+([,$remove($round($calc((%temp.voice / %temp.total)*100),1),.0),%,])
echo %temp.chan Regulars Total: $+(,%temp.reg,) $+([,$remove($round($calc((%temp.reg / %temp.total)*100),1),.0),%,])
echo %temp.chan Ircop Total: $+(,%temp.ircop,) $+([,$remove($round($calc((%temp.ircop / %temp.total)*100),1),.0),%,])
echo %temp.chan Away Total: $+(,%temp.away,) $+([,$remove($round($calc((%temp.away / %temp.total)*100),1),.0),%,])
echo %temp.chan Clone Total: $+(,%temp.clones,) $+([,$remove($round($calc((%temp.clones / %temp.total)*100),1),.0),%,])
echo %temp.chan Moded Total: $+(,$calc(%temp.op + %temp.half + %temp.voice),) $+([,$remove($round($calc(($calc(%temp.op + %temp.half + %temp.voice) / %temp.total)*100),1),.0),%,])
echo $color(info) %temp.chan -
unset %temp.*
clear -s
.disable #c.stat
}
#c.stat end