mIRC Homepage
Posted By: pouncer loop through all servers and channels - 16/11/07 12:34 AM
anyone have an alias i can use to loop through all server status connections open and then loop through each channel for the server status and echo it?
Posted By: Bekar Re: loop through all servers and channels - 16/11/07 12:42 AM
And echo it?
Code:
alias loopy {
  var %con = $scon(0)
  while (%con) {
    scon %con
    var %cha = $chan(0)
    while (%cha) {
      echo -a :: $server :: $chan(%cha) ::
      dec %cha
    }
    dec %con
  }
}

That's the general idea of what you're wanting.
Posted By: pouncer Re: loop through all servers and channels - 16/11/07 12:46 AM
that is perfect bekar, but can it list in order instead of reversed?
Posted By: Bekar Re: loop through all servers and channels - 16/11/07 01:06 AM
Code:
alias loopy {
  var %con = 1
  while ($scon(%con)) {
    scon %con
    var %cha = 1
    while ($chan(%cha)) {
      echo -a :: $server :: $v1 ::
      inc %cha
    }
    inc %con
  }
}
© mIRC Discussion Forums