mIRC Homepage
Posted By: andymps Should this work - 10/06/03 12:32 AM
Code:
 
on 1:op:#: {
  if $read(blacklist.txt) {
    if $opnick == $ifmatch { mode $chan -o $ifmatch }
  }
}
 

Should that work
blacklist.txt contains the blacklisted ppl
Posted By: codemastr Re: Should this work - 10/06/03 12:36 AM
Probably not, because $read(blacklist.txt) reads a random line, you probably want to test if ANY line == the $nick.
Code:
on @1:op:#: {  
   if $read(blacklist.txt,s,$opnick) {    
      mode $chan -o $ifmatch 
   }
} 

That tests if there is a line in the file that starts with the value of $opnick. I also added the @ to make it so it doesn't trigger if you are not an op.
Posted By: andymps Re: Should this work - 10/06/03 12:41 AM
Thanx smile
Posted By: andymps Re: Should this work - 10/06/03 12:49 AM
Hmmm i just tested that and it doesnt seem to work
Code:
on @1:op:#: {    
  if $read(blacklist.txt, s, $opnick) {  
    mode $chan -o $ifmatch    
  }
} 
 

thats what i have
Posted By: codemastr Re: Should this work - 10/06/03 12:52 AM
Can you include 2-3 lines of what is contained in the file?
Posted By: andymps Re: Should this work - 10/06/03 12:57 AM
Well just nick in the format of
Code:
  
Whiz`
Kater`
Breakerul

and like that
cos i have setup in popups so when i click on black list it adds that person to the txt
Posted By: codemastr Re: Should this work - 10/06/03 12:59 AM
try changing that $ifmatch to $opnick.
Posted By: andymps Re: Should this work - 10/06/03 01:03 AM
ok done that it looks like :
Code:
  
on @1:op:#: {    
  if $read(blacklist.txt,s,$opnick) {  
    mode $chan -o $opnick    
  }
} 


but still nothin
Posted By: andymps Re: Should this work - 10/06/03 02:02 AM
also im lookin to devise a script that so when someone swears it quotes what was said and a warning and kicks em if they do it again but it doesnt kick ops

can any1 help
Posted By: andymps Re: Should this work - 10/06/03 02:41 AM
cos i get the on text bit appart from how do u make it identify 1 word from a sentance and if that word is in a txt file with loads of swear words in?
Posted By: KingTomato Re: Should this work - 10/06/03 03:21 AM
swearing.mrc Just for you >:D
Posted By: Nobodi Re: Should this work - 10/06/03 09:20 AM
Try using the w switch in place of the s switch.

Code:
  
on @1:op:#: {
  if $read(blacklist.txt,[color:red]w[/color],$opnick) {
  mode $chan -o $opnick
 }
}
 

Posted By: andymps Re: Should this work - 10/06/03 03:04 PM
Thnx,
KingTomato, i clicked that link and it says page cannot be displayed?
Posted By: The_Game Re: Should this work - 10/06/03 04:34 PM
Thats funny cause it works for me...
Posted By: Online Re: Should this work - 10/06/03 04:57 PM
Here's the correct link: http://www.kingtomato.com/files/swearing.mrc
Posted By: KingTomato Re: Should this work - 10/06/03 05:19 PM
thanks online, thats what happens after midnight--all you senses leave you. Including (but not limited to) typing. heh
© mIRC Discussion Forums