mIRC Home    About    Download    Register    News    Help

Topic Options
#265259 - 24/03/19 01:35 AM Importing favorites
Livesongs Offline
Mostly harmless

Registered: 24/03/19
Posts: 1
Hello I was wondering if there was a way to import multiple channels into the favorite section on mirc im trying to make a auto lurk bot for twitch but dont want to add the channels manually because I have so many

#265271 - 25/03/19 04:12 AM Re: Importing favorites [Re: Livesongs]
maroon Offline
Hoopy frood

Registered: 12/01/04
Posts: 1151
The favorites are in the [chanfolder] section of mirc.ini. I don't recommend writing to it with a script, best to backup mirc.ini to somewhere safe, then paste from elsewhere using notepad. From playing round with it, it looks like each line is formatted where the #channelname is either by itself or followed by several optional fields like:


... where the last 2 fields being 1 are:

1 if join-on-connect, otherwise blank
1 if minimize-on-join, otherwise blank

If the optional fields aren't set, they're blank rather than have a series of commas.

You can browse thru the favorites like:

//hfree -w favorites | hload -m1i favorites $mircini chanfolder

This shows the items being loaded in reverse alphabetical order:

//var %i 1 | while ($hget(favorites,%i).item) { echo -a $v1 $hget(favorites,$v1) | inc %i }

and that's the way they would save to disk:

/hsave -ins favorites favs.txt chanfolder