mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Dec 2006
Posts: 31
J
JohnS Offline OP
Ameglian cow
OP Offline
Ameglian cow
J
Joined: Dec 2006
Posts: 31
ok i have it set up for multiple servers and i use the perform list to do everything. however my annoyance is when the first server gets disconnected and reconnected it also reloads all the other servers again.
my perform is sort of like this:

/server <server1>
/server -m <server2>
/server -m <server3>

so now even if the connections to servers 2 and 3 are fine, server one will get disconnected and reconnected then load up servers 2 and 3 in different windows with my alternate nick.
i want it to like detect if theres already a connection to servers 2 and 3 and if theyre connected then not try to connect again. or is there a way to have them seperate so they all connect on startup of mirc but not start the whole connection process if the first one gets disconnected then reconnects.

Joined: Mar 2004
Posts: 526
Fjord artisan
Offline
Fjord artisan
Joined: Mar 2004
Posts: 526
the variable $scon(0) says how many networks your are connected to.

the values of $scon(1) through $scon(x) contain the network names. You can use this information in a script you call in perform to determine what networks you are connected to and then connect to the one (or ones) that are not connected when one (or more) drops off.


Help others! It makes the world a better place, Makes you feel good, and makes you Healthy!
Joined: Jan 2003
Posts: 1,063
D
Hoopy frood
Offline
Hoopy frood
D
Joined: Jan 2003
Posts: 1,063
I find it better to use the ON START event to do auto-connects when you start mIRC. I also put the code itself in an alias wich I call from the ON START event, so I can always call it again later if I canceled the initial auto-connect:

Code:
on *:start: {
  window -xa "Status Window"
  autoconnect
}
alias autoconnect {
  if ($?!="AutoConnect all: ?") {
    server irc.server1.org -i nick1 nick2
    server -m irc.server2.org -i othernick1 othernick2
    server -m irc.etc.net
  }
}


put something like that in your remotes (ALT+R)


If it ain't broken, don't fix it!
Joined: Dec 2006
Posts: 31
J
JohnS Offline OP
Ameglian cow
OP Offline
Ameglian cow
J
Joined: Dec 2006
Posts: 31
i want something simple not some long drawn out script though. which is why i liked the perform list really.
what id need for each server is:

connection
nick change, alternate
nickserv authentication
channel list to join

but not reconnect to all if the first one drops connection.

Last edited by JohnS; 21/06/08 06:49 AM.
Joined: Oct 2003
Posts: 3,918
A
Hoopy frood
Offline
Hoopy frood
A
Joined: Oct 2003
Posts: 3,918
it's *not* drawn out to use the script editor to connect to multiple servers

Code:
on *:START: {
  server SERVER1.com -j #autojoin,#channels,#here -i NICK ALTNICK
  server -m SERVER2.com -j #autojoin,#channels,#here -i NICK ALTNICK
  server -m SERVER3.com -j #autojoin,#channels,#here -i NICK ALTNICK
  ...
}


then you can put the nickserv auth in perform or an on connect event:

Code:
on *:CONNECT: {
  if ($network == X) msg Nickserv IDENTIFY blah
  if ($network == Y) ...
}


This keeps them all separate from each other and doesn't have any side effects if any connection dies.


- argv[0] on EFnet #mIRC
- "Life is a pointer to an integer without a cast"

Link Copied to Clipboard