mIRC Homepage
Posted By: Shamrock Auto connect and join channels - 06/09/18 10:25 AM
I've been using a script to auto connect and join:

Code:
on *:START:{
  server irc.somename.net -j #chat
  server ircnet.org -j #blah

}


I want to add another channel to one of the servers, so it joins 2 channels on one of the servers with the same nick. I can't seem to get anything to work. It either just joins one of the channels or joins the second one with another nick.

Anyone help out? Thanks.
Posted By: ArThuR Re: Auto connect and join channels - 06/09/18 10:39 AM
cause you use only server command, for joining another server you should use this command => /server -m YourServer

So It's Mean you should change your codes to:

Code:
 on *:START:{
  server irc.somename.net -j #chat
  server -m ircnet.org -j #blah
} 
Posted By: Raccoon Re: Auto connect and join channels - 07/09/18 02:04 AM
ArThuR does address the glaring problem with your script, so that you can now connect to two different servers at the same time. But in the off chance you also wanted to join a second or third channel on either of those two servers, just separate the channel names with a comma.

Code:
server    SavedGroup  -j #mirc,#irchelp,#chat
server -m irc.foo.bar -j #politics,#computers

If you want different nicknames on each server, include the -i switch.

Code:
server    SavedGroup  -j #mirc,#irchelp,#chat -i Rob Rob- robert@noemail My Name is Robert
server -m irc.foo.bar -j #politics,#computers -i Bob Bob` bob@noemail My Name is Bobert

If you save your servers into mIRC's server list, grouping them by network name, you can also store additional settings like NickServ login password. In the above examples, SavedGroup references a saved server group.

You currently cannot store a chosen nickname for a server in mIRC's saved servers, so that's where the -i switch comes in handy above.
-i $mnick $anick $email $fullname
Posted By: Shamrock Re: Auto connect and join channels - 07/09/18 09:55 AM
Thanks guys. I am using the -m to join more that one server - forgot to type it above.

I see now why it wasn't connecting to more than one channel, I was putting comma space ", " between each channel name.

Working perfect now smile
Posted By: Protopia Re: Auto connect and join channels - 08/09/18 09:29 AM
I have a generic autoconnect script which looks at your favourites for channels which are marked as autojoin, and makes an automatic connection to the server so you can autojoin.

Start mirc - and it connects to all the servers and joins all the channels.

If you would like a copy, please PM me with your email address.
Posted By: Memebox Re: Auto connect and join channels - 26/10/19 11:52 PM
your account is set to not accept PM's, but I'm interested in that script.
Posted By: thomaz Re: Auto connect and join channels - 03/12/19 06:08 PM
How do i connect to multiple channels with key?

Code
on *:start: {
  server efnet.port80.se:6667 -j #chan1 key1,#chan2 key2
}

doesnt work. it only joins 1st channel+key
Posted By: kap Re: Auto connect and join channels - 03/12/19 06:25 PM
According to https://en.wikichip.org/wiki/mirc/commands/server this should work:

Code
on *:start: {
  server efnet.port80.se:6667 -j #chan,#chan2 key1,key2
}


Note: Use * to specify no key is needed for that channel.
Posted By: thomaz Re: Auto connect and join channels - 03/12/19 06:56 PM
thx a lot, works now. smile
Posted By: TimeRider Re: Auto connect and join channels - 03/12/19 07:23 PM
Okay, I have this for more networks. If you want auto nickserv and oper password to be automatic, this works well!

on *:CONNECT:{
if ($network == Network1) {
nickserv identify password
oper username password
join #chan1,#chan2,#chan3
}

elseif ($network == Network2) {
nickserv identify ...
join #chan,#chan2,#chan3,...
}
;and so on
}
© mIRC Discussion Forums