mIRC Home    About    Download    Register    News    Help

Print Thread
#250065 01/01/15 05:23 PM
Joined: Sep 2014
Posts: 52
Babel fish
OP Offline
Babel fish
Joined: Sep 2014
Posts: 52
I know how to pick a random nick from all present in the channel - $nick(#,$r(1,$nick(#,0))) - But I was wondering if there was a way to exclude certain nicks from being chosen. I am trying to exclude 3 nicks from being chosen when I run my command.

Joined: Jul 2006
Posts: 4,150
W
Hoopy frood
Offline
Hoopy frood
W
Joined: Jul 2006
Posts: 4,150
var %n
while (1) {
var %n $nick(#,$r(1,$nick(#,0)))
if (!$istok(nick1 nick2 nick3,%n,32)) break
}
return %n


#mircscripting @ irc.swiftirc.net == the best mIRC help channel
Wims #250067 01/01/15 06:13 PM
Joined: Sep 2014
Posts: 52
Babel fish
OP Offline
Babel fish
Joined: Sep 2014
Posts: 52
Thank you Wims! laugh

Edit: For some reason the command failed to work until I removed "return %n"

Last edited by paper0rplastic; 01/01/15 06:45 PM.

Link Copied to Clipboard