mIRC Home    About    Download    Register    News    Help

Print Thread
A Way To Timeout All? #254333 03/08/15 10:59 PM
Joined: Jul 2014
Posts: 48
A
AeonPsych Offline OP
Ameglian cow
OP Offline
Ameglian cow
A
Joined: Jul 2014
Posts: 48
Hello,
is there a way to timeout everyone in the current chat? I know you can do /timeout $nick but I am asking if there is a way to do anyone/everyone currently in chat at whatever time the command would be triggered.

Or is there a way to pick a random $nick to timeout from a current list of users?

Re: A Way To Timeout All? [Re: AeonPsych] #254339 04/08/15 08:56 AM
Joined: Dec 2013
Posts: 779
N
Nillen Offline
Hoopy frood
Offline
Hoopy frood
N
Joined: Dec 2013
Posts: 779
$nick(#,0) will return all nicks in the channel.
This is all the information you need to know to make a script to timeout all / random.

Assuming you want a remote text event, here's a randomp picker for you.
Code:
on *:text:!random:#: { 
var %nicks $nick(#,0)
msg # There are %nicks users in this channel right now.
var %rng $rand(1,%nicks)
var %nick $nick(#,%rng)
msg # The user I randomly selected is %nick $+ .
}


Let me know if you need further explanations. Try to use the help files before asking for help though. Here are some useful reads.

/help variables
/help on text
/help if then else
/help <insert random identifier here>


Nillens @ irc.twitch.tv
Nillen @ irc.rizon.net