Kod: Kodu kopyalamak için üzerine çift tıklayın!
set ngver "v0.6.3"
# newgreet v0.6.3 for eggdrop v1.3
# by toot <toot@
[Üye Olmadan Linkleri Göremezsiniz. Üye Olmak için TIKLAYIN...]d9.net>
# tested on eggdrop v1.3.16
# 02/6/23
# this script will choose a random greet from a text
# file when a user who the bot doesn't know enters
# the channel. i got the idea from a tcl i saw on
# efnet, i'm not sure who wrote it tho...
# BIG BIG thanks to Design who helped me :)
# just put the tcl file in your scripts directory, add
# it to your config, and put a greets file in your
# eggdrop directory.. :)
## you just need to set the file the greets will
## be chosen from.. one greet per line.
set greetfile "greetfile.txt"
## here's the actual script..
bind join - * ngreet
proc ngreet {nick host handle chan} {
if {$handle == "*"} {
global greetfile
set file [open $greetfile r]
set line 0
while ![eof $file] {
set lines([incr line]) [gets $file]
}
set line [rand $line]
set randomline $lines($line)
close $file
putserv "PRIVMSG $chan :\[$nick\] $randomline"
}
}
putlog "\002newgreet\002 $ngver by toot, loaded!@"
DipNot : Alıntıdır.