This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Devoice on repeats

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
Post Reply
L
Lucifer
Voice
Posts: 17
Joined: Wed Nov 01, 2006 7:02 pm

Devoice on repeats

Post by Lucifer »

hey can anybody help me with script to devoice ppl on repeats msg/actions ???
User avatar
TCL_no_TK
Owner
Posts: 509
Joined: Fri Aug 25, 2006 7:05 pm
Location: England, Yorkshire

Post by TCL_no_TK »

Please use Sir_Fz's code below :) thnx
Last edited by TCL_no_TK on Sun Aug 30, 2009 10:47 am, edited 2 times in total.
L
Lucifer
Voice
Posts: 17
Joined: Wed Nov 01, 2006 7:02 pm

Post by Lucifer »

Thanks mate, but got an error can u fix it please...
Tcl error [pubm:repeat_devoice]: expected boolean value but got ""
User avatar
Sir_Fz
Revered One
Posts: 3794
Joined: Sun Apr 27, 2003 3:10 pm
Location: Lebanon
Contact:

Post by Sir_Fz »

Try

Code: Select all

# repeats:seconds
set nrepeats 3:2

bind pubm - * devoice:repeats
bind ctcp - ACTION devoice:repeats

proc devoice:repeats {nick uhost hand chan arg {arg2 ""}} {
 global nrepeats
 if {![validchan $chan] || ![isvoice $nick $chan]} {return}
 if {$arg2 != ""} {
  set arg $arg2
 }
 foreach {o s} [split $nrepeats :] {break}
 set arg [md5 $nick:$uhost:$chan:[stripcodes bcruag $arg]]
 if {[flooded $arg $s $o]} {
  pushmode $chan -v $nick
 }
}

proc flooded {id s o} {
 global flooded
 if {![info exists flooded($id)]} {
  set flooded($id) 0
  utimer $s [list unset flooded($id)]
 }
 expr {[incr flooded($id)] >= $o}
}
User avatar
TCL_no_TK
Owner
Posts: 509
Joined: Fri Aug 25, 2006 7:05 pm
Location: England, Yorkshire

Post by TCL_no_TK »

thnx Fz :)
@Lucifer will take a while before i can test the script, but ive already loaded it up and got the same error message, so it'll fix it over the weekend if i get the time.
Post Reply