Docstoc

repeating

Document Sample
repeating Powered By Docstoc
					on 1:TEXT:*:#:{
    var %repeat = $repeattt(1,3,30,$chan,$nick,repeat,$1-)
    if (%repeat) {
      var %rl = $gettok(%repeat,1,46)
      var %rt = $gettok(%repeat,2,46)
      mode # -v $nick
      ban -u120 # $nick 2
      msg #   4 $nick $+ ,   12 Text repeating are not allowed on the
main - banned for 2 minutes.

            return
        }
    }
}


;REPEAT


alias repeattt {
  var %t = $hash($strip($7-),32)
  if ($hget($+(prot.,$cid,.,$4)) != $+(prot.,$cid,.,$4)) hmake
$+(prot.,$cid,.,$4) 1500
  var %h = $+(prot.,$cid,.,$4)
  var %h1 = $+($6,.,$5)
  var %h3 = $hget(%h,%h1)
  if (%h3) {
    var %last.text = $gettok(%h3,3,46)
    if (%t == %last.text) {
      var %counts = $gettok(%h3,1,46)
      var %inccounts = $calc(%counts + 1)
    }
    elseif (%t != %last.text) {
      var %inccounts = 1
    }
    var %c = $gettok(%h3,2,46)
    var %ct = $calc($ctime - $gettok(%h3,2,46))
    hadd -u [ $+ [ $calc($3 - %ct) ] ] %h %h1 $+(%inccounts,.,%c,.,%t)
    if ($calc(%counts + $1) == $2) { return
$+($gettok($hget(%h,%h1),1,46),.,$calc($ctime -
$gettok($hget(%h,%h1),2,46))) }
  }
  else { hadd -u [ $+ [ $3 ] ] %h %h1 $+($1,.,$ctime,.,%t) }
}

alias addz {
  var %i = 1
  while (%i <= 2016) {
    write -a astra/f $+ %i $crlf
    inc %i
  }


}

				
DOCUMENT INFO
Shared By:
Categories:
Tags:
Stats:
views:0
posted:11/1/2012
language:
pages:1