mIRC Home    About    Download    Register    News    Help

Print Thread
#43628 22/08/03 09:08 PM
Joined: Aug 2003
Posts: 73
D
Babel fish
OP Offline
Babel fish
D
Joined: Aug 2003
Posts: 73
Can any1 give me a command where i can save my joinings or add them sum where? so then i dont have to keep going on join then typing wot chan i want to go in

Thx


IRC (Idiots Relay Chat) :tongue:

{]TDN[}Deadly-Sin
#43629 22/08/03 09:12 PM
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Umm, use
Code:
on *:JOIN:[b]#[/b]: { 
  if ($chan == #Channel) {
  }
}

#43630 22/08/03 09:24 PM
Joined: Aug 2003
Posts: 73
D
Babel fish
OP Offline
Babel fish
D
Joined: Aug 2003
Posts: 73
thx put how would i now if they r saved and were can i get em from


IRC (Idiots Relay Chat) :tongue:

{]TDN[}Deadly-Sin
#43631 22/08/03 09:25 PM
Joined: May 2003
Posts: 2,265
P
Hoopy frood
Offline
Hoopy frood
P
Joined: May 2003
Posts: 2,265
on *:JOIN:#:{
if (!$read(mychannels.txt,w,$+(*,$server,-,$chan,*)) {
write mychannels.txt $server $+ - $+ $chan
}
}
alias joinchans {
var %i 1
while (%i <= $lines(mychannels.txt)) {
.echo -q $iif(!$window($+(*,$gettok($read(mychannels.txt,%i),1,45),1),*),server -m $gettok($read(mychannels.txt,%i),1,45) -j $gettok($read(mychannels.txt,%i),2,45),join $gettok($read(mychannels.txt,%i),2,45))
inc %i
}
}
this will save every channel on every server you join to mychannels.txt then just type: /joinchans to join them smile

Last edited by pheonix; 22/08/03 09:27 PM.

new username: tidy_trax
#43632 22/08/03 09:26 PM
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
That wouldn't be saved, that is just so you don't have to specify a channel..
Try
Code:
on 1:JOIN:#: {
if ($nick == $me) {
write Channel.txt $chan
}
}


#43633 23/08/03 03:02 AM
Joined: Aug 2003
Posts: 73
C
Babel fish
Offline
Babel fish
C
Joined: Aug 2003
Posts: 73
Try this:

on 1:JOIN:#: {
if ($nick == $me) {
var %a 1
while ($readini(channels.ini,Chan-List,%a) != $null) && ($readini(channels.ini,Chan-List,%a) != #) {
inc %a 1
}
writeini channels.ini Chan-List %a #
}
}
alias joinmychans {
var %a 1
while ($readini(channels.ini,Chan-List,%a) != $null) {
join $readini(channels.ini,Chan-List,%a)
inc %a 1
}
}


The blue monkey is out of its barrel...
#43634 23/08/03 03:45 AM
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Why would I want to try that?

#43635 23/08/03 02:32 PM
Joined: Dec 2002
Posts: 124
B
Vogon poet
Offline
Vogon poet
B
Joined: Dec 2002
Posts: 124
yet another totally useless code example by msn chatter pheonix smile

#43636 23/08/03 02:41 PM
Joined: May 2003
Posts: 2,265
P
Hoopy frood
Offline
Hoopy frood
P
Joined: May 2003
Posts: 2,265
* pheonix has been specifically told by tjerk to ignore ignorant lying people like you :tongue:


new username: tidy_trax
#43637 23/08/03 02:43 PM
Joined: Dec 2002
Posts: 2,985
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 2,985
this will save every channel on every server you join to mychannels.txt then just type: /joinchans to join them

Yeah, and flood the hell out of the server too in most cases, assuming that the script works.

#43638 23/08/03 02:44 PM
Joined: May 2003
Posts: 2,265
P
Hoopy frood
Offline
Hoopy frood
P
Joined: May 2003
Posts: 2,265
how will that flood?, it checks the windows you have open to see if that server is already open, if not it opens it, then joins each channel on each server.......


new username: tidy_trax
#43639 23/08/03 02:46 PM
Joined: Dec 2002
Posts: 2,985
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 2,985
And how many channels can you mass-join in the fashion you describe without getting killed? Not many.

#43640 23/08/03 02:47 PM
Joined: May 2003
Posts: 2,265
P
Hoopy frood
Offline
Hoopy frood
P
Joined: May 2003
Posts: 2,265
ah yeah, got ya, o well its whats he asked for....


new username: tidy_trax
#43641 23/08/03 03:44 PM
Joined: Dec 2002
Posts: 124
B
Vogon poet
Offline
Vogon poet
B
Joined: Dec 2002
Posts: 124
i'm a man of few words..

#43642 23/08/03 03:44 PM
Joined: Dec 2002
Posts: 2,985
Hoopy frood
Offline
Hoopy frood
Joined: Dec 2002
Posts: 2,985
No-one has yet bothered to establish whether the user is looking to save favourite rooms or different rooms each time he uses IRC. If he wants a given set of rooms "save[d] somewhere" then he should use mIRC's built in favourite channels dialogue or the Perform function:

/join #Room1,#Room2,#Room3,#Room4,#Room5

That is one command which sends a total of six commands instead of ten to the server, resulting in a far less chance of being disconnected. (1 x JOIN and 5 x MODE)

If the user wants to save a different set of rooms each time then he'd then use a script and one that definitely does not contain a loop since a loop just increases what you are sending. If you'd have tested what you typed here then you'd have got cut off after joining three or four rooms.
Code:
#Joinall on
ON ME:*:JOIN:#: {
  if (# $+ $chr(44) !isin $read($server $+ .mrc)) {
    write -ci $server $+ .mrc $read($server $+ .mrc) $+ # $+ ,
  }
}
ON ME:*:PART:#: {
  write -ci $server $+ .mrc $remove($read($server $+ .mrc),# $+ $chr(44))
}
ON *:CONNECT: {
  joinall
}
alias joinall {
  if ($read($server $+ .mrc) != $null) {
    join $read($server $+ .mrc)
  }
}
#Joinall End
This is probably not perfect but it does what the user may want and won't flood him off unless he's planning on joining a fairly substantial amount of rooms. When he parts one before leaving the relevant server, that room is removed from 'memory' and is not rejoined when he logs in next. One thing to remember out of all this though is that if he has "Rejoin rooms on reconnect" enabled then it's going to work along-side any script so it would need to be turned off. /enable #joinall to turn on and /disable #joinall to turn off.

Lastly this is tested on two networks and is fully functional.

One possible modification is to change $server to $network though I am not sure whether all IRCd's support $network or not.


Link Copied to Clipboard