mIRC Homepage
Posted By: bcancer exempt ip - 11/01/08 08:40 PM
Any code that I can use to exempt certain ip from being ban from my script?
Posted By: sparta Re: exempt ip - 11/01/08 09:30 PM
Give the hosts you want to protect a level above 1, the return if the users level => 1
Posted By: Riamus2 Re: exempt ip - 11/01/08 09:32 PM
The method depends on how your script is set up and also whether or not you're actually using IP's or if you're using the address mask, which may be a host instead of an IP.

The basic idea would be:

Code:
  if (255.255.255.255 isin $address($nick,2)) { return }
  else { ban code }


Note that you could also just use the User list and check for the user level and if the user has a "protected" level, don't ban. Like I said, it depends on your script and how you want to do it.
Posted By: bcancer Re: exempt ip - 11/01/08 10:15 PM
Cool it works, can I add more then one ip on that line? if so exemple please :P
Posted By: Wims Re: exempt ip - 11/01/08 10:32 PM
Something like that should works :

if ($istok(Ip1 Ip2 Ip3 IpN,$token($wildsite,2,64),32)) { return }
else { ban code }
Posted By: bcancer Re: exempt ip - 11/01/08 11:35 PM
Tkx guys.
Posted By: Riamus2 Re: exempt ip - 12/01/08 11:21 AM
Wims showed you an example using the same idea I gave, but if you really want multiple exceptions, you're better off using the User List.
© mIRC Discussion Forums