mIRC Home    About    Download    Register    News    Help

Print Thread
#90115 11/07/04 10:05 PM
Joined: Jul 2004
Posts: 4
L
lstyd Offline OP
Self-satisified door
OP Offline
Self-satisified door
L
Joined: Jul 2004
Posts: 4
how to isolate few users

like ON join if (friend1 isin $nick) || (someshit isin $address) { leave him }
else ban onthers ?

#90116 11/07/04 10:09 PM
Joined: Apr 2004
Posts: 66
C
Babel fish
Offline
Babel fish
C
Joined: Apr 2004
Posts: 66
Code:
on !@:JOIN:#:{
if (($nick != <friend>) || (<whatever> !isin $address)) { ban # $nick 3 }
} 



Replace <friend> with the nick of your friend. And replace <whatever> with the actual address you want to check.

#90117 11/07/04 10:15 PM
Joined: Jul 2004
Posts: 4
L
lstyd Offline OP
Self-satisified door
OP Offline
Self-satisified door
L
Joined: Jul 2004
Posts: 4
and what if i have this:

if (($nick != name1) || ($nick != name2) || ($nick != name100) || ($nick != name200) || (some.crap.com !isin $address) || (host2.bnc.net !isin $address)) { }

and if friend HAS name "name1" and his host is host2.bnc.net and NOT some.crap.com ?

the what ?

he gets banned no matter if he has good nickname ?

Last edited by lstyd; 11/07/04 10:25 PM.
#90118 12/07/04 07:13 AM
Joined: Feb 2003
Posts: 67
N
Naz Offline
Babel fish
Offline
Babel fish
N
Joined: Feb 2003
Posts: 67
In your example a user would only have to match one in order to NOT get banned.

However, if you want to include many nicks or addresses it would be easier to tokenize them in a varialbe or text file line. For example set the nicks to %nicks nick1,nick2,nick3,nick4,nick5

Then you can use if !$istok(%nicks,$nick,44) { do stuff } and the same idea for addresses.


Those who live by the sword get shot by those who don't.
#90119 12/07/04 09:13 AM
Joined: Apr 2003
Posts: 701
K
Hoopy frood
Offline
Hoopy frood
K
Joined: Apr 2003
Posts: 701
Code:
[color:blue]alias nofriendban {
  if (!$istok($level($fulladdress),friend,44)) {
    ; well, kick him out
  }
  ;  else echo $chan he's your friend!
}[/color]


Next, you have to put for all your friends a line (or some lines) in the Users tab (ALt-R)
The format is:
friend:[color:green]nick!user@address[/color]
You can use the standard wildcard characters.

#90120 12/07/04 01:52 PM
Joined: Jul 2004
Posts: 4
P
Self-satisified door
Offline
Self-satisified door
P
Joined: Jul 2004
Posts: 4
Or, if you have an O:line on a server, /kline and /akill work very nicely smile


---pianomany2k
pianomany2k@gmail.com

Link Copied to Clipboard