mIRC Homepage
Posted By: Stium Spam script help - 15/05/04 10:43 PM
Alright guys I'm lost at how to add an ifop part of this.

I love how the script works, I just don't want it effecting the ops in the channel.

Code:
 on @*:text:*:%clanchan:{

  if (%flood. [ $+ [ $chan ] $+ ] . [ $+ [ $nick ] ] == $null) {

    set -u8 %flood. $+ $chan $+ . $+ $nick 0

  }

  inc %flood. $+ $chan $+ . $+ $nick 

  if (%flood. [ $+ [ $chan ] $+ ] . [ $+ [ $nick ] ] >= 5) {

    mode $chan -v $nick | mode $chan +b $nick | .timer 1 60 /mode $chan +v $nick | .timer 1 40 /mode $chan -b $nick | .notice $nick %color1 You have been devoiced for 60 seconds due to flooding. %color2 | .msg $chan %color1 Remember not to spam or you'll end up like $nick %color2 | unset %flood.nick

  }
}
 


Thanks
Posted By: Zyzzyx26 Re: Spam script help - 15/05/04 11:01 PM
If i understood that right, just add this at the beginning of the code (after the on @*:text:*:%clanchan:{)
Code:
if ($nick isop $chan) { halt }
Posted By: Wolfie Re: Spam script help - 16/05/04 04:14 AM
Code:
on @*:text:*:%clanchan:{
  if ($nick isop $chan) { return }
  inc -u8 $+(%,flood.,$chan,.,$nick)
  if ($($+(%,flood.,$chan,.,$nick),2) > 4) {
    mode $chan -v+b $nick $nick
    .timer 1 60 /mode $chan -b+v $nick $nick
    .notice $nick %color1 You have been devoiced for 60 seconds due to flooding. %color2
    .msg $chan %color1 Remember not to flood or you'll end up like $nick %color2
  }
}


See if this works for you. When you are devoicing someone, you can ban them with the same mode command (cut down on commands sent, reduce flooding potential). Although personally, I wouldn't recommend making so much happen because then if a few people gang up on you, they can make your script flood you off. It's also unnecessary to set a value to 0 before inc'ing it.
© mIRC Discussion Forums