mIRC Home    About    Download    Register    News    Help

Print Thread
List of NICKS? #27095 30/05/03 09:03 PM
Joined: May 2003
Posts: 7
R
rtil Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
R
Joined: May 2003
Posts: 7
I am writing a flood control script - and I am wondering if it is possible, for when you enter a channel for mIRC to grab a list of nicks from the channel and make each one a variable. Any way to do it is fine, thank you.

Re: List of NICKS? #27096 30/05/03 10:04 PM
Joined: Jan 2003
Posts: 3,012
KingTomato Offline
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2003
Posts: 3,012
Code:
on 1:JOIN:#: {
  if ($nick == $me) {
    /set -u0 %i 1
    while ($nick($chan, %i)) {
      /set % [ $+ [ $nick($chan, %i) ] ] [color:red]value_here[/color]
      /inc -u0 %i
    }
  }
}


that will give you %kingtomato value_here, %nimue value_here, %codemastr value_here, etc


-KingTomato
Re: List of NICKS? #27097 30/05/03 10:06 PM
Joined: Jan 2003
Posts: 3,012
KingTomato Offline
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2003
Posts: 3,012


-KingTomato
Re: List of NICKS? #27098 30/05/03 10:10 PM
Joined: Dec 2002
Posts: 699
N
Nimue Offline
Fjord artisan
Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 699
The thig is, when you join a channel, mIRC knows only you are in that channel. You'd have to wait for the names reply to finish (raw 366 RPL_ENDOFNAMES).

Re: List of NICKS? #27099 30/05/03 10:14 PM
Joined: Jan 2003
Posts: 3,012
KingTomato Offline
Hoopy frood
Offline
Hoopy frood
Joined: Jan 2003
Posts: 3,012
Very true..

Code:
raw 366:*: {
  /set -u0 %i 1
  while ($nick($$2, %i)) {
    /set % [ $+ [ $nick($$2, %i) ] ] [color:Red]value_here[/color]
    /inc -u0 %i
  }
}



Thanks once again Nimue >:D

EDIT: BTW--that is the token for channel, $$2, right? Been a while >:\

Last edited by KingTomato; 30/05/03 10:15 PM.

-KingTomato
Re: List of NICKS? #27100 30/05/03 10:15 PM
Joined: Dec 2002
Posts: 699
N
Nimue Offline
Fjord artisan
Offline
Fjord artisan
N
Joined: Dec 2002
Posts: 699
No probs. smile

Re: List of NICKS? #27101 30/05/03 11:20 PM
Joined: May 2003
Posts: 7
R
rtil Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
R
Joined: May 2003
Posts: 7
Well thanks guys, i'm not a mirccode expert, pretty much a n00b, so i'm not quite familiar with every syntax with all the code, but i get used to it. smile