All pastes #89496 Raw Edit

Stuff

public text v1 · immutable
#89496 ·published 2006-07-16 10:10 UTC
rendered paste body
on *:TEXT:*:#:{
  ;flood protection
  if ($hget(flood. $+ $nick,ig)) { halt }
  %bl4h.floodunomsgs = 3
  %bl4h.floodunosec = 4
  ;length of ignore in seconds
  %bl4h.floodunoignore = 10
  if (!$hget(flood. $+ $nick,s)) { 
    hadd -m flood. $+ $nick t $1
    hadd -m flood. $+ $nick times 1
    hadd -z flood. $+ $nick s %bl4h.floodunosec
    goto gays 
  }
  if ($hget(flood. $+ $nick,times) >= %bl4h.floodunomsgs && $hget(flood. $+ $nick,s)) {
    hadd -u $+ %bl4h.floodunoignore flood. $+ $nick ig 1
    .notice $nick You're flooding me. *ignores your commands for %bl4h.floodunoignore seconds*
    halt 
  }
  if ($1 == $hget(flood. $+ $nick,t)) { hinc flood. $+ $nick times }
  :gays
  ;end flood protection