mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: May 2010
Posts: 3
S
SpiLoT Offline OP
Self-satisified door
OP Offline
Self-satisified door
S
Joined: May 2010
Posts: 3
Heya,

I'm thinking if there might be a chance that you guys can implement an option that on exiting mIRC, it'll save all the chans/servers and on opening it back again, it connects to all the chans/servs that I've been connected to rather than connecting to servers one by one.

Kind just like FireFox when you close it with more than a tab.

P.S. I did a little google but I couldn't find scripts/help. Perhaps I was using wrong/not enough keywords, but oh well.
P.P.S If there was already an option like that, then pardon me and please point out where it's. xD

Cheers,
Sean.

Last edited by SpiLoT; 26/05/10 10:14 AM.
Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
If you always want the same networks/channels, it's very easy to script. If you want it to keep track of the last ones used, then it's still pretty easy, but does require keeping track of what's open. If you give specifics of how you want it to work, someone could easily set up a script for you.

Note that I'm not saying the feature suggestion isn't good. It's not a bad idea at all. I'm just answering your questions at the end about whether or not there is a script method.


Invision Support
#Invision on irc.irchighway.net
Joined: Nov 2004
Posts: 842
Hoopy frood
Offline
Hoopy frood
Joined: Nov 2004
Posts: 842
I haven't had time to test this, but you could just use this for now.

Code:
#autocon on
alias -l loc { return $iif($network,$v1,$gettok($server,-2-,46)) }
on *:connect:{
  if (!$istok(%servers,$server,44)) { set %servers $server $+ , $+ %servers }
  if ( % [ $+ [ $loc ] $+ ] .chans ) { join -n $v1 }
}
on *:join:#:{ set % [ $+ [ $loc ] $+ ] .chans $chan $+ , $+ % [ $+ [ $loc ] $+ ] .chans }
on *:start:{ tokenize 44 %servers | server $1 | tokenize 32 $2- | scon -r server -mz $* }
#autocon end

Last edited by Jigsy; 26/05/10 01:50 PM.

What do you do at the end of the world? Are you busy? Will you save us?
Joined: May 2010
Posts: 3
S
SpiLoT Offline OP
Self-satisified door
OP Offline
Self-satisified door
S
Joined: May 2010
Posts: 3
@Riamus2:
I completely agree with you. So now I know that it's easy to script, I have to learn whatever mIRC scripting is, I have no problem in learning and gaining any further experience but though I'd like to see that the option is considered in the next mIRC version since Khaled is trying his best to do it user-friendly as much as possible (he's doing an awesome job).

I think with that option it'll keep IRC users sticked to mIRC much more since I know that the human-being is utter bored by repetitive tasks.

@Jigsy:
I've tried it. It works but it only joins 1 channel only. I tried to see the log in the server's window, here what it says
Quote:
%GTANet.chans No such channel


I've also tried closing mIRC with 2 servers + channels joined in both of them, when I restart, it connects to both servers automatically and only joins 1 channel with an error in servers' windows like the following
Quote:
%<server-name>.chans No such channel


Thanks for doing the script, it gave me a head-up on creating a similar script once I learn mIRC script.

Joined: Oct 2003
Posts: 3,918
A
Hoopy frood
Offline
Hoopy frood
A
Joined: Oct 2003
Posts: 3,918
This is what I use:

Code:
on *:CONNECT:var %c = $readini(channels.ini,channels,$network) | if (%c) join %c
on ME:*:JOIN:#:writeini channels.ini channels $network $addtok($readini(channels.ini,channels,$network),#,44)
on ME:*:PART:#:var %c = $remtok($readini(channels.ini,channels,$network),#,0,44) | $iif(%c,writeini,remini) channels.ini channels $network %c


- argv[0] on EFnet #mIRC
- "Life is a pointer to an integer without a cast"
Joined: May 2010
Posts: 3
S
SpiLoT Offline OP
Self-satisified door
OP Offline
Self-satisified door
S
Joined: May 2010
Posts: 3
Thanks it worked like a charm. laugh

Joined: Jul 2010
Posts: 5
D
Nutrimatic drinks dispenser
Offline
Nutrimatic drinks dispenser
D
Joined: Jul 2010
Posts: 5
it works for me, but it doesnt preserve all the servers. it only autoconnects on startup to the 1st server i had open previously. i have to manually connect to the other severs.

anyone have a fix?

Joined: Oct 2003
Posts: 3,918
A
Hoopy frood
Offline
Hoopy frood
A
Joined: Oct 2003
Posts: 3,918
To add servers to your auto-start simply use

Code:
ON *:START:server irc.server.com | server -m irc.server2.com | ...


- argv[0] on EFnet #mIRC
- "Life is a pointer to an integer without a cast"
Joined: Jul 2010
Posts: 5
D
Nutrimatic drinks dispenser
Offline
Nutrimatic drinks dispenser
D
Joined: Jul 2010
Posts: 5
Originally Posted By: argv0
To add servers to your auto-start simply use

Code:
ON *:START:server irc.server.com | server -m irc.server2.com | ...


thanks a lot, that worked perfectly

sorry i'm a noob


Link Copied to Clipboard