mIRC Homepage
Posted By: BORR Popups - 31/03/03 03:21 PM
Ok, I have this popup:



Control
.Op - $$snicks:{ mode $chan +ooooooooo $$1 $2 $3 $4 $5 $6 $7 $8 $9 }
.Deop - $$snicks:{ mode $chan -ooooooooo $$1 $2 $3 $4 $5 $6 $7 $8 $9 }
.Voice - $$snicks:{ mode $chan +vvvvvvvvv $$1 $2 $3 $4 $5 $6 $7 $8 $9 }
.Devoice - $$snicks:{ mode $chan -vvvvvvvvv $$1 $2 $3 $4 $5 $6 $7 $8 $9 }
.Kick:/kick $chan $1
.Kick (reason):/kick $chan $1 $$?="Reason:"
.Ban:/mode $chan +b $address($1,3)
.Kick-Ban:/mode $chan +b $address($1,3) | /kick $chan $1



But I only want it 2 B there when my access level in that channel is 5 (5 = aop). How do I do this?
Posted By: KingTomato Re: Popups - 31/03/03 03:55 PM
The best I can do you is if you are an op...


Code:
Control
.$iif($me isop $active, Op - $$snicks):{ mode $chan +ooooooooo $$1 $2 $3 $4 $5 $6 $7 $8 $9 }
.$iif($me isop $active, Deop - $$snicks):{ mode $chan -ooooooooo $$1 $2 $3 $4 $5 $6 $7 $8 $9 }
.$iif($me isop $active, Voice - $$snicks):{ mode $chan +vvvvvvvvv $$1 $2 $3 $4 $5 $6 $7 $8 $9 }
.$iif($me isop $active, Devoice - $$snicks):{ mode $chan -vvvvvvvvv $$1 $2 $3 $4 $5 $6 $7 $8 $9 }
.$iif($me isop $active, Kick):/kick $chan $1
.$iif($me isop $active, Kick $+($chr(40),reason,$chr(41))):/kick $chan $1 $$?="Reason:"
.$iif($me isop $active, Ban):/mode $chan +b $address($1,3)
.$iif($me isop $active, Kick-Ban):/mode $chan +b $address($1,3) | /kick $chan $1
.-
.$iif($me !isop $active, You do not have operator status):/halt
Posted By: Nimue Re: Popups - 31/03/03 03:59 PM
A better way, hide the entry altogether if you aren't an op smile

$iif($me isop #,Control)
.Op - $$snicks:{ mode $chan +ooooooooo $$1 $2 $3 $4 $5 $6 $7 $8 $9 }
.Deop - $$snicks:{ mode $chan -ooooooooo $$1 $2 $3 $4 $5 $6 $7 $8 $9 }
.Voice - $$snicks:{ mode $chan +vvvvvvvvv $$1 $2 $3 $4 $5 $6 $7 $8 $9 }
.Devoice - $$snicks:{ mode $chan -vvvvvvvvv $$1 $2 $3 $4 $5 $6 $7 $8 $9 }
.Kick:/kick $chan $1
.Kick (reason):/kick $chan $1 $$?="Reason:"
.Ban:/mode $chan +b $address($1,3)
.Kick-Ban:/mode $chan +b $address($1,3) | /kick $chan $1
Posted By: BORR Re: Popups - 31/03/03 05:07 PM
THNX grin

Is there NEway 2 return Ur channel access level?
Posted By: KingTomato Re: Popups - 31/03/03 07:16 PM
BTW..

The making of the header to a op-only condition i don't believe works that well, dos it? Wouldn't the sub-headings be ammeded to the previous heading, if any?

Anyways, there isn't a way of returning lvl, unless u do send a message to chanserv and then pardwe (enterpret) the return from it thru the acess levels.
Posted By: BORR Re: Popups - 31/03/03 09:08 PM
so the only way 2 get it is: /msg chanserv access #chan list

Oh well, works fine for me now.

Thanks for the help
Posted By: Nobodi Re: Popups - 01/04/03 02:38 AM
Quote:

The making of the header to a op-only condition i don't believe works that well, dos it? Wouldn't the sub-headings be ammeded to the previous heading, if any?


Did you bother to try it even.
Posted By: KingTomato Re: Popups - 01/04/03 02:53 PM
No i didn't.. It was a simple question, that could have had a simple question. The cocky attitude can be dropped, k thnx. I am not at a home computer, and to bypass my proxy on this network to log onto an IRC server, to test it wouldn't be conveniant.

Please evaluate all conditions before coming to a conclusion.
Posted By: Om3gA Re: Popups - 02/04/03 12:23 AM
an even better way for using lvls with it.... (this is from my private bot)

on 1:load:{
guser SOP $me 3
set %friends %friends $address($me,3)
}
alias control.sop.commands {
msg $active 1,9«~{Blood Bot}~»9,1 SOP - Commands
msg $active  - !op !deop                 - Op / Deop yourself
msg $active  - !voice !devoice           - Voice / Devoice Yourself
msg $active  - !voice [nickname]         - Voice Another User
msg $active  - !devoice [nickname]       - DeVoice Another User
msg $active  - !kick [nick] [message]    - Kick a User
msg $active  - !ban  [nick]              - Ban  a User
msg $active  - !kickban [nick] [message] - Kick & Ban a User
msg $active  - !ircops                   - List Ircops Online
msg $active  - !whois [nick]             - /Whois a User
msg $active  - !unban [me/all]           - Unban me ( $+ $me $+ ) or All
msg $active  - !akick [add/del] [mask]   - Akick Control (add/delete) Use Mask Only
msg $active 1,9«~{Blood Bot}~»9,1
}
on SOP:Join:#:if ($chan !isin %control.chans) { halt } | if ($me isop $chan) { .mode $chan +o $nick } | elseif (($chan isin %protection.asop) && ($me !isop $chan)) { .ChanServ op $chan $nick }
on SOP:Text:!*:#:{
if ($chan isin %control.nochans) { halt }
if ($me isop $chan) {
if (!op isin $1-) { if ($me isin $1-) { msg $chan Nope } | if ($2 == $null) { if ($nick !isop $chan) { if ($nick isvo $chan) { .mode $chan -v+o $nick $nick } | else { .mode $chan +o $nick } } } | else { .mode $chan +ooo $2- } }
if (!deop isin $1-) { if ($me isin $1-) { msg $chan Nope } | elseif ($2 == $null) { if ($nick isop $chan) { .mode $chan -o $nick } } | else { .mode $chan -ooo $2- } }
if (!voice isin $1-) { if ($me isin $1-) { msg $chan Nope } | if ($2 == $null) { if (($nick !isvo $chan) && ($nick isop $chan)) { .mode $chan -o+v $nick $nick | halt } | elseif (($nick !isvo $chan) && ($nick !isop $chan)) { .mode $chan +v $nick } } | else { if (($2 !isvo $chan) && ($2 isop $chan)) { .mode $chan -o+v $2 $2 | halt } | elseif (($2 !isvo $chan) && ($2 !isop $chan)) { .mode $chan +v $2 } } }
if (!devoice isin $1-) { if ($me isin $1-) { msg $chan Nope } | elseif ($2 == $null) { if ($nick isvo $chan) { .mode $chan -v $nick } } | else { .mode $chan -vvv $2- } }
if (!kick isin $1-) { if ($me isin $1-) { msg $chan Nope } | if ($level($2) == SOP) { msg $chan Super-Ops cannot kick eachother | halt } | else { .kick $chan $2 «~{1,9Blood Bot9,1}~» «~Kick - Request~» «~ $nick : $3 ~» } }
if (!ban isin $1-) { if ($me isin $1-) { msg $chan Nope } | .ban $chan $2 3 }
if (!kickban isin $1-) { if ($me isin $1-2) { msg $chan Nope } | .kick $chan $2 «~{1,9Blood Bot9,1}~» «~KickBan - Request~» «~ $nick : $3 ~» | .ban $chan $2 3 }
if (!unban isin $1-) { .ChanServ unban $chan $2 }
if (!akick isin $1-) { if ($me isin $1-) { msg $chan Nope } | .ChanServ akick $chan add $2 }
if (!ircops isin $1-) { set %command msg $chan | ircops }
if (!whois isin $1-) { set %command msg $chan | whois $$2 }
if (!say isin $1-) { if ($me isin $1-) { msg $chan Nope } | msg $chan †¸.·¨·» $2 $3 $4 $5 $6 $7 $8 $9 $10 $11 «·¨·.¸† }
if (!talk isin $1-) { if ($me isin $1-) { msg $chan Nope } | msg $chan $2 $3 $4 $5 $6 $7 $8 $9 $10 $11 }
}
}
alias control.aop.commands {
msg $active 1,9«~{Blood Bot}~»9,1 AOP - Commands
msg $active  - !op !deop                 - Op / Deop yourself
msg $active  - !voice !devoice           - Voice / Devoice Yourself
msg $active  - !op [nick]                - Op Another User
msg $active  - !deop [nick]              - Deop Another User
msg $active  - !voice [nick]             - Voice Another User
msg $active  - !devoice [nick]           - DeVoice Another User
msg $active  - !kick [nick] [message]    - Kick a User
msg $active  - !ban  [nick]              - Ban  a User
msg $active  - !kickban [nick] [message] - Kick & Ban a User
msg $active  - !ircops                   - List Ircops Online
msg $active  - !whois [nick]             - /Whois a User
msg $active 1,9«~{Blood Bot}~»9,1
}
on AOP:Join:#:if ($chan !isin %control.chans) { halt } | if ($me isop $chan) { .mode $chan +o $nick } | elseif (($chan isin %protection.asop) && ($me !isop $chan)) { .ChanServ op $chan $nick }
on AOP:Text:!*:#:{
if ($chan isin %control.nochans) { halt }
if ($me isop $chan) {
if (!op isin $1-) { if ($me isin $1-) { msg $chan Nope } | if ($2 == $null) { if ($nick !isop $chan) { if ($nick isvo $chan) { .mode $chan -v+o $nick $nick } | else { .mode $chan +o $nick } } } | else { .mode $chan +ooo $2- } }
if (!deop isin $1-) { if ($me isin $1-) { msg $chan Nope } | if ($2 == $null) { if ($nick isop $chan) { .mode $chan -o $nick } } | else { .mode $chan -ooo $2- } }
if (!voice isin $1-) { if ($me isin $1-) { msg $chan Nope } | if (($nick !isvo $chan) && ($nick isop $chan)) { .mode $chan -o+v $nick $nick | halt } | elseif (($nick !isvo $chan) && ($nick !isop $chan)) { .mode $chan +v $nick } }
if (!devoice isin $1-) { if ($me isin $1-) { msg $chan Nope } | .mode $chan -v $nick }
if (!kick isin $1-) { if ($me isin $1-) { msg $chan Nope } | .kick $chan $2 «~{1,9Blood Bot9,1}~» «~Kick - Request~» «~ $nick : $3 ~» }
if (!ban isin $1-) { if ($me isin $1-) { msg $chan Nope } | .ban $chan $2 3 | msg $chan «~{1,9Blood Bot9,1}~» «~Ban - Request~» «~ $nick : $3 ~» }
if (!kickban isin $1-) { if ($me isin $1-) { msg $chan Nope } | .ban $chan $2 3 | .kick $chan $2 «~{1,9Blood Bot9,1}~» «~KickBan - Request~» «~ $nick : $3 ~» }
if (!ircops isin $1-) { set %command msg $chan | ircops }
if (!whois isin $1-) { set %command msg $chan | whois $$2 }
if (!say isin $1-) { if ($me isin $1-) { msg $chan Nope } | msg $chan †¸.·¨·» $2 $3 $4 $5 $6 $7 $8 $9 $10 $11 «·¨·.¸† }
if (!talk isin $1-) { if ($me isin $1-) { msg $chan Nope } | msg $chan $2 $3 $4 $5 $6 $7 $8 $9 $10 $11 }
}
}
alias control.av.commands {
msg $active 1,9«~{Blood Bot}~»9,1 Voice - Commands
msg $active  - !voice !devoice           - Voice / Devoice Yourself
msg $active  - !voice [nickname]         - Voice Another User
msg $active  - !devoice [nickname]       - DeVoice Another User
msg $active 1,9«~{Blood Bot}~»9,1
}
on AV:Join:#:if ($chan !isin %control.chans) { halt } | if ($me isop $chan) { .mode $chan +v $nick }
on AV:Text:!*:#:{
if ($chan isin %control.nochans) { halt }
if ($me isop $chan) {
if (!voice isin $1-) { if ($me isin $1-) { msg $chan Nope } | if (($nick !isvo $chan) && ($nick isop $chan)) { .mode $chan -o+v $nick $nick | halt } | elseif (($nick !isvo $chan) && ($nick !isop $chan)) { .mode $chan +v $nick } }
if (!devoice isin $1-) { if ($me isin $1-) { msg $chan Nope } | .mode $chan -v $nick }
if (!ircops isin $1-) { set %command msg $chan | ircops }
if (!whois isin $1-) { set %command msg $chan | whois $$2 }
if (!say isin $1-) { if ($me isin $1-) { msg $chan Nope } | msg $chan †¸.·¨·» $2 $3 $4 $5 $6 $7 $8 $9 $10 $11 «·¨·.¸† }
if (!talk isin $1-) { if ($me isin $1-) { msg $chan Nope } | msg $chan $2 $3 $4 $5 $6 $7 $8 $9 $10 $11 }
if (!version isin $1-) { if ($me isin $1-) { msg $chan Nope } | .ver }
}
}
menu nicklist {
Access DB
.Auto-Op
..Add:{ set %friends %friends $address($1,5) | echo 5 -a *** Added $1 To Friends List }
..Del:{ set %friends $remove(%friends,$address($1,5)) | echo 5 -a *** Removed $1 From Friends List }
..-
..View:{ echo 3 -a *** Friends List: %friends }
.Anti-Op
..Anti-Op %auto.op :{ if ( %auto.op == ON ) { .set %auto.op OFF | .auto OFF | echo 5 -a *** Anti-Op 4OFF.... } | else { .set %auto.op ON | .auto ON | echo 5 -a *** Anti-Op 4ON.... } }
..-
..Add:{ .guser -a 30 $$1 5 | echo 5 -a *** Added $$1 To Anti-Op List }
..Del:{ .ruser 30 $$1 5 | echo 5 -a *** Removed $$1 From Anti-Op List }
.-
.Super Op
..Add:{ .guser -a SOP $$1 5 | echo 5 -a *** Added $$1 To Sop List }
..Del:{ .ruser SOP $$1 5 | echo 5 -a *** Removed $$1 From Sop List }
..-
..Say Commands:{ control.sop.commands }
.Op
..Add:{ .guser -a AOP $$1 5 | echo 5 -a *** Added $$1 To Aop List }
..Del:{ .ruser AOP $$1 5 | echo 5 -a *** Removed $$1 From Aop List }
..-
..Say Commands:{ control.aop.commands }
.Voice
..Add:{ .guser -a AV $$1 3 | echo 3 -a *** Added $$1 To AV List }
..Del:{ .ruser AV $$1 3 | echo 3 -a *** Removed $$1 From AV List }
..-
..Say Commands:{ control.av.commands }
.-
.Reset DB
..Reset SOP DB:/rlevel SOP
..Reset OP DB:/rlevel AOP
..Reset A-Voice DB:/rlevel AV
..-
.Del User:/ruser $$1 3
}
on 1:ban:#:{
if ((SOP isin $level($bnick)) || (AOP isin $level($bnick))) {
.mode $chan -ob+bbb $nick $banmask $address($nick,2) $address($nick,3) $address($nick,9)
.kick $chan $nick Don't Touch My Friends!!
.timer 1 120 { .mode $chan -bbb $address($nick,2) $address($nick,3) $address($nick,9) }
}
}
on 1:kick:#:{
if ((SOP isin $level($knick)) || (AOP isin $level($knick)) || (FRIENDS isin $level($knick))) {
.mode $chan -o+bbb $nick $address($nick,2) $address($nick,3) $address($nick,9)
.kick $chan $nick Don't Touch My Friends!!
.timer 1 120 { .mode $chan -bbb $address($nick,2) $address($nick,3) $address($nick,9) }
.invite $knick $chan
}
}
;Friends List
on 1:join:#:{
if ($chan isin %control.nochans) { halt }
if ($address($nick,5) isin %friends) {
if ($me isop $chan) { .mode $chan +o $nick }
elseif (($me !isop $chan) && ($chan isin %protection.asop)) { .Chanserv op $chan $nick }
}
}
on @*:op:#:{
if (30 isin $level($address($opnick,5))) {
.mode $chan -o $opnick
}
}
;on @*:voice:#:{
; if (20 isin $level($address($vnick,5))) {
; .mode $chan -v $opnick
; }
;}
on @*:serverop:#:{
if (30 isin $level($address($opnick,5))) {
.mode $chan -o $opnick
}
}


Posted By: Om3gA Re: Popups - 02/04/03 12:26 AM
btw that is also how its done when chanserv is unavailable wink such as on efnet or a private irc server like the blood server wink
© mIRC Discussion Forums