|
pUff
|
pUff
|
I'm trying to make a script that does not allow a new mode for #thethirdchannel. so that way when someones sets mode +p it will set -p and set +nt. I tryed this script but it don't seem to work...
on @*:MODE:#thethirdchannel:/mode $chan - $+ $1
Could someone help me fix this script?
|
|
|
|
Joined: Aug 2004
Posts: 7,168
Hoopy frood
|
Hoopy frood
Joined: Aug 2004
Posts: 7,168 |
The easiest way to do this, is to use the mlock command that most chanserv's have. For more help look at /cs help mlock or /cs help set mlock...different chanservs have it in different locations. However, if this option isn't available or for some reason you don't want to do it that way then you might try on @*:mode:#thethirdchannel:{ .mode $chan $+(-,$1,+nt) }
|
|
|
|
pUff
|
pUff
|
For one i'm on undernet in a unregisterd channel. Two this script still does not work. This is what happend.
22:44 * XM-bot (XM@ip68-227-96-40.ok.ok.cox.net) has joined #thethirdchannel 22:44 * pUff` sets mode: +v XM-bot 22:44 * pUff` sets mode: +o XM-bot 22:44 * XM-bot sets mode: +p
The mode still remained...
|
|
|
|
Joined: Aug 2004
Posts: 7,168
Hoopy frood
|
Hoopy frood
Joined: Aug 2004
Posts: 7,168 |
If it's just the +p mode that you're worried about, then this should work on @*:mode:#thethirdchannel:{ .mode $chan -p+nt } For that matter if you wanted to ensure that the only modes set were nt then on @*:mode:#thethirdchannel:{ .mode $chan -imklps+nt }
|
|
|
|
pUff
|
pUff
|
I'm sorry for being picky but i found one little problem with your script. When someone sets +k the script will not set -k
|
|
|
|
Joined: Aug 2004
Posts: 7,168
Hoopy frood
|
Hoopy frood
Joined: Aug 2004
Posts: 7,168 |
the +k mode is for a key, and unless a key is specified, it's irrelevant as to whether that mode is active or not
|
|
|
|
Joined: Feb 2005
Posts: 193
Vogon poet
|
Vogon poet
Joined: Feb 2005
Posts: 193 |
on @*:mode:*:{
if ($nick != $me) {
if (+ isin $1-) mode $comchan($me,1) $replace($1-,+,-)
if (- isin $1-) mode $comchan($me,1) $replace($1-,-,+)
}
} Untested
|
|
|
|
Joined: Nov 2003
Posts: 2,321
Hoopy frood
|
Hoopy frood
Joined: Nov 2003
Posts: 2,321 |
on @!*:mode:#:{ mode $chan $replacex($1-, +, -, -, +) }
|
|
|
|
Joined: Mar 2004
Posts: 540
Fjord artisan
|
Fjord artisan
Joined: Mar 2004
Posts: 540 |
Why use $comchan? Why not just use $chan?
|
|
|
|
Joined: Feb 2005
Posts: 193
Vogon poet
|
Vogon poet
Joined: Feb 2005
Posts: 193 |
This isn't my code. I had it in an old file. I was in a hurry and just pasted it. I never even looked it over. :tongue:
|
|
|
|
pUff
|
pUff
|
I'm sorry but none of your scripts worked for +k
|
|
|
|
Joined: Sep 2004
Posts: 200
Fjord artisan
|
Fjord artisan
Joined: Sep 2004
Posts: 200 |
on @!*:mode:#:{ mode $chan $replacex($1-, +, -, -, +) } change that to: on @!*:mode:#:{ mode $chan $replacex($1-, +, -, -, +) }$1- it will reverse ALL mode changes
|
|
|
|
pUff
|
pUff
|
on @!*:mode:#:{ mode $chan $replacex($1-, +, -, -, +) }$1- That script actualy FORCED the +k to stay... Let alone set -k 
|
|
|
|
DaveC
|
DaveC
|
did u use $replace or $replacex like instructed?
|
|
|
|
Joined: Mar 2004
Posts: 540
Fjord artisan
|
Fjord artisan
Joined: Mar 2004
Posts: 540 |
on @!*:mode:#:{ mode $chan $replacex($1-, +, -, -, +) }$1- That script actualy FORCED the +k to stay... Let alone set -k Shouldnt that be on @!*:mode:#:{ mode $chan $replacex($1-, +, -, -, +) $1- }
|
|
|
|
Joined: Nov 2003
Posts: 2,321
Hoopy frood
|
Hoopy frood
Joined: Nov 2003
Posts: 2,321 |
Mine already replaced all modes.
|
|
|
|
Joined: Apr 2003
Posts: 701
Hoopy frood
|
Hoopy frood
Joined: Apr 2003
Posts: 701 |
I might be way off, but I'd go for:
on @!*:mode:#:{ mode $chan $replacex($1, +, -, -, +) $2- }
|
|
|
|
|