My First flood protection by boody010

VIEWS: 1 PAGES: 1

									on *:text:!floodon:#:{
  if ($nick isop $chan) || ($nick ishop $chan) {
    if (%floodchan) {
      notice $nick flood protection is already on for $chan
    }
    else {
      set %floodchan $addtok(%floodchan,$chan,44)
      msg $chan 4 Flood protection is now on for $chan
    }
  }
}
on *:text:!floodoff:#:{
  if ($nick isop $chan) || ($nick ishop $chan) {
    if (%floodchan) {
      set %floodchan $remtok(%floodchan,$chan,1,44)
      msg $chan 4 Flood protection is now off for $chan
    }
    else {
      notice $nick Flood protection is already turned off for $chan
    }
  }
}
on *:text:*:%floodchan: {
  if $nick !isop $chan {
    hadd -mu10 chanflood $+($nick,.,$chan,.,$ticks) 1
    if ($hfind(chanflood,$+($nick,.*),0,w) > 6) {
      ban $+(-,ku,$calc(60)) $chan $nick $nick Dont Flood $chan !!! (1
Minute Ban)
    }
  }
}

								
To top