mIRC Home    About    Download    Register    News    Help

Print Thread
#151626 20/06/06 01:25 AM
Joined: Jun 2006
Posts: 10
Pikka bird
OP Offline
Pikka bird
Joined: Jun 2006
Posts: 10
My friend asked me if there was a way to part a channel automatically when a certain user goes in there, I didnt know the answer to that so I came to you guys, is there a way to part a channel automatically when a certain user goes in there? If there is please let me. Help is appreciated. Thanks.


#151627 20/06/06 01:28 AM
Joined: Apr 2006
Posts: 400
K
Fjord artisan
Offline
Fjord artisan
K
Joined: Apr 2006
Posts: 400
yea, easy, here:
Code:
on *:JOIN:#: {
  if ($nick == nickhere) {
    part #
  }
}


-Kurdish_Assass1n
#151628 20/06/06 03:25 AM
Joined: Dec 2002
Posts: 1,245
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Dec 2002
Posts: 1,245
Quote:

Code:
on *:JOIN:#: {
  if ($nick == nickhere) {
    part $chan
  }
}


just need to use $chan instead of # in a remote unless you specify the channel name (#mIRC)

#151629 20/06/06 03:32 AM
Joined: Apr 2006
Posts: 400
K
Fjord artisan
Offline
Fjord artisan
K
Joined: Apr 2006
Posts: 400
lol MikeChat, I swear, i ALWAYS use $chan instead of #, I just thought that they might have thought something stupid about me, lol, idk why, but, i did. >:P


-Kurdish_Assass1n
#151630 20/06/06 05:39 AM
Joined: Aug 2005
Posts: 1,052
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Aug 2005
Posts: 1,052
Quote:
Quote:

Code:
on *:JOIN:#: {
  if ($nick == nickhere) {
    part $chan
  }
}


just need to use $chan instead of # in a remote unless you specify the channel name (#mIRC)


??

Actually # works just has fine has $chan

//echo -a #

same results as

//echo -a $chan


Code:
if $reality > $fiction { set %sanity Sane }
Else { echo -a *voices* }
#151631 20/06/06 09:45 AM
Joined: Dec 2002
Posts: 1,245
M
Hoopy frood
Offline
Hoopy frood
M
Joined: Dec 2002
Posts: 1,245
I stand corrected in this case

I do not recall # ever working in remote events

#151632 20/06/06 10:15 AM
Joined: Dec 2002
Posts: 1,541
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Dec 2002
Posts: 1,541
yeah, it's been working for a while now. For as long as I can remember it's always worked


Those who fail history are doomed to repeat it
#151633 23/06/06 08:19 PM
Joined: Jun 2006
Posts: 10
Pikka bird
OP Offline
Pikka bird
Joined: Jun 2006
Posts: 10
Thanks for the help guys, one other thing, if he wanted to add various nicks instead of just one, how would he do it? Would he just add a comma next to the previous nick? ex: nick1,nick2? Oh, I kinda used this script myself and was wondering if this script would also work if it parted me automatically if a user was already on the channel I was joining?


#151634 23/06/06 10:19 PM
Joined: Dec 2002
Posts: 1,541
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Dec 2002
Posts: 1,541
Code:
on *:JOIN:#: {
  if (($nick == nick1) || ($nick == nick2) || ($nick == nick3)) { part # }
}


or:

Code:
on *:JOIN:#: {
  if ($nick isin %nick) { part # }
}


obviously you'd need to fill %nick with the nicknames, but you get the point


Those who fail history are doomed to repeat it

Link Copied to Clipboard