mIRC Home    About    Download    Register    News    Help

Print Thread
#140111 22/01/06 12:44 PM
Joined: Jan 2006
Posts: 1
G
Gawker Offline OP
Mostly harmless
OP Offline
Mostly harmless
G
Joined: Jan 2006
Posts: 1
i trying to check on what servers i connected and i made this alias
chckServ {
var %v = 1
while (%v <= $scon(0)) {
return $scon(%v).server
inc %v 1
}
}

i checked it by
//{ if (net.il isin $chckserv) { //echo -a $active lol } }
and it dont work i only get the 1st server in the list
what can b the problem and how can i fix it?

#140112 22/01/06 01:43 PM
Joined: Sep 2005
Posts: 2,881
H
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,881
The return command prevents any further processing of the current event/alias/etc, so when you return the first server it stops listing them.

Try this:

Code:
alias chckserv {
  var %servers
  scid -a $(%servers = %servers $server,)
  return %servers
}


Code:
//if ($istok($chckserv,net.il,32)) { do whatever }


Link Copied to Clipboard