CharmedOne Posted March 17, 2010 Report Share Posted March 17, 2010 Ok this is just beyonddddddddd me i know this looks right but it isnt working, once i added the return to my code the whisper stopped closing so now i am lost, i cant believe i am having probs with something so simple. #whisperclose on raw WHISPER:*: { if (allow isin $+(*!*, $Ial($nick).addr))) { return if ($nick isop #) { return .closemsg $nick } } } #whisperclose end Link to comment Share on other sites More sharing options...
err0r Posted March 18, 2010 Report Share Posted March 18, 2010 unless i'm mistaken raw whisper doesn't return # for channel $1 will return the channel name allow won't be in the ial addr of the nick either i'm guessing you are trying to close any whispers that are not from ppl on your allow list or that are not ops in the channel. if so and you are adding user level to allow by the ial addy try this #whisperclose on raw WHISPER:*: { if (allow !isin $level($+(*!,$Ial($nick).addr))) && ($nick !isop $1) { .closemsg $nick } } #whisperclose end Note: your user level format would be like this Allow Whispers : auser allow *! $+ $ial($$1).addr $$1 Link to comment Share on other sites More sharing options...
Pablo Posted March 18, 2010 Report Share Posted March 18, 2010 Raw events will not return $chan as err0r states. Also, you are searching for "allow" in the long gate. That will never be there. I am not sure what is meant by allow, but I am assuming that allow is supposed to be a variable you set to allow gates to whisper you. I am thinking you want something more like... raw Whisper:*: { if ( $ial($nick,1) !isin %allow && $nick !isop $1 ) { halt } ; if the gate is in allow or the nick is an op, it will continue.. otherwise it stops... } menu nicklist { Allow Whisper: { set %allow $addtok(%allow, $ial($1,1), 32) } } I think this works;) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now