mIRC Home    About    Download    Register    News    Help

Print Thread
Read from nicks in room. #123837
27/06/05 10:41 PM
27/06/05 10:41 PM
Joined: Jun 2005
Posts: 44
B
BNX Offline OP
Ameglian cow
BNX  Offline OP
Ameglian cow
B

Joined: Jun 2005
Posts: 44
Is there a way... well I know there is... but how!
To read only the nicks in the room?

for example:
<Person> !random nick
<Bot> Georgebob
<Georgebob> o.o

I have seen this done with another mirc bot, who "hugged" all the people in the room.

Last edited by BNX; 27/06/05 10:43 PM.
Re: Read from nicks in room. #123838
27/06/05 10:50 PM
27/06/05 10:50 PM
Joined: Feb 2005
Posts: 681
Your dreams ;)
M
mIRCManiac Offline
Fjord artisan
mIRCManiac  Offline
Fjord artisan
M

Joined: Feb 2005
Posts: 681
Your dreams ;)
on *:TEXT:!random nick:#:msg # $nick(#,$rand(1,$nick(#,0)))


mIRCManiac
Re: Read from nicks in room. #123839
29/06/05 03:10 AM
29/06/05 03:10 AM
Joined: Jun 2005
Posts: 44
B
BNX Offline OP
Ameglian cow
BNX  Offline OP
Ameglian cow
B

Joined: Jun 2005
Posts: 44
awesome! Thanks a bunch, that was shorter than I expected...

If I wanted to use all the members, would I do..

msg # $nick(#)

Last edited by BNX; 29/06/05 03:12 AM.
Re: Read from nicks in room. #123840
29/06/05 03:27 AM
29/06/05 03:27 AM
Joined: Dec 2002
Posts: 1,245
California, doooood
M
MikeChat Offline
Hoopy frood
MikeChat  Offline
Hoopy frood
M

Joined: Dec 2002
Posts: 1,245
California, doooood
pretty close, /help $snicks

Re: Read from nicks in room. #123841
29/06/05 03:33 AM
29/06/05 03:33 AM
Joined: Mar 2005
Posts: 420
X
xDaeMoN Offline
Fjord artisan
xDaeMoN  Offline
Fjord artisan
X

Joined: Mar 2005
Posts: 420
$snicks would return selected nicks, not ALL nicks. Not unless you selected all of them in the nicklist.


If you have a plastic floor runner over your tiles, then you're one Hella Pinoy!
Re: Read from nicks in room. #123842
29/06/05 03:34 AM
29/06/05 03:34 AM
Joined: Mar 2005
Posts: 420
X
xDaeMoN Offline
Fjord artisan
xDaeMoN  Offline
Fjord artisan
X

Joined: Mar 2005
Posts: 420
Your idea would flood the room if there are a lot of people in the room.


If you have a plastic floor runner over your tiles, then you're one Hella Pinoy!
Re: Read from nicks in room. #123843
29/06/05 03:37 AM
29/06/05 03:37 AM
Joined: Jun 2005
Posts: 44
B
BNX Offline OP
Ameglian cow
BNX  Offline OP
Ameglian cow
B

Joined: Jun 2005
Posts: 44
The server I use is very small, never anymore than 15 people in the channel. But thanks smile

Re: Read from nicks in room. #123844
29/06/05 06:35 AM
29/06/05 06:35 AM
Joined: Dec 2002
Posts: 1,245
California, doooood
M
MikeChat Offline
Hoopy frood
MikeChat  Offline
Hoopy frood
M

Joined: Dec 2002
Posts: 1,245
California, doooood
Quote:

$snicks would return selected nicks, not ALL nicks. Not unless you selected all of them in the nicklist.


yes... Ithought /sline was with it... my bad
Quote:

/sline [-a|r] <#channel> <N|nick>
Selects or deselects lines in a channel nickname listbox. It can select either the Nth nickname in a listbox, or a specified nickname.

If you do not specify any switches, any existing selections in the listbox are cleared. If you specify the -a switch then the specified is selected without affecting the selection states of other lines. If you specify the -r switch then the specified item is deselected.

Re: Read from nicks in room. #123845
29/06/05 11:39 AM
29/06/05 11:39 AM
Joined: Apr 2003
Posts: 701
Leuven, Belgium
K
Kelder Offline
Hoopy frood
Kelder  Offline
Hoopy frood
K

Joined: Apr 2003
Posts: 701
Leuven, Belgium
alias allnicks {
var %i = 1, %n, %chan = $iif($1 ischan,$1,$chan)
while ($nick(%chan,%i)) {
var %n = %n $v1
inc %i
}
if ($isid) return %n
msg %chan %n
}

To just get all nicknames, use $allnicks(#channel) or $allnicks if you're in the correct window/event, to send a message to the channel with only all nicks: /allnicks #channel

You can probably adapt it somewhat to your needs...

Re: Read from nicks in room. #123846
29/06/05 07:21 PM
29/06/05 07:21 PM
Joined: Dec 2002
Posts: 1,245
California, doooood
M
MikeChat Offline
Hoopy frood
MikeChat  Offline
Hoopy frood
M

Joined: Dec 2002
Posts: 1,245
California, doooood
For the bot try
Code:
on *:TEXT:!allnicks*:#:{
  var %i = 1
  while ($nick(#,%i)) {
    if ($nick($chan,%i) != $me) { var %allchan = %allchan $nick(#,%i) }
    inc %i
  }
  msg $chan %allchan
}

It should post all the nicks but the bots