Page 1 of 1

mirc scripting

Posted: Tue Sep 06, 2005 3:44 pm
by Shintorojin
Hey guys,
I was wondering if someone could tell me how to reference Chanserv in my scripting, i'm trying to make a script that if anyone but me changes my modes, it auto changes it back... But i'm not sure what the identifier for serives is... Should i use [email protected]?

Thanks in advance,
Shinji

Re: mirc scripting

Posted: Tue Sep 06, 2005 8:08 pm
by Darvocet
Shintorojin wrote:Hey guys,
I was wondering if someone could tell me how to reference Chanserv in my scripting, i'm trying to make a script that if anyone but me changes my modes, it auto changes it back... But i'm not sure what the identifier for serives is... Should i use [email protected]?

Thanks in advance,
Shinji
Why not use mode lock, or mlock. Available with at least ircservices but im sure with anope as well. /chanserv set #channel MLOCK +ntl 30

Then chanserv will change the modes back. You can also include -mps and stuff like that so if someone adds one that you don't allow it removes it.

Example: (My mode lock is: -ChanServ- Mode lock: +nt-impsklcNf)

[2:36pm] XanaX[a] sets mode: +smi
[2:36pm] XanaX[a] sets mode: +lk 213 21321
[2:36pm] ChanServ sets mode: -smilk 21321

Posted: Wed Sep 07, 2005 6:18 am
by w00t
I believe he meant on someone deopping etc.. try something like this

on 1:DEOP:*:{
if ($opnick == $me && ($nick != $me || $nick != ChanServ)) {
cs op $chan $me
; _kickbanengine $chan $nick Naughty!
}
}

Posted: Wed Sep 07, 2005 12:27 pm
by Shintorojin
hehe, yeah thanks w00t thats exactly what i was refering to. I tried with the ChanServ bit but it didn't work. I'll try yours and see what happens...

Thanks,
Shinji

Posted: Wed Sep 07, 2005 12:35 pm
by Shintorojin
okay i tested it. It seems it doesn't see * JM sets mode: -o JM as identifier $nick...

Anyone got any idea's??

Thanks,
Shinji

Posted: Thu Sep 08, 2005 12:45 am
by Wiggle
$opnick = person being opped/deopped
$nick = person opping or deopping

Code: Select all

on !*:DEOP:#:{
  if ($opnick == $me) && ($nick != ChanServ) {
    chanserv op # $me
  }
}
Should try re-opping if anyone but ChanServ or yourself deops you. (Of course someone could deop you through ChanServ, but that's another story :P.)

Posted: Thu Sep 08, 2005 8:52 am
by w00t
Yup, it's designed to allow that - ie: people who have channel access I don't mind screwing with me, but other people freak me out ;)

Posted: Thu Sep 15, 2005 11:11 am
by White_Magic
lol i thought the first post ment umodes lol oh my *wakes up*