mIRC Home    About    Download    Register    News    Help

Print Thread
#187828 13/10/07 07:00 PM
Joined: Oct 2007
Posts: 36
A
asmodeo Offline OP
Ameglian cow
OP Offline
Ameglian cow
A
Joined: Oct 2007
Posts: 36
Hi for all

CODE:
on 1!@:JOIN:#: {
if (($chan isin %myrooms) && ( problem code frown )) { .mode $chan +v $nick }
}

I would like to exclued users with this mask: *!1034*@*
The code task will be: if one user has join on one of my rooms, and this user has not mask *!1034*@*, else I will give him voice.
It is easy, but i don´t know do it cry

Thanks for all! This code is very important for me.
Nice time! smile
Note: I am spanish, and my english not very good, i hope that you understand post.


·´¯`·.¸¸“Jã¢k øf ãll ‡rãÐ꧅„…Mã§têR øf Nønꔸ¸.·´¯`·
Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
Code:
on @*:join:%myrooms:{
  if *!1034*@* !iswm $address($nick,5) {
    .mode # +v $nick
  }
}


Since the @ in the ON JOIN event requires you to be opped in the channel, the usage of ! in that same event is redundant.

If you have your room list, as stored in %myrooms, comma separated, then you can use the variable in place of the channel name in the ON JOIN event.

These are the most common questions regarding the changes I made, but if you have other questions, ask and I'll try to explain.

Joined: Oct 2007
Posts: 36
A
asmodeo Offline OP
Ameglian cow
OP Offline
Ameglian cow
A
Joined: Oct 2007
Posts: 36
Hi RusselB, and thx very much, really! smile
I was tried other code: ($address($nick,5) !isin *!1034*@*) mixed

But I don´t undertand you when you tell me "comma separated"
I have my room list in one variable like this:
%myrooms #channel1 #channel2 #channel3 it is ok?
or it must be: %myrooms #channel1,#channel2,#channel3

Thanks again RusselB




·´¯`·.¸¸“Jã¢k øf ãll ‡rãÐ꧅„…Mã§têR øf Nønꔸ¸.·´¯`·
Joined: Jul 2007
Posts: 32
S
Ameglian cow
Offline
Ameglian cow
S
Joined: Jul 2007
Posts: 32
No i think its meant to be.

Code:
 %myrooms #channel1, #channel2, #channel3 



Joined: Oct 2004
Posts: 8,330
Hoopy frood
Offline
Hoopy frood
Joined: Oct 2004
Posts: 8,330
Yes, it needs commas.


Invision Support
#Invision on irc.irchighway.net
Joined: Dec 2002
Posts: 503
B
Fjord artisan
Offline
Fjord artisan
B
Joined: Dec 2002
Posts: 503
It's an event. Use $fulladdress instead of $address($nick,5).

Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
OK.. I had no problems testing it using $address($nick,5), but by no means am I going to say that $fulladdress might not be as good or possibly better.

Joined: Dec 2002
Posts: 503
B
Fjord artisan
Offline
Fjord artisan
B
Joined: Dec 2002
Posts: 503
*nod*, yeah, it'll work using it. I just say it as an efficiency thing for new users.

When using a remote-user triggered event (TEXT, NOTICE, JOIN, etc. etc.), the full user mask (the equivalent of $address($nick,5)) is put into $fulladdress. It just means less client-side operations (evaluation of $nick, followed by an IAL lookup for $address()).

Joined: Jul 2007
Posts: 32
S
Ameglian cow
Offline
Ameglian cow
S
Joined: Jul 2007
Posts: 32
Yea, that wat is better hope your problem is fixed laugh


Link Copied to Clipboard