mIRC Home    About    Download    Register    News    Help

Print Thread
#145851 28/03/06 10:58 PM
Joined: Apr 2005
Posts: 1,009
raZOR Offline OP
Hoopy frood
OP Offline
Hoopy frood
Joined: Apr 2005
Posts: 1,009
how can you check if nickname OR adress is in $ulist
IF i dont know address ?

like
on *:JOIN:#mychan:{
if ($nick iswm $ulist) { halt }
else { /ban -k $chan $nick you are not wanted }
}

or

on *:JOIN:#mychan:{
if (.domain iswm $ulist) { halt }
else { /ban -k $chan $nick your host is forbidden }
}

but i saw mirc is not capable to check only nickname
or adress thru $ulist on such simple way...

Last edited by raZOR; 28/03/06 11:01 PM.

IceCapped
#145852 28/03/06 11:15 PM
Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
Code:
 on !@*:join:#:{
if !$ulist($+($nick,*)) && !$ulist($+(*,$address)) {
.ban -k $chan $nick You are not wanted
}
}
 


Untested, but it should work

#145853 28/03/06 11:27 PM
Joined: Apr 2005
Posts: 1,009
raZOR Offline OP
Hoopy frood
OP Offline
Hoopy frood
Joined: Apr 2005
Posts: 1,009
what to change if i want just for adress check (domain) ?


IceCapped
#145854 28/03/06 11:40 PM
Joined: Apr 2005
Posts: 1,009
raZOR Offline OP
Hoopy frood
OP Offline
Hoopy frood
Joined: Apr 2005
Posts: 1,009
doh, sorry :tongue:
(its almoust 2am and my brain sux) =)

thanks for this code !

edit:

still i wonder how can i define .domain (specific) for ban

like if i dont want anyone from .uk in channel ?

Last edited by raZOR; 28/03/06 11:42 PM.

IceCapped
#145855 29/03/06 12:39 AM
Joined: Aug 2004
Posts: 7,252
R
Hoopy frood
Offline
Hoopy frood
R
Joined: Aug 2004
Posts: 7,252
Replace $+(*,$address) with *!*@*.uk

#145856 29/03/06 09:39 AM
Joined: Apr 2005
Posts: 1,009
raZOR Offline OP
Hoopy frood
OP Offline
Hoopy frood
Joined: Apr 2005
Posts: 1,009
thanks very much =)
i apreciate it

~edit~

i have bot on mirc 6.16
and i have 1 user on user list
that matches banned domain

and i get this error then:

421 My_Bot user!*@banned.host.domain :Unknown command

may i ask why?
(or this is 6.16 bug) ?

~ edit 2 ~

it still puzzles me...
i am on user list, and script checks if user or domain is
NOT on user list, so why i get banned then ?
and my nickname or domain arent changed
(i use hidden host server side +x, so it is always same)

Last edited by raZOR; 29/03/06 09:50 AM.

IceCapped

Link Copied to Clipboard