Hiya, i was wondering if anyone knew where the final version of tsunami.tcl could be found, i know the script is old, although i am interested to see and use it.
Thanks in advanced
Code: Select all
# tsunami.tcl
# version 0.1 beta 2
# caesar <cezarica@prietenii.com>
# #eggdrop @ Undernet.org
# http://www.geocities.com/caesartcl/
### Description:
# Will lock and kick+ban the users that use a tsunami flood on the channel.
### Notes:
# This is still in beta testing so use it on your own risk!
# You will need eggdrop 1.6.x in order this to work.
# What channel modes do you want to be used for locking the channel?
set modes "mR"
# Number of lines in seconds keep channel locked for if they have how many characters?
# By default I've set it to 5 lines in 3 seconds to lock the channel for 60 seconds if they have more than 50 characters.
set ltl 6:3:30:13
### ANY EDITING AND/OR MODIFICATIONS MADE BEYOND THIS IS YOUR OWN RISK! ###
# binds #
bind pubm - * tsunami:pub
bind part - * tsunami:part
# stuff #
set blist ""
# setudef flag tsunami
# array fix #
foreach chan [channels] {
# if {![channel get [strlwr $chan] tsunami]} {
# return
# }
set bla([strlwr $chan]) 0
}
# tsunami #
proc tsunami:pub {nick uhost hand chan text} {
global bla blist
if {[strlwr $nick] == [strlwr $::botnick] || ![botisop [strlwr $chan]]} {
# || ![channel get [strlwr $chan] tsunami]
return
}
set cm [getchanmode [strlwr $chan]]
if {(([string match {+*[$::modes]*[::modes]*} $cm]) && ([llength [split $::modes]] == 1)) || (([string match {+*[::modes]*[::modes]* *} $cm]) && ([length [split $cm]] > 1))} { return }
set linelength [lindex [split $::ltl ":"] 3]
if {[string length [join [split $text] ""]] > "$linelength"} {
lappend blist [strlwr $nick]
set lines [lindex [split $::ltl ":"] 0]
set insec [lindex [split $::ltl ":"] 1]
set unlock [lindex [split $::ltl ":"] 2]
incr bla([strlwr $chan])
utimer $insec "reset [strlwr $chan]"
utimer $insec "remove [strlwr $nick]"
if {$bla([strlwr $chan]) >= $lines} {
putquick "MODE [strlwr $chan] +$::modes"
foreach luser $blist {
set mask "*!*@[lindex [split [getchanhost $luser [strlwr $chan]] @] 1]"
newchanban [strlwr $chan] $mask Tsunami "Tsunami flooder!" 5
}
utimer $unlock "unlock [strlwr $chan]"
}
}
}
# reset #
proc reset {chan} {
global bla
incr bla([strlwr $chan]) -1
return
}
# remove #
proc remove {nick} {
global blist
lreplace blist [strlwr $nick] [strlwr $nick]
return
}
# unlock #
proc unlock {chan} {
putquick "MODE [strlwr $chan] -$::modes"
return
}
# array remove #
proc tsunami:part {nick uhost hand chan msg} {
global bla
if {$nick != $::botnick} {
return
}
foreach arr_part [array names bla] {
if {[string match [strlwr [strlwr $chan]] $arr_part]} {
array unset bla [strlwr $chan]
}
}
}
putlog "tsunami.tcl.. loaded"