|
Joined: Jan 2005
Posts: 25
Ameglian cow
|
OP
Ameglian cow
Joined: Jan 2005
Posts: 25 |
as the subject says.
just trying to get one to work
|
|
|
|
Joined: Aug 2004
Posts: 7,252
Hoopy frood
|
Hoopy frood
Joined: Aug 2004
Posts: 7,252 |
on @*:text:!voice:#:{
var %a = $nick(#,0,a,v)
while %a > 0 { .mode # +v $nick(#,%a,a,v) | dec %a }
}
on @*:text:!devoice:#:{
var %a = $nick(#,0,v)
while %a > 0 { .mode # -v $nick(#,%a,v) | dec %a }
}
|
|
|
|
Joined: Nov 2004
Posts: 332
Fjord artisan
|
Fjord artisan
Joined: Nov 2004
Posts: 332 |
alias mvoice {
set %n 1
set %tn $nick(#, 0)
while (%n <= %tn) {
set %vnick $nick(#, %n)
m.voice
inc %n
}
}
alias m.voice {
[color:red]if (%vnick != $me) {[/color]
mode $chan +v %vnick
}
[color:red]}[/color]
[color:blue]menu nicklist {
.mass modes
..mass voice {
mvoice
}
}
[/color]
the above creates a popup that will voice everyone in a channel but you; if ud like it to include you, omit the red text. if you'd rahter have the alias and not the popup, omit the blue text. the alias is mvoice so to use type /mvoice or use the poup button in the nicklist. good luck
The Kodokan will move you, one way or another.
|
|
|
|
Joined: Jan 2005
Posts: 25
Ameglian cow
|
OP
Ameglian cow
Joined: Jan 2005
Posts: 25 |
}}menu No such nick/channel - . is unknown mode char to me - voice No such nick/channel - }} No such nick/channel
^ thats what I get when I try to use the script
|
|
|
|
Joined: Sep 2003
Posts: 4,230
Hoopy frood
|
Hoopy frood
Joined: Sep 2003
Posts: 4,230 |
Does your code look just like his?, I assume you decided to put the } on one lime with a command and you also decided to place them hard next to each other as in }}, try putting a space between them, or better yet make your code just like his.
|
|
|
|
Joined: Feb 2005
Posts: 194
Vogon poet
|
Vogon poet
Joined: Feb 2005
Posts: 194 |
You can use this: menu nicklist {
.Mass Voice:set %i $nick(#,0) | :next | if $nick(#,%i) != $me mode # +v $nick(#,%i) %kr | dec %i | if %i > 0 goto next
.Mass De-Voice:set %i $nick(#,0) | :next | if $nick(#,%i) != $me mode # -v $nick(#,%i) %kr | dec %i | if %i > 0 goto next
} Or... something similar to ricky_knuckles's code. I have given you the alias and popup. If you wish to not have the popup, simply delete it, and use /allvoice /alldevoice. menu nicklist {
.Mass Voice:allvoice
.Mass De-Voice:alldevoice
}
alias allvoice {
set %i $nick(#,0)
:next | if $nick(#,%i) != $me mode # +v $nick(#,%i) %kr
dec %i | if %i > 0 goto next
}
alias alldevoice {
set %i $nick(#,0)
:next | if $nick(#,%i) != $me mode # -v $nick(#,%i) %kr
dec %i | if %i > 0 goto next
}
Last edited by alhammer; 06/03/05 05:53 AM.
|
|
|
|
Joined: Nov 2004
Posts: 332
Fjord artisan
|
Fjord artisan
Joined: Nov 2004
Posts: 332 |
i find that directly pasting code from here to the edit box tends to go poorly you can try pasting to a word file or text document etc that has worked for me sometimes or it has been suggested to me that you "quote" the code then everything remains the same in order to facillitate you in this heres an uncolored copy of the code
alias mvoice {
set %n 1
set %tn $nick(#, 0)
while (%n <= %tn) {
set %vnick $nick(#, %n)
m.voice
inc %n
}
}
alias m.voice {
if (%vnick != $me) {
mode $chan +v %vnick
}
}
menu nicklist {
.mass modes
..mass voice {
mvoice
}
}
Last edited by ricky_knuckles; 06/03/05 06:40 AM.
The Kodokan will move you, one way or another.
|
|
|
|
Joined: Mar 2004
Posts: 175
Vogon poet
|
Vogon poet
Joined: Mar 2004
Posts: 175 |
All these mass voice/devoice methods are extremely inefficient and can easily cause excessive flooding. Instead of setting the mode once per user, you can do it all in one string like so: alias mvoice {
tokenize
var %a = 1
While ($Nick(#,%a,a,v)) {
tokenize 32 $1- $v1
inc %a
}
While ($0) {
raw -q mode # $+(+,$Str(v,$0)) $($+($,1-,$Modespl),2)
tokenize 32 $($+($,$Calc($Modespl + 1),-),2)
}
}
alias mdevoice {
tokenize
var %a = 1
While ($Nick(#,%a,v)) {
tokenize 32 $1- $v1
inc %a
}
While ($0) {
raw -q mode # $+(-,$Str(v,$0)) $($+($,1-,$Modespl),2)
tokenize 32 $($+($,$Calc($Modespl + 1),-),2)
}
} Syntax for mass voice: /mvoice Syntax for mass devoice: /mdevoice
- Relinsquish
|
|
|
|
Joined: Jan 2005
Posts: 25
Ameglian cow
|
OP
Ameglian cow
Joined: Jan 2005
Posts: 25 |
what would I do if I wanted it to exclude ops?
I am using Relinsquish's script
|
|
|
|
Joined: Aug 2003
Posts: 1,831
Hoopy frood
|
Hoopy frood
Joined: Aug 2003
Posts: 1,831 |
Change While ($Nick(#,%a,a,v)) { to
|
|
|
|
|