|
Joined: Sep 2003
Posts: 93
Babel fish
|
OP
Babel fish
Joined: Sep 2003
Posts: 93 |
Got a little test for experienced scripters...
What I want is to create under raw 366 is a complete listing of nicks (and their modes) along with the percentages when I join a channel..
This is what I have under my popups...
Channel Stats:echo -a 4,1 Channel Stats for0,1 # 13,01Owners: 03,01( $+ $nick($active,0,~,o) $+ ) 12,01SuperOps:14,01 ( $+ $nick($active,0,&,o) $+ ) 07,01SeniorOps:00,01 ( $+ $nick($active,0,!,o) $+ ) 11,01Ops:08,01 ( $+ $opnick(#,0) $+ ) 06,01HalfOps:10,01 ( $+ $nick($active,0,h,o) $+ ) 13,01Voices:9,1 ( $+ $nick($active,0,v,o) $+ ) 12,01Regulars:15,1 ( $+ $nvnick(#,0) $+ ) 04,01Total:00,01 ( $+ $nick(#,0) $+ ) 08,01Time:07,01 $asctime(h:nntt) 11,01Date:12,01 $adate
It's one line - apologies for the multilines.
I tried using the same type thing in remotes but it only worked partially.
Any help would be appreciate especially in terms of code cleanup and completeness.
Talea
|
|
|
|
Joined: Mar 2004
Posts: 108
Vogon poet
|
Vogon poet
Joined: Mar 2004
Posts: 108 |
raw 353 - and you want it to list names? I dont follow.. like list to a seperate window, file, dialog?
sometimes these are as bad as quit messages :tongue:
|
|
|
|
Joined: Aug 2003
Posts: 1,831
Hoopy frood
|
Hoopy frood
Joined: Aug 2003
Posts: 1,831 |
This is still all on one line, it just utilizes $& to split the line into many for readabilty purposes in the mirc editor (and on this board). See /help $& raw 366:*:{
echo -it $2 4,1 Channel Stats for0,1 $2 13,01Owners: 03,01( $+ $nick($2,0,~) $+ ) $&
12,01SuperOps:14,01 ( $+ $nick($2,0,&) $+ ) 07,01SeniorOps:00,01 ( $+ $nick($2,0,!) $+ ) $&
11,01Ops:08,01 ( $+ $nick($2,0,o) $+ ) 06,01HalfOps:10,01 ( $+ $nick($2,0,h) $+ ) $&
13,01Voices:9,1 ( $+ $nick($2,0,v) $+ ) 12,01Regulars:15,1 ( $+ $nick($2,0,r) $+ ) $&
04,01Total:00,01 ( $+ $nick($2,0) $+ ) 08,01Time:07,01 $time(h:nntt) 11,01Date:12,01 $adate
}
|
|
|
|
Joined: Sep 2003
Posts: 93
Babel fish
|
OP
Babel fish
Joined: Sep 2003
Posts: 93 |
I didn't know about the $& - now I do and thanks... I'll give it a shot and let you know Talea P.S. Update...works like a charm! (wonder if there's a way of also adding percentages to the stats???... hmmm)
Last edited by Talea; 17/05/04 11:30 AM.
|
|
|
|
Joined: Aug 2003
Posts: 1,831
Hoopy frood
|
Hoopy frood
Joined: Aug 2003
Posts: 1,831 |
raw 366:*:{
var %a = $nick($2,0),%l = (,%r = )
echo -it $2 04,01 Channel Stats for00 $2 13Owners:03 $nick($2,0,~) $&
$+(%l,$round($calc($nick($2,0,~)/ %a *100),0),%,%r) 12SuperOps:14 $nick($2,0,&) $&
$+(%l,$round($calc($nick($2,0,&)/ %a *100),0),%,%r) 07SeniorOps:00 $nick($2,0,!) $&
$+(%l,$round($calc($nick($2,0,!)/ %a *100),0),%,%r) 11Ops:08 $nick($2,0,o) $&
$+(%l,$round($calc($nick($2,0,o)/ %a *100),0),%,%r) 06HalfOps:10 $nick($2,0,h) $&
$+(%l,$round($calc($nick($2,0,h)/ %a *100),0),%,%r) 13Voices:09 $nick($2,0,v) $&
$+(%l,$round($calc($nick($2,0,v)/ %a *100),0),%,%r) 12Regulars:15 $nick($2,0,r) $&
$+(%l,$round($calc($nick($2,0,r)/ %a *100),0),%,%r) 04Total:00 %a $&
08Time:07 $time(h:nntt) 11Date:12 $adate
}
|
|
|
|
Joined: Sep 2003
Posts: 93
Babel fish
|
OP
Babel fish
Joined: Sep 2003
Posts: 93 |
Thanks plenty for your help... eventually I might have gotten it but with 2 sprained ankles and torn ligaments, I'm in a lot of pain and can't think about mirc scripting. Talea
|
|
|
|
|