mIRC Homepage

Can only voice/kick/etc 3 users at a time

Posted By: Sydero

Can only voice/kick/etc 3 users at a time - 22/03/08 12:13 AM

In version v6.31 running on Vista, if I select 10 users and choose voice, kick or something else, it will only voice the first three people and not all of them. Does anyone know how to fix this?

Thanks
Posted By: Bekar

Re: Can only voice/kick/etc 3 users at a time - 22/03/08 12:52 AM

The popup's that come with mIRC will only op/voice etc. the first selected 3.

If you want to be able to do more, then you'll need to do a bit of scripting. At this point, it starts to be called a 'mass' action, which is easy to abuse.

You also have to take in to consideration how many modes you can do in one command, as is limited by the server. See the $modespl identifier, which is filled with the 'MODES' argument on the 005 line.

If you want help writing such a script, let us know.
Posted By: Sydero

Re: Can only voice/kick/etc 3 users at a time - 22/03/08 02:41 AM

Well every other irc client can voice more than 3 at a time... so yes, I'd like to know how to do it please smile
Posted By: argv0

Re: Can only voice/kick/etc 3 users at a time - 22/03/08 03:05 AM

Well, not "much more".. the amount is generally limited by the server and it's usually something like 4 to 6.

Other clients might have scripts in place to loop over the nicknames but you can easily do the same in mIRC with loops.

/help /while
Posted By: Sydero

Re: Can only voice/kick/etc 3 users at a time - 22/03/08 03:44 AM

Quote:
[20:25] * Reyne[OG] sets mode: -vvvv MegaAros MegaVolt Methax moshea
[20:25] * Reyne[OG] sets mode: -vvvv Mrott-VA ochocinco|afk raasaa[NV] Ryan_Reyes
[20:25] * Reyne[OG] sets mode: -vvvv Shaunbing{afk} Sir_Galahad Thor\zzz Timberland
[20:25] * Reyne[OG] sets mode: -vv trepidation|Umbrella Xav|
[20:25] <%Sir_BluJohn> O_O
[20:25] * Reyne[OG] sets mode: +vvvv MegaAros MegaVolt Methax moshea
[20:26] * Reyne[OG] sets mode: +vvvv Mrott-VA ochocinco|afk raasaa[NV] Ryan_Reyes
[20:26] * Reyne[OG] sets mode: +vvvv Shaunbing{afk} Sir_Galahad Thor\zzz Timberland
[20:26] * Reyne[OG] sets mode: +vv trepidation|Umbrella Xav|


That's a log of someone unvoicing and voicing a number of people in two actions, one to devoice all the highlighted and one to voice.
Posted By: Riamus2

Re: Can only voice/kick/etc 3 users at a time - 22/03/08 12:15 PM

As he stated, you *can* do more, but it's limited by the server for how many to do at once. Notice that only 4 were ever done at once.
Posted By: LostShadow

Re: Can only voice/kick/etc 3 users at a time - 22/03/08 07:01 PM

/v /mode $active +v $1

Then type /v <Person to +v>

/v2 /mode $active +vv $1 $2
/v3 /mode $active +vvv $1 $2 $3

Note that, the logs you pasted, a person only +v'd 4 the most at a time.

You have to type //echo -a $modespl to see what the maximum limit. By your logs, I'm gambling that on that network, the maximum limit is 4.

Note that.

/v4 /mode $active +vvvv $1 $2 $3 $4

Is the same as.

/v4 /mode $active +vvvv $1-

*But*

If all the networks you go to are limited to 4, you could just use.

/v /mode $active +vvvv $1-

And /dv /mode $active -vvvv $1-

Then make your own /o and /deop or /op, etc.

These go to aliases.
Posted By: Riamus2

Re: Can only voice/kick/etc 3 users at a time - 23/03/08 12:04 AM

The better method is:

Code:
menu nicklist {
  Voice Selected: massv $chan $snicks
}

alias massv {
  if (!$2) { echo -a ERROR: No nicks selected | return }
  var %in = $replace($2,$chr(44),$chr(32)), %max = $iif($modespl,$v1,4)
  var %c = 1, %t = $numtok(%in,32)
  while (%c <= %t) {
    mode $1 + $+ $str(v,%max) $gettok(%in,%c - $calc(%c + %max),32)
    inc %c %max
  }
}


I'm sure there's an faster way to do that, but that's the general idea that I just quickly put together.

To do it with ops, do the same thing, but using +o instead of +v. Note that this is set up to automatically voice the maximum number per line as the server allows. If for some reason the server never sends the RAW that tells the max, it will default to 4. I'm not sure if that's ever the case, so I threw it in as a safety.
Posted By: Bekar

Re: Can only voice/kick/etc 3 users at a time - 23/03/08 12:37 AM

I'd throw something like this in there:

Code:
menu nicklist {
  Voice selected: mass $chan +v $snicks
  DeVoice selected: mass $chan -v $snicks
}

alias mass {
  if (!$3) { echo -a ERROR: No nicks selected | return }
  var %in = $replace($3-, $chr(44), $chr(32)), %max = $iif($modespl, $v1, 4)
  var %c = 1, %t = $numtok(%in, 32), %ms = $left($2, 1) $+ $str(%max, $right($2, 1))
  while (%c <= %t) {
    mode $1 %ms $gettok(%in, %c - $calc(%c + %max), 32)
    inc %c %max
  }
}

Saves having to repeat code lots *shrug*. Also allows the user to use a comma-separated or a space-separated list (easier for /command type actions).
Posted By: LostShadow

Re: Can only voice/kick/etc 3 users at a time - 23/03/08 01:09 AM

Oh.... so *now* we get into the help of helping with *mass* scripts.

What's so funny though, is that when I make my help of offering a "non-mass" alias, people will instantly jump into helping with *mass* scripts. Which contradicted them not wanting to do it before.

Sigh.
Posted By: starbucks_mafia

Re: Can only voice/kick/etc 3 users at a time - 23/03/08 01:52 AM

Originally Posted By: LostShadow
What's so funny though, is that when I make my help of offering a "non-mass" alias, people will instantly jump into helping with *mass* scripts. Which contradicted them not wanting to do it before.

What are you talking about? Nobody said they wouldn't help with mass scripts. In Bekar's original reply he specifically said:
Originally Posted By: Bekar
If you want help writing such a script, let us know.
Posted By: Riamus2

Re: Can only voice/kick/etc 3 users at a time - 23/03/08 02:12 AM

There is a BIG difference between mass op/voice scripts and mass message scripts. Mass message scripts are often used for spamming. Mass op/voice scripts can only be used by halfops or higher and are therefore handled by people in the channel who control the rules and can do what they want anyhow.
Posted By: Riamus2

Re: Can only voice/kick/etc 3 users at a time - 23/03/08 02:16 AM

Heh, you might as well throw in the menu items for ops since the change allows those to work. And to anyone using this, you can also add in other modes (+/- h, +/- a, etc) if the network supports those modes by just editing the menu as shown below.

Code:
menu nicklist {
  Voice selected: mass $chan +v $snicks
  DeVoice selected: mass $chan -v $snicks
  Op selected: mass $chan +o $snicks
  DeOp selected: mass $chan -o $snicks
}


And the code I posted should have handled both space and comman-separated lists already. Not sure if you meant that it didn't.

The only change I'd suggest is to change the alias to something that isn't quite so common. "mass" could be used by a lot of scripts and could cause a conflict at some point. smile
Posted By: LostShadow

Re: Can only voice/kick/etc 3 users at a time - 23/03/08 03:51 AM

Originally Posted By: starbucks_mafia
What are you talking about? Nobody said they wouldn't help with mass scripts.

But they did mention it could be easy to abuse.

[quote]In Bekar's original reply he specifically said:
Originally Posted By: Bekar
If you want help writing such a script, let us know.

Right, but such a person didn't ask (yet). Bekar was actually re:ing Riamus2, suggestion a better example.
Posted By: LostShadow

Re: Can only voice/kick/etc 3 users at a time - 23/03/08 03:53 AM

Originally Posted By: Riamus2
There is a BIG difference between mass op/voice scripts and mass message scripts.

This is not my argument.

Quote:
Mass message scripts are often used for spamming. Mass op/voice scripts can only be used by halfops or higher and are therefore handled by people in the channel who control the rules and can do what they want anyhow.

Exactly.
Posted By: Bekar

Re: Can only voice/kick/etc 3 users at a time - 23/03/08 08:02 AM

Yup, I did say that they are easy to abuse, simply because they are. I didn't say I wouldn't help if they asked.

I didn't just throw one out there as I'm not fond of them.

These days, with EFNet's CHANOP and other network's channel services etc., using a mass-mode script is pretty pointless. Any well established channel can recover from it. This really makes such a mass command more of a toy than anything else.

In any case, there was some code thrown in here (Riamus2) and I felt I had an easy contribution to give to the group based on his code, which may or may not generate some discussion.

I've written such mass-scripts previously (prior to $modespl and after it's introduction), writing them to the point of stacking multiple commands on the same quoted command (up until the ~ 900 character limit) to make them faster etc., but I don't have any of them any more. I never used them in any case.

Anyway.
Posted By: sparta

Re: Can only voice/kick/etc 3 users at a time - 23/03/08 08:40 AM

I helped "one" with a mass script befor, then i got flamed here, and it's easy to rewrite a mass script from mass voice/op to mass deop/devoice/kick/ban..
© 2022 mIRC Discussion Forums