mIRC Home    About    Download    Register    News    Help

Print Thread
#266963 13/03/20 06:52 PM
Joined: Feb 2015
Posts: 138
kap Offline OP
Vogon poet
OP Offline
Vogon poet
Joined: Feb 2015
Posts: 138
1. create c:\newmirc
2. create blank file 'mirc.ini' in c:\newmirc
3. copy mirc.exe (version 7.61) into c:\newmirc
4. copy servers.ini to c:\newmirc
5. run mirc.exe in c:\newmirc
6. place the following code in the remote section of the script editor:

Code
menu status {
  Connect to...
  .Recent networks
  ..$submenu($_rec_netw($1))
  .Popular networks
  ..$submenu($_pop_netw($1))
}
; return popular networks from servers.ini
alias -l _pop_netw {
  if ($istok(begin end,$1,32)) return -
  return $iif($istok($_connected_networks,$readini(servers.ini,networks,$(n $+ $calc($1 - 1),2)),32),$style(3)) $readini(servers.ini,networks,$(n $+ $calc($1 - 1),2)) : server $iif($server,-m) $readini(servers.ini,networks,$(n $+ $calc($1 - 1),2))
}
; return recent successful networks from servers.ini
alias -l _rec_netw {
  if ($istok(begin end,$1,32)) return -
  noop $regex($readini(servers.ini,recent,$(n $+ $calc($1 - 1),2)),/.*SERVER:[^:]+:(\+?\d+)GROUP:([^:]+)/) | var %port $regml(1), %net $regml(2)
  return $iif($istok($_connected_networks,%net,32),$style(3)) %net %port : server $iif($server,-m) %net %port
}
; return list of connected network names, space delimited
alias -l _connected_networks {
  var %s 1, %res
  while ($scon(%s)) { 
    if ($scon(%s).server) var %res $addtok(%res,$scon(%s).network,32)
    inc %s
  }
  return %res
}
; return list of connected server names, space delimited
alias -l _connected_servers {
  var %s 1, %res
  while ($scon(%s)) {
    if ($scon(%s).server) var %res $addtok(%res,$scon(%s).server,32)
    inc %s
  }
  return %res
}


7. connect to a server
8. join a random channel
9. right-click in the status window --> popup appears
10. right-click in the channel window --> popup appears (and should not appear!)

Note: If I add a channel popup definition, it stops the status popup from showing in the channel...
Note2: This is on WIN10 - 1909

Last edited by kap; 13/03/20 07:03 PM.

GNU Terry Pratchett - Looking for a mIRC help channel -> Check #mircscripting @ irc.swiftirc.net
kap #266969 14/03/20 09:11 AM
Joined: Dec 2002
Posts: 5,411
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 5,411
Thanks for your bug report. This is intentional and has been a default behaviour ever since popups were added long ago. If no channel popup menu is found, the status window popup menu is displayed.


Link Copied to Clipboard