|
Joined: Jan 2007
Posts: 280
Fjord artisan
|
OP
Fjord artisan
Joined: Jan 2007
Posts: 280 |
When somebody does mode +q on you: * $nick sets mode +q <the nick with owner> But wich code is it? $qnick? $ownernick? Doesn't work.
ON ^1:OWNER:#:{
echo $chan 10€12 $nick 11(10 $+ $address $+ 11)12 zet mode $1 op $qnick 12€
.halt
}
Squee whenever a squee squee's. Squee whenever a squee does not squee.
|
|
|
|
Joined: Oct 2004
Posts: 8,330
Hoopy frood
|
Hoopy frood
Joined: Oct 2004
Posts: 8,330 |
Keep in mind that on OWNER only works on specific networks (IRCD, I believe). As for what you'd use, I don't know because I don't use a network that has owner status.
Invision Support #Invision on irc.irchighway.net
|
|
|
|
Joined: Jan 2007
Posts: 280
Fjord artisan
|
OP
Fjord artisan
Joined: Jan 2007
Posts: 280 |
Erm, but when i use:
ON ^1:MODE:#:{
echo $chan 10€12 $nick 11(10 $+ $address $+ 11)12 zet mode $1 aan/uit 5€
.halt
}
It does not Owner. Only +m, +n, +s, that stuff.
@ = S.O.P, A.O.P and Owner.
% = H.O.P.
+ = V.O.P
(That we use)
Squee whenever a squee squee's. Squee whenever a squee does not squee.
|
|
|
|
Joined: Jan 2007
Posts: 280
Fjord artisan
|
OP
Fjord artisan
Joined: Jan 2007
Posts: 280 |
Nvm, it was $opnick
but thanks!
Squee whenever a squee squee's. Squee whenever a squee does not squee.
|
|
|
|
Joined: Aug 2004
Posts: 7,252
Hoopy frood
|
Hoopy frood
Joined: Aug 2004
Posts: 7,252 |
@ is anyone with Ops status (/mode #channel +o nick) Owner/Deowner is only recognized properly on IRCX servers. The ON MODE event is for Channel modes, which this is not. Here's a suggestion for you to try. Please note that I have used ~ for the character that represents the owner mode, change if necessary. on ^*:rawmode:#:{
if q isin $2 {
var %a = 2, %b = $len($2)
while %a <= %b {
if $mid($2,%a,1) == q {
set %opnicks $addtok(%opnicks,$gettok($3-,$calc(%a - 1),32),32)
}
inc %a
}
.msg $chan $nick ( $+ $address $+ ) set mode +q for %opnicks
}
haltdef
}
You had the right idea regarding ON MODE, just not the right event.
|
|
|
|
Joined: Mar 2007
Posts: 38
Ameglian cow
|
Ameglian cow
Joined: Mar 2007
Posts: 38 |
@ is anyone with Ops status (/mode #channel +o nick) Owner/Deowner is only recognized properly on IRCX servers. The ON MODE event is for Channel modes, which this is not. Here's a suggestion for you to try. Please note that I have used ~ for the character that represents the owner mode, change if necessary. on ^*:rawmode:#:{
if q isin $2 {
var %a = 2, %b = $len($2)
while %a <= %b {
if $mid($2,%a,1) == q {
set %opnicks $addtok(%opnicks,$gettok($3-,$calc(%a - 1),32),32)
}
inc %a
}
.msg $chan $nick ( $+ $address $+ ) set mode +q for %opnicks
}
haltdef
}
You had the right idea regarding ON MODE, just not the right event. Nice works but you ignore the most important: if ($left($1,1) == +)  (If only set + modes) Or: if (- isin $1) { $remove($1,-,modes) } And doesn't work properly if it has +i or +s on the middle, eg: ***You sets mode: +qqbiq Reinox HuMoR @devnull.org Peter You need exclude ($remove) the modes that they doesn't use parameters. Only a suggestion  Cya!.-
"if ($me ison $forum) { say Hello! }"
|
|
|
|
Joined: Aug 2004
Posts: 7,252
Hoopy frood
|
Hoopy frood
Joined: Aug 2004
Posts: 7,252 |
Well, considering the fact that the + or - at the beginning of that section would also be in $2, your suggestion (which uses $1) wouldn't work either.
I said it was a suggestion, not a guaranteed solution.
Also, my code does take into account the non q modes that might be set, since I check the position in $2 for the q mode, and add the name that matches the equivalent position..
|
|
|
|
Joined: Mar 2007
Posts: 38
Ameglian cow
|
Ameglian cow
Joined: Mar 2007
Posts: 38 |
Well, considering the fact that the + or - at the beginning of that section would also be in $2, your suggestion (which uses $1) wouldn't work either.
I said it was a suggestion, not a guaranteed solution.
Also, my code does take into account the non q modes that might be set, since I check the position in $2 for the q mode, and add the name that matches the equivalent position.. Yes yes! And works fine. I just say a few possible bugs to considerate... Like I said, nice work! Cya!.- EDIT: If + and - is in modes all are in $1, I think...
Last edited by HuMoR; 25/03/07 07:22 PM.
"if ($me ison $forum) { say Hello! }"
|
|
|
|
|