mIRC Home    About    Download    Register    News    Help

Print Thread
help #140111
22/01/06 12:44 PM
22/01/06 12:44 PM
Joined: Jan 2006
Posts: 1
G
Gawker Offline OP
Mostly harmless
Gawker  Offline OP
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?

Re: help #140112
22/01/06 01:43 PM
22/01/06 01:43 PM
Joined: Sep 2005
Posts: 2,876
H
hixxy Offline
Hoopy frood
hixxy  Offline
Hoopy frood
H

Joined: Sep 2005
Posts: 2,876
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 }