You are god. Your services are appreciated. <3

But, um, /unban would pwn too.

Code:
alias secure {/msg chanserv set $$1 keeptopic on
/msg chanserv set $$1 topiclock on
/msg chanserv set $$1 keeptopic on
/msg chanserv set $$1 private on
/msg chanserv set $$1 restricted on
/msg chanserv set $$1 opnotice on
/msg chanserv set $$1 enforce on }


My latest project. However, I'm not sure I understand the errorchecking system. Could you help me implement it for errors nonexistant channel and access denied?

Edit: if ($1(!ischan)) { echo -a $1 is an invalid channel }

is what I came up with for invalid channel, from looking at your notes in the other scripts. But it doesn't work. Where did I go wrong?

on 1:notice:Access denied.: /echo -a Access denied. | halt
on 1:notice:channel # isn't registered: /echo -a Nonexistant channel. | halt


Some more stuff I came up with. But I don't know how to integrate it into the if-then-else

Edit: Been working a little, got this:

alias secure {
if ($1 ischan) {
/msg chanserv set $$1 topiclock on
/msg chanserv set $$1 keeptopic on
/msg chanserv set $$1 private on
/msg chanserv set $$1 restricted on
/msg chanserv set $$1 opnotice on
/msg chanserv set $$1 enforce on }
}


But that's fairly useless because I have to be ON the channel, I think. And it still doesn't help with access denied.

---

Also, for the /i alias, is there some way to make it work even if the person isn't sharing a channel with you?

--

ALSO, I'm doing SOP aliases. I want it to either SOP on the channel spefcified, or on the channel it was typed on if there was no channel specified. I know we did this with the invite script, but I just don't get it. Could you single out that part of the script and help me with it? /aop /msg chanserv aop #$2 add $1 is what I've managed so far. Of course, error checking would be nice. But I still need help with that. =\

EDIT: Does

alias aop { if ($active ischan) { msg chanserv aop $active add $1 | halt }
else ( msg chanserv aop $2 add $1 ) }


have any merit?

Edit2: Tried it. Worked sorta okay. AOPed the nick on the inputed channel when specification was given, but it still AOPed on the inputed channel when specification WAS given.

Last edited by Mpot; 03/09/07 09:27 PM.