script help
#163296
28/10/06 03:48 PM
|
Joined: Aug 2006
Posts: 469
Garou
OP
Fjord artisan
|
OP
Fjord artisan
Joined: Aug 2006
Posts: 469 |
on @*:op:#chat:{ if ( %opnick == off ) || ( %opnick == $null ) || ($nick isop #chat) || ($read($scriptdir $+ exempts.op,nw,$opnick)) { return } if (!$read($scriptdir $+ guardian.op,nw,$opnick)) { mode $chan -o $opnick } } on *:nick:{ if ( %opnick == off ) || ( %opnick == $null ) || ($nick isop #chat) { return } if ($read($scriptdir $+ exempts.op,nw,$newnick)) { return } var %i = 1 while ($comchan($newnick,%i)) { if ($me isop $v1) && ($newnick isop $v2) && (!$read($scriptdir $+ guardian.op,nw,$v1)) { mode $comchan($newnick,%i) -o $newnick } inc %i } }
Can I also add full ban with a kick msg on deop?
Last edited by Garou; 28/10/06 03:50 PM.
|
|
|
Re: script help
#163297
28/10/06 04:03 PM
|
Joined: Jan 2003
Posts: 3,012
KingTomato
Hoopy frood
|
Hoopy frood
Joined: Jan 2003
Posts: 3,012 |
I'm not sure I understand what you want to happen, but here is one way to take your request:
on @*:op:#chat:{
if ( %opnick == off ) || ( %opnick == $null ) || ($nick isop #chat) || ($read($scriptdir $+ exempts.op,nw,$opnick)) { return }
if (!$read($scriptdir $+ guardian.op,nw,$opnick)) {
;mode $chan -o $opnick
[color:red]mode $chan -o+b $nick $wildsite
kick $chan $nick You have been kicked for unauthorized op[/color]
}
}
on *:nick:{
if ( %opnick == off ) || ( %opnick == $null ) || ($nick isop #chat) { return }
if ($read($scriptdir $+ exempts.op,nw,$newnick)) { return }
var %i = 1
while ($comchan($newnick,%i)) {
if ($me isop $v1) && ($newnick isop $v2) && (!$read($scriptdir $+ guardian.op,nw,$v1)) {
;mode $comchan($newnick,%i) -o $newnick
[color:red]mode $comchan($newnick,%i) -o+b $newnick $wildsite
kick $comchan($newnick,%i) $nick You have been kicked for unauthorized op[/color]
}
inc %i
}
}
I commented out your previous line just incase, and added two more. If you meant to ban when you deop them, this is your solution. If you want a ban on deop (as in the on DEOP event) then I'd have to rewrite this solution.
-KingTomato
|
|
|
Re: script help
#163298
28/10/06 04:06 PM
|
Joined: Aug 2006
Posts: 469
Garou
OP
Fjord artisan
|
OP
Fjord artisan
Joined: Aug 2006
Posts: 469 |
This is perfect thx KingTomato.
|
|
|
Re: script help
#163299
28/10/06 04:24 PM
|
Joined: Aug 2006
Posts: 469
Garou
OP
Fjord artisan
|
OP
Fjord artisan
Joined: Aug 2006
Posts: 469 |
This kick msg didnt work?
|
|
|
Re: script help
#163300
29/10/06 12:00 AM
|
Joined: Aug 2006
Posts: 469
Garou
OP
Fjord artisan
|
OP
Fjord artisan
Joined: Aug 2006
Posts: 469 |
The first part of the code red does not ban and the kick msg does not work. The second part does work but again no kick msg.
Can anyone check what the error is?
|
|
|
Re: script help
#163301
29/10/06 08:38 PM
|
Joined: Jan 2003
Posts: 3,012
KingTomato
Hoopy frood
|
Hoopy frood
Joined: Jan 2003
Posts: 3,012 |
I'm sorry, I goofed on the identifiers.
on @*:op:#chat:{
if ( %opnick == off ) || ( %opnick == $null ) || ($nick isop #chat) || ($read($scriptdir $+ exempts.op,nw,$opnick)) { return }
if (!$read($scriptdir $+ guardian.op,nw,$opnick)) {
;mode $chan -o $opnick
mode $chan -o+b $opnick $wildsite
kick $chan $opnick You have been kicked for unauthorized op
}
}
on *:nick:{
if ( %opnick == off ) || ( %opnick == $null ) || ($nick isop #chat) { return }
if ($read($scriptdir $+ exempts.op,nw,$newnick)) { return }
var %i = 1
while ($comchan($newnick,%i)) {
if ($me isop $v1) && ($newnick isop $v2) && (!$read($scriptdir $+ guardian.op,nw,$v1)) {
;mode $comchan($newnick,%i) -o $newnick
mode $comchan($newnick,%i) -o+b $newnick $wildsite
kick $comchan($newnick,%i) $newnick You have been kicked for unauthorized op
}
inc %i
}
}
-KingTomato
|
|
|
Re: script help
#163302
30/10/06 01:54 AM
|
Joined: Aug 2006
Posts: 469
Garou
OP
Fjord artisan
|
OP
Fjord artisan
Joined: Aug 2006
Posts: 469 |
|
|
|
Re: script help
#163303
30/10/06 04:22 PM
|
Joined: Aug 2006
Posts: 469
Garou
OP
Fjord artisan
|
OP
Fjord artisan
Joined: Aug 2006
Posts: 469 |
on @*:op:#chat:{ if ( %opnick == off ) || ( %opnick == $null ) || ($nick isop #chat) { return } if (!$read($scriptdir $+ guardian.op,nw,$opnick)) { ;mode $chan -o $opnick mode $chan -o+b $opnick $wildsite kick $chan $opnick 14Your nick does not have op access on this channel } }
on *:nick:{ if ( %opnick == off ) || ( %opnick == $null ) || ($nick isop #chat) { return } if ($read($scriptdir $+ guardian.op,nw,$opnick)) { return } var %i = 1 while ($comchan($newnick,%i)) { if ($me isop $v1) && ($newnick isop $v2) && (!$read($scriptdir $+ guardian.op,nw,$v1)) { ;mode $comchan($newnick,%i) -o $newnick mode $comchan($newnick,%i) -o+b $newnick $wildsite kick $comchan($newnick,%i) $newnick 14Your nick does not have op access on this channel } inc %i } }
[11:10] * Mode (ChanServ:#chat +o _a`hay) [11:10] * Mode (Linuxx:#chat -o+b _a`hay *!*@dal.net) [11:10] * _a`hay was kicked by Me (Your nick does not have op access on this channel
On op it will deop but bans dalnet instead of the user any ideal why?
Last edited by Garou; 30/10/06 04:39 PM.
|
|
|
Re: script help
#163304
01/11/06 05:07 AM
|
Joined: Jan 2003
Posts: 3,012
KingTomato
Hoopy frood
|
Hoopy frood
Joined: Jan 2003
Posts: 3,012 |
Yea, I used $wildsite to ban the user not knowing you're using DAL net. DAL net uses a bogus mask in an effort to keep everyone anonymous. Try replacing $wildsite with this: $address
To further specify a mask, fool around with $address(name,mask) where name is the name of the person, and mask is a numeric value such as 1, 2, 3, etc. Find ne that works using something like: //echo -a $address($me,mask)
Just keep changing mask until you find one you like. Then put this code in your script but use $opnick and $newnick instead of $me.
-KingTomato
|
|
|
Re: script help
#163305
01/11/06 01:24 PM
|
Joined: Jun 2006
Posts: 508
deegee
Fjord artisan
|
Fjord artisan
Joined: Jun 2006
Posts: 508 |
[11:10] * Mode (ChanServ:#chat +o _a`hay) [11:10] * Mode (Linuxx:#chat -o+b _a`hay *!*@dal.net) [11:10] * _a`hay was kicked by Me (Your nick does not have op access on this channel ... On op it will deop but bans dalnet instead of the user any ideal why?
ChanServ opped _a`hay The ban mask matches ChanServ!service@dal.net. If you don't want the user opped, remove their access from ChanServ.
|
|
|
Re: script help
#163306
01/11/06 10:33 PM
|
Joined: Aug 2006
Posts: 469
Garou
OP
Fjord artisan
|
OP
Fjord artisan
Joined: Aug 2006
Posts: 469 |
Ya all I did was to add var %i = 1 and I removed $wildsite and its working now :P
if (!$read($scriptdir $+ guardian.op,nw,$opnick)) { var %i = 1 ;mode $chan -o $opnick mode $chan -o+b $opnick
|
|
|
|
|