Basic — File Browser
Basicv09272000 / Basicv09272000 / SYS / who.ini
who.ini — 5.45 KB — Download this file
[aliases]
n0=;who display
n1=who {
n2= if ($server == $null) halt
n3= if ($i(display,who) == echo) %wecho.display = echo
n4= unset %who.head %wecho.who
n5= if ($1) who.set $1
n6= elseif (($active ischan) || ($query($active))) who.set $active
n7= elseif (=* iswm $active) {
n8= if ($server) who.set $remove($active,=)
n9= else iecho Not connected to server
n10= }
n11= else iecho /who - Insufficient parameters
n12=}
n13=who.set {
n14= %who.echo = $addtok(%who.echo,$1,44)
n15= %who.targ = $1
n16= %who.count. [ $+ [ $1 ] ] = 0
n17= .raw WHO $$1
n18=}
n19=who.echo echo $1 $replace($2-,&c1,$c1,&c2,$c2,&c3,$c3,&c4,$c4,&c5,$c5)
n20=who.store {
n21= inc %who.count. [ $+ [ %who.targ ] ]
n22= if ($hget(%who.targ) == $null) hmake %who.targ 999
n23= hadd %who.targ %who.count. [ $+ [ %who.targ ] ] $6 $bind($3,@,$4) $2 $5 $8 $7 $9-
n24=}
n25=who.display {
n26= if ($format(who,$1)) { $ifmatch | return }
n27= if ($i(display,whostyle) == simple) { who.display3 $1- | return }
n28= if ($hget(%who.targ) == $null) return
n29= %wecho.win = $iif((@* iswm $active) || (=* iswm $active) || ($query($active)) || ($active == Status Window),-s,$active)
n30= %wecho.cmnd = who.echo %wecho.win
n31= %wecho.name = (&c3WHO&c1/&c3 $+ $1 $+ &c1)
n32= %wecho.line = $str(Ä,$calc(44 - $len($remove(%wecho.name,,&c1,&c3))))
n33= %wecho.cmnd &c1ÚÄ $+ %wecho.name $+ &c1 $+ %wecho.line $+ &c1Ä¿
n34= %wecho.cmnd &c1³ ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄ-- Ä-ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÅÄÄ¿
n35= %wecho.cmnd &c1ÀÄÄÅÄÄÄÄÄÄ-- ÄÄÄÄ Ä-ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ ³
n36= %wecho.even = 1
n37= %wecho.i = 1
n38= while ($hget(%who.targ,%wecho.i)) {
n39= var %read = $ifmatch
n40= var %stat = ( $+ $gettok(%read,6,32) $+ / $+ $gettok(%read,5,32) $+ ) $gettok(%read,4,32)
n41= var %name = $gettok(%read,7-,32), %line = $gettok(%read,1,32) ( $+ $gettok(%read,2,32) $+ )
n42= var %chan = $gettok(%read,3,32)
n43= if (%wecho.even) %wecho.spa =
n44= else unset %wecho.spa
n45= who.disp.temp %line
n46= who.disp.temp %name
n47= who.disp.temp %chan
n48= who.disp.temp %stat
n49= if (%wecho.even) {
n50= %wecho.even = 0
n51= %wecho.cmnd &c1ÚÄÄÅÄÄÄÄÄÄÄÄÄÄ&c2--&c1ÄÄ- &c5ÄÄÄ &c2-&c1ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿ |
n52= %wecho.cmnd &c1| ÀÄÄÄÄÄÄÄÄÄÄÄÄ&c4--&c2Ä &c1ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÅÄÄÙ
n53= }
n54= else {
n55= %wecho.even = 1
n56= %wecho.cmnd &c1| ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ&c5ÄÄÄ-&c2-- &c1ÄÄÄÄÄÄÄÄÄÄÄÅÄÄ¿
n57= %wecho.cmnd &c1ÀÄÄÅÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ ÄÄ&c4--&c3Ä&c2Ä&c1- ÄÄÄÙ |
n58= }
n59= inc %wecho.i
n60= }
n61= if (%wecho.even) %wecho.cmnd &c1ÀÄ $+ $str(Ä,$calc(44 - $len($remove(%wecho.name,,&c3,&c1,&c2)))) $+ %wecho.name $+ &c1ÄÙ
n62= else %wecho.cmnd &c1ÀÄ $+ $str(Ä,$calc(44 - $len($remove(%wecho.name,,&c3,&c1,&c2)))) $+ %wecho.name $+ &c1ÄÙ
n63= %who.echo = $remtok(%who.echo,%who.targ,44)
n64= unset %who.targ
n65= .timer.wechounset 1 3 unset %wecho.*
n66=}
n67=who.disp.temp {
n68= %.randcol1 = $r(1,5)
n69= %.randcol2 = $r(1,5)
n70= %.randnum1 = &c $+ %.randcol1 $+ $iif($r(10,99) < 50,:,|) $+
n71= %.randnum2 = &c $+ %.randcol2 $+ ³
n72= %.bar1 = $iif($r(1,10) > 5,%.randnum1,%.randnum2)
n73= %.bar2 = $iif($r(1,10) < 5,%.randnum2,%.randnum1)
n74= var %k = 1
n75= while ($wordwrap(%k,44,$1-)) {
n76= %wecho.cmnd %wecho.spa %.bar1 $align(44,$ifmatch) %.bar2
n77= inc %k
n78= }
n79=}
n80=who.display3 {
n81= if ($hget($1) == $null) return
n82= %wecho.win = $iif((@* iswm $active) || (=* iswm $active) || ($query($active)) || ($active == Status Window),-s,$active)
n83= %wecho.space = $x(14)
n84= %wecho.cmnd = who.echo %wecho.win
n85= %wecho.name = (&c3WHO&c1/&c3 $+ $1 $+ &c1)
n86= %wecho.line = $str(Ä,$calc(48 - $len($remove(%wecho.name,,&c1,&c3)))) $+ Ä¿
n87= %wecho.cmnd &c1ÚÄ $+ %wecho.name $+ %wecho.line
n88= %wecho.i = 1
n89= while ($hget(%who.targ,%wecho.i)) {
n90= who.display2 $ifmatch
n91= inc %wecho.i
n92= }
n93= %wecho.bttm = &c1ÀÄ $+ $str(Ä,$calc(34 - $len($remove(%wecho.name,,&c3,&c1,&c2)))) $+ %wecho.name $+ ÄÙ
n94= %wecho.cmnd $x($calc(52 - $len($remove(%wecho.bttm,,&c3,&c1,&c2))))) $+ %wecho.bttm
n95= %who.echo = $remtok(%who.echo,%who.targ,44)
n96= unset %who.targ
n97= .timer.who.unset 1 2 unset %wecho.*
n98=}
n99=who.display2 {
n100= %wecho.nick = &c2(&c3 $+ $_align(9,$1) $+ &c2)&c1
n101= %wecho.host = &c2(&c3 $+ $align(32,$2) $+ &c2)&c1
n102= %wecho.serv = &c2(&c3 $+ $align(32,$4) $+ &c2)&c1
n103= %wecho.stat = $6 $+ &c1/&c3 $+ $5
n104= %wecho.stat = &c2(&c3 $+ $replace($_align(9,$remove(%wecho.stat,,&c3,&c1,&c2)),@,&c4@&c3,*,4*&c3) $+ &c2)&c1
n105= if (%wecho.i == 1) %wecho.cmnd &c1ÃÄ $+ %wecho.nick $+ ÄÂÄ $+ $replace(%wecho.host,@,&c4@&c3) $+ &c1Ä´
n106= else %wecho.cmnd &c1ÚÄ $+ %wecho.nick $+ ÄÅÄ $+ $replace(%wecho.host,@,&c4@&c3) $+ &c1Ä´
n107= %wecho.cmnd &c1ÀÄ $+ %wecho.stat $+ ÄÅÄ $+ %wecho.serv $+ &c1Ä´
n108= %wecho.ii = 1
n109= %wecho.quot = $strip($7-)
n110= while ($wordwrap(%wecho.ii,32,%wecho.quot)) {
n111= %wecho.cmnd %wecho.space $+ &c1ÃÄ&c2(&c5 $+ $align(32,$ifmatch) $+ &c2)&c1Ä´
n112= inc %wecho.ii
n113= }
n114= %wecho.z = 1
n115= while ($wordwrap(%wecho.z,32,$3)) {
n116= %wecho.cmnd %wecho.space $+ &c1ÃÄ&c2(&c5 $+ $align(32,$ifmatch) $+ &c2)&c1Ä´
n117= inc %wecho.z
n118= }
n119=}
n120=; eof