mIRC Home    About    Download    Register    News    Help

Print Thread
#153095 11/07/06 06:42 AM
Joined: Oct 2003
Posts: 39
Matrixx Offline OP
Ameglian cow
OP Offline
Ameglian cow
Joined: Oct 2003
Posts: 39
I Have this in my remotes at the moment,

on *:JOIN:#mychannel: { /mode $chan +v $nick }

and this is what shows up in the channel.

Matrixx sets mode: +v _45ish

but i would like to change it so it doesn't voice anyone who is +o or +h (fullop or half op)

is there anywhere it can check to see if the user who has joined is either one or the other..


Gary
#153096 11/07/06 08:27 AM
Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
One problem that you have, is that when a person joins a channel, they join as a regular user, that is, to say, no one has voice, half-ops, or ops when they join.

Here's a suggestion, although it's not perfect
Code:
 on @*:join:#:{
.timer 1 3 check.reg $chan $nick
}
alias check.reg {
if $2 isreg $1 {
.mode $1 +v $2
}
}
 

This will delay the voicing of the person that joined for 3 seconds, usually more than enough time for a person/bot/service/server to op or half-op the person that joined.

If you don't want that delay, then you could go with this
Code:
 on @*:join:#: mode $chan +v $nick
on @*:op:#:{
if $opnick isvoice $chan {
.mode $chan -v $opnick
}
}
on @*:serverop:#:{
if $opnick isvoice $chan {
.mode $chan -v $opnick
}
}
on @*:help:#:{
if $hnick isvoice $chan {
.mode $chan -v $hnick
}
}
 


With that, the person will be voiced upon joining, then devoiced if they are granted ops or half-ops in the channel

Please note that, as far as access is concerned, there's nothing that someone who is voiced can do, that a half-op or op can't do.

Personally, I'd go with the first of the two codes if it really makes a difference. I wouldn't recommend lowering the timing of the delay below 3 seconds, as there may be system/internet/server lag that has tio be accounted for.

#153097 11/07/06 05:46 PM
Joined: Oct 2003
Posts: 39
Matrixx Offline OP
Ameglian cow
OP Offline
Ameglian cow
Joined: Oct 2003
Posts: 39
Thanks Very much for that RusselB

I followed your advise and went with the 1st example and worked great..

Thanks once again grin


Gary
#153098 12/07/06 09:45 AM
Joined: Dec 2002
Posts: 1,541
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Dec 2002
Posts: 1,541
Matrixx - just so you know, newer mircs (those released in the last few years) also have the /pvoice command which delay voices people. Type /help pvoice for more info. (I realize you already got an answer that works, Im just showing you another command you could use)


Those who fail history are doomed to repeat it

Link Copied to Clipboard