IRCForumları - IRC ve mIRC Kullanıcılarının Buluşma Noktası
  sohbet

Yeni Konu aç Cevapla
 
LinkBack Seçenekler Stil
Alt 27 Şubat 2011, 00:25   #1
Çevrimdışı
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
IF Ticaret Sayısı: (0)
IF Ticaret Yüzdesi:(%)
eggdrop1.6.13+laston




merhaba arkadaslar Oyun triva tcl benim eggdrop Botda calismiyor eski sürüm oldugundan dolayi mi tcller calismiyor yardimci olurmursunuz......
set tgquestionnumber "0"

# soru dosyalarýnýn tutlacaðý dizin.
set tgqdb "scripts/trivia.questions"

# skorlarýn yazýlacaðý dizin
set tgscf "scripts/trivia.scores"

# soru veya cevap hatalarýnýn saklanacaðý dizin
set tgerrfil "scripts/trivia.errors"

# [0/1] Hata raporu mail araciligi ile gonderilsin mi
set tgerrmethod 0


# hata raporu gonderilmeden once gecici dosyalar nerede saklansin
set tgerrmailtmp "/tmp"

# hata raporlarinin gonderilecegi mail adresi
set tgerremail "
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
"


# Oyunun oynanacagi kanal
set tgchan "#oyun"

# doðru cevaba verilecek puan
set tgpointsperanswer 5

# Soru cevap ayraci girin
set tgqdbsep "|"


# soru bankanizda sorular
# SORU\CEVAP seklinde ise 1
# CEVAP\soru seklinde ise 0
set tgqdbquestionfirst 0


# Web sayfasi olarak düzenlenen dosya nerede saklansin.
set tghtmlfile "scripts/mychan.html"

# web sayafsi ne zaman sürede update edilsin
# 0 yaparsaniz HTML ozelligi kapatýlýr.
set tghtmlrefresh 0

# Web sayfasi kaydedilirken kullanilacak fontlar.
set tghtmlfont "verdana,helvetica,arial"


# En fazla verilecek ipucu sayýsý
set tgmaxhint 3

# ipucu gosterilsin mi (1) evet (0) hayir?
set tgalwaysshowq 1

# Sorular Buyuk harfle yazilsin mi(1)evet (0) hayir?
set tgcapsquestion 0

# Cevaplar büyük harfle yazilsin mi(1) evet (0) hayir?
set tgcapsanswer 1

# ipuclari buyuk harfle yazilsinmi (1)evet (0) hayir?
set tgcapshint 0

# en az kaç soru üst üste bilindiðinde cevap serisi yakaladý olarak kayýt edilecek
set tgstreakmin 5

#belirli sayýda soru bilinmezse oyun kapatýlacak. !skip komutu hadil deðil. 0 disable yapar.
set tgmaxmissed 0

# ipucu karakteri
set tghintchar "*"

#verilen ipuclarý arasýndaki süre. saniye cinsinden.
set tgtimehint 9

#bir sonraki soruyu sorma süresi. saniye cinsinden.
set tgtimenext 10

#tebrik mesajlarý
set tgcongrats [list "Harikasin" "Bravo bildin" "Iyi hareket" "Tebrikler" "Iste oyun bu" "Guzel gidiyorsun" "Oyun nasil oynanir goster" "Bravo" "Heytt Be Helal" "Vay Beee Muhtesemsin Devam Devam" "Oyun Nasýl Oynanýr Goster Bu VatandasLara" "Iyi Hareket Ama Fazla Hareket Yapma Atarim Kafayý" "Hýmmm Sen Bu Kafa Ile Fazla Yasamassin En Iyiisi Git Uyu" "Bravvvvooo Cok Guzelsin BenimLe CikarMisin" "Guzel gidiyorsun Allah Bilir Besiktaslisin
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
" "Iste oyuN Bu Bastir"]

#doðru cevap verilemediðinde gösterilecek mesajlar.
set tgnobodygotit [list "Dogru cevabi bilen cikmadi." "Evde kimse varmi?" "Cevap yok!" "Bu sorular cokmu zor geldi?" "Acaba burda yalniz miyim?" "Boyle giderse kimse puan alamayacak!" "Canlanin biraz" "Sizde Is Yok Calýsýn Biraz" "Bu Soruyu Bilseydiniz BenLe Cýkardýnýz" "Daha Cok Calýsmalýsýnýz"]

#bir sonraki soru bildirim mesajý
set tgtrythenextone [list "Bakalim sonrakini bilecekmisiniz..." "Bir sonraki icin hazirlanin..." "Belki bir sonrakini bilirsiniz..." "Bakalim bunu bulabilecekmisiniz..." "Sonraki soru geliyor..."]

# Will the bot calculate the time it took to get the correct
# answer (1) or not (0)? (requires TCL 8.3 or higher).
set tgtimeanswer 1

# Sorunun Cevabi gosterilsin mi? (1) evet (0) hayir?
set tgshowanswer 1

# Sorulan sorular her bilindiginde skor tablosu gosterilsin mi ?
set tgshowallscores 1

#bold mesaj kullanýmý açýk/kapalý ayarý. 0 kapalý için
set tgusebold 0

# Mesaj sistemi ne olarak kullanilsin /msg ise 1 /notice ise 0
set tgpriv2msg 1

#yardým komutu
set tgcmdhelp "help"

#oyun baþlatma komutu
set tgcmdstart "basla"

#oyunu kimlerin baþlatabileceðini belirleyen bayrak(flag) ayarlarý. sadece bota kayýtlý oplar için o|o yazýn.
#bütün kullanýcýlar için -|- yazýn.
set tgflagsstart "-|-"

#oyunu durdurma komutu
set tgcmdstop "x1"

#oyunu kimlerin durdurabileceðini belirleyen bayrak(flag) ayarlarý. sadece bota kayýtlý oplar için o|o yazýn.
#bütün kullanýcýlar için -|- yazýn.
set tgflagsstop "o|o"

# ipucu komutu
set tgcmdhint "ipucu"

#oyunuda kimlerin ipucu komutunu kullanabileceðini belirleyen bayrak(flag) ayarlarý.
# sadece bota kayýtlý oplar için o|o yazýn. bütün kullanýcýlar için -|- yazýn.
set tgflagshint "-|-"

# Disable the !hint command x seconds after someone uses it. This
# prevents accidental double hints if two people use the command in
# quick succession.
set tgtempnohint 10

#soru atlatma komutu
set tgcmdskip "!atla"

#oyunuda kimlerin !skip komutunu kullanabileceðini belirleyen bayrak(flag) ayarlarý.
# sadece bota kayýtlý oplar için o|o yazýn. bütün kullanýcýlar için -|- yazýn.
set tgflagsskip "n|n"

# top10 komudu.
set tgcmdtop10 "top10"

#oyunuda kimlerin !top10 komutunu kullanabileceðini belirleyen bayrak(flag) ayarlarý.
# sadece bota kayýtlý oplar için o|o yazýn. bütün kullanýcýlar için -|- yazýn.
set tgflagstop10 "-|-"

# skor temizleme komutu
set tgcmdreset "sýfýrla"

#oyunuda kimlerin temizle komutunu kullanabileceðini belirleyen bayrak(flag) ayarlarý.
# sadece bota kayýtlý oplar için o|o yazýn. bot yöneticileri için n|n yazýn.
set tgflagsreset "n|n"

#skor tablosunu sifirlamak icin bota login oldugunu sifreyi kullanin
set tgresetreqpw 1

#skor öðrenme komutu
set tgcmdlookup "skor"

#baþkasýnýn skorunu öðrenme komutu
set tgcmdtarget "hedef"

#kata bildirme komutu
set tgcmderror "hata"

# kurallar komudu.
set tgcmdrules "kural"

# Kanal kurallarý.
set tgrules "Reklam, Tekrar, Flood, Küfür ve bezeri tutumsuz hareketlerde bulunmak yasaktir. Iyi Sanslar. :-)"

# Number of minutes between reminders of how to report errors.
set tgerrremindtime 15

# COLOURS
# The colour codes used are the same as those used by mIRC:
# 00:white 01:black 02:dark blue 03:dark green
# 04:red 05:brown 06:purple 07:orange
# 08:yellow 09:light green 10:turquoise 11:cyan
# 12:light blue 13:magenta 14:dark grey 15:light grey
#
# Always specify colour codes as two digits, i.e. use "01" for
# black, not "1".
# You can specify a background colour using "00,04" (white text
# on red background).
# To disable a colour, use "".
# Note that disabling some colours but not others may yield
# unexpected results.

set tgcolourstart "04" ;#Oyun baslatildi.
set tgcolourstop "04" ;#Oyun durduruldu.
set tgcolourskip "10" ;#Soru gecildi.
set tgcolourerr "12" ;#Nasil hata bildirilir.
set tgcolourmiss "12" ;#Kimse soruyu bilemedi.
set tgcolourqhead "04" ;#Soru basligi.
set tgcolourqbody "02" ;#Sorunun kendisi.
set tgcolourhint "03" ;#Ipucu.
set tgcolourstrk "12" ;#Arka arkaya bilme rekorunda olan kisi.
set tgcolourscr1 "10" ;#1.Siradaki kisi.
set tgcolourscr2 "06" ;#2.Siradaki kisi.
set tgcolourscr3 "04" ;#3.Siradaki kisi.
set tgcolourrset "04" ;#Skorlar Resetlendi.
set tgcolourstend "12" ;#Arka arkaya bilme rekoru bitti.
set tgcolourmisc1 "12" ;#Ara reng 1.
set tgcolourmisc2 "02" ;#Ara reng 2.




# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
# #
# Any editing done beyond this point is done at your own risk! #
# #
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
#Misc checks & var initialisations
set tgver "1.3.4"
set tgrel "release"
if {[info tclversion]<8.2} {
putlog "\002[file tail [info script]]\002 failed to load: in order to use this script, eggdrop needs to be compiled to use tcl 8.2 or higher (recommended: latest stable version)."
return
}
if {$tgtimeanswer==1&&[info tclversion]<8.3} {
putlog "\002[file tail [info script]]\002 warning: timing of answers has been automatically disabled. this feature requires tcl 8.3 or higher."
set tgtimeanswer 0
}
if {![info exists alltools_loaded]||$allt_version<205} {
putlog "\002[file tail [info script]]\002 failed to load: please load alltools.tcl v1.14 or higher (available with eggdrop 1.6.13 or higher) before attempting to load this script."
return
}
if {[utimerexists tghtml]!=""} {killutimer $tghtmlrefreshtimer}
if {$tghtmlrefresh>0} {
set tghtmlrefreshtimer [utimer $tghtmlrefresh tghtml]
}
if {![file exists $tgqdb]} {
putlog "\002[file tail [info script]]\002 failed to load: $tgqdb does not exist."
return
}
if {[llength [split $tgchan]]!=1} {
putlog "\002[file tail [info script]]\002 failed to load: too many channels specified."
return
}
if {![info exists tgplaying]} {
set ctcp-version "${ctcp-version} (Trivia Soru Cevap botu) Düzenleyen: [Üye Olmadan Linkleri Göremezsiniz. Üye Olmak için TIKLAYIN...] )"
set tgplaying 0
}
if {![info exists tghintnum]} {set tghintnum 0}
if {![info exists tgmissed]} {set tgmissed 0}

#Binds
bind pubm $tgflagsstart "$tgchan %$tgcmdstart" tgstart
bind pubm $tgflagsstop "$tgchan %$tgcmdstop" tgstop
proc tgbindhintcmd {} {
global tgflagshint tgcmdhint
bind pubm $tgflagshint "$::tgchan %$tgcmdhint" tgforcehint
}
proc tgunbindhintcmd {} {
global tgflagshint tgcmdhint
unbind pubm $tgflagshint "$::tgchan %$tgcmdhint" tgforcehint
}
tgbindhintcmd
bind pubm $tgflagsskip "$tgchan %$tgcmdskip" tgskip
bind pubm $tgflagstop10 "$tgchan %$tgcmdtop10" tgshowtop10
bind join -|- "$tgchan *" tgjoinmsg
bind msg - $tgcmdhelp tggivehelp
bind msg - $tgcmdlookup tgscorelookup
bind msg - $tgcmdtarget tgtargetlookup
bind msg - $tgcmderror tgerror
bind msg - $tgcmdrules tgrulesmsg
bind msg $tgflagsreset "$tgcmdreset" tgresetscores
bind kick - "$tgchan $botnick" tgbotgotkicked
bind evnt - disconnect-server tgbotgotdisconnected

#starts the game if it isn't running.
proc tgstart {nick host hand chan text} {
global tgplaying tgstreak tgchan tgerrremindtime tgerrremindtimer tgmissed
if {[strlwr $tgchan]==[strlwr $chan]} {
if {$tgplaying==0} {
tggamemsg "[tgcolstart]Soru botu \002$nick\002 taraf&#253;ndan ba&#254;lat&#253;ld&#253;!"
tgnextq
set tgplaying 1
set tgstreak 0
set tgmissed 0
set tgerrremindtimer [timer $tgerrremindtime tgerrremind]
}
}
}

#stops the game if it's running.
proc tgstop {nick host hand chan text} {
global tghinttimer tgnextqtimer tgplaying tgchan tgcurrentanswer tgstreak tgstreakmin
global tgerrremindtimer tgrebindhinttimer
if {[strlwr $tgchan]==[strlwr $chan]} {
if {$tgplaying==1} {
tggamemsg "[tgcolstop]Soru botu \002$nick\002 taraf&#253;ndan durduruldu!"
if {$tgstreakmin>0&&[lindex [split $tgstreak ,] 1]>=$tgstreakmin} { tgstreakend }
set tgstreak 0
set tgplaying 0
catch {unbind pubm -|- "$tgchan *" tgcheckanswer}
if {[utimerexists tghint]!=""} {killutimer $tghinttimer}
if {[utimerexists tgnextq]!=""} {killutimer $tgnextqtimer}
if {[timerexists tgerrremind]!=""} {killtimer $tgerrremindtimer}
if {[utimerexists tgrebindhinttimer]!=""} {killtimer $tgrebindhinttimer}
}
}
}

#gives a hint if there is currently a question to answer.
proc tgforcehint {nick host hand chan text} {
global tghinttimer tgnextqtimer tgplaying tgchan tgcurrentanswer tgstreak tgstreakmin
global tgtempnohint tgmaxhintcurrent tghintnum tgrebindhinttimer tgtempnohint
if {[strlwr $tgchan]==[strlwr $chan]} {
if {$tgplaying==1&&[utimerexists tghint]!=""} {
killutimer $tghinttimer
tghint
tgunbindhintcmd
if {$tghintnum<$tgmaxhintcurrent} {
set tgrebindhinttimer [utimer $tgtempnohint tgbindhintcmd]
}
}
}
}

#skips the current question if one has been asked.
proc tgskip {nick host hand chan text} {
global tghinttimer tgnextqtimer tgplaying tgchan tgcurrentanswer tgstreak
global tgstreakmin tgtimenext tgrebindhinttimer
if {[strlwr $tgchan]==[strlwr $chan]} {
if {$tgplaying==1&&[utimerexists tghint]!=""} {
tggamemsg "[tgcolskip]Soru [tgcolmisc2]$nick'in[tgcolskip] iste&#240;i üzerine geçildi..."
if {$tgstreakmin>0&&[lindex [split $tgstreak ,] 1]>=$tgstreakmin&&[strlwr [lindex [split $tgstreak ,] 0]]==[strlwr $nick]} {
tgstreakend
set tgstreak 0
}
catch {unbind pubm -|- "$tgchan *" tgcheckanswer}
killutimer $tghinttimer
if {[utimerexists tgrebindhinttimer]!=""} {killtimer $tgrebindhinttimer}
set tgnextqtimer [utimer $tgtimenext tgnextq]
}
}
}

#reminds channel how to report errors in questions/answers
proc tgerrremind {} {
global tgerrremindtimer tgerrremindtime botnick tgcmderror
tggamemsg "[tgcolerr]Hat&#253;rlatma: Soru/Cevap hatalar&#253;n&#253; lütfen bize bildirin. Hatalar&#253; bize bildirmek için \002/msg $botnick $tgcmderror <sorunumaras&#253;> \[Aç&#253;klama\]\002 &#254;eklinde kullan&#253;n&#253;z."
set tgerrremindtimer [timer $tgerrremindtime tgerrremind]
}

#bot got kicked. stop the game.
proc tgbotgotkicked {nick host hand chan targ text} {
tgquietstop
}

#bot got disconnected. stop the game.
proc tgbotgotdisconnected {disconnect-server} {
tgquietstop
}

#stops the game without telling the channel.
proc tgquietstop {} {
global tgplaying tgstreak tgchan tgcurrentanswer tghinttimer tgnextqtimer tgerrremindtimer
global tgrebindhinttimer
if {$tgplaying==1} {
set tgstreak 0
set tgplaying 0
catch {unbind pubm -|- "$tgchan *" tgcheckanswer}
if {[utimerexists tghint]!=""} {killutimer $tghinttimer}
if {[utimerexists tgnextq]!=""} {killutimer $tgnextqtimer}
if {[timerexists tgerrremind]!=""} {killtimer $tgerrremindtimer}
if {[utimerexists tgrebindhinttimer]!=""} {killtimer $tgrebindhinttimer}
}
}

#reads the question database.
proc tgreadqdb {} {
global tgqdb tgquestionstotal tgquestionslist
set tgquestionstotal 0
set tgquestionslist ""
set qfile [open $tgqdb r]
set tgquestionslist [split [read -nonewline $qfile] "\n"]
set tgquestionstotal [llength $tgquestionslist]
close $qfile
}

#selects the next question.
proc tgnextq {} {
global tgqdb tgcurrentquestion tgcurrentanswer tgquestionnumber
global tgquestionstotal tghintnum tgchan tgquestionslist tgqdbsep tgqdbquestionfirst
global tgcapsquestion tgcapsanswer
tgreadqdb
set tgcurrentquestion ""
set tgcurrentanswer ""
while {$tgcurrentquestion == ""} {
set tgquestionnumber [rand [llength $tgquestionslist]]
set tgquestionselected [lindex $tgquestionslist $tgquestionnumber]
set tgcurrentquestion [lindex [split $tgquestionselected $tgqdbsep] [expr $tgqdbquestionfirst^1]]
if {$tgcapsquestion==1} {
set tgcurrentquestion [strupr $tgcurrentquestion]
}
set tgcurrentanswer [string trim [lindex [split $tgquestionselected $tgqdbsep] $tgqdbquestionfirst]]
if {$tgcapsanswer==1} {
set tgcurrentanswer [strupr $tgcurrentanswer]
}
}
unset tghintnum
tghint
bind pubm -|- "$tgchan *" tgcheckanswer
return
}

#shows timed hints.
proc tghint {} {
global tgmaxhint tghintnum tgcurrentanswer tghinttimer tgchan
global tgtimehint tghintchar tgquestionnumber tgquestionstotal
global tgcurrentquestion tghintcharsused tgnextqtimer tgtimenext tgstreak tgstreakmin
global tgnobodygotit tgtrythenextone tgmissed tgmaxmissed tgcmdstart tgshowanswer
global tgtimestart tgtimeanswer tgalwaysshowq tgmaxhintcurrent tgtempnohint tgcapshint
if {[catch {incr tghintnum}]!=0} {
set tghintnum 0
regsub -all -- "\[^A-Za-z0-9\]" $tgcurrentanswer "" _hintchars
set tgmaxhintcurrent [expr [strlen $_hintchars]<=$tgmaxhint?[expr [strlen $_hintchars]-1]:$tgmaxhint]
catch {tgunbindhintcmd}
if {$tgmaxhintcurrent>0} {
set tgrebindhinttimer [utimer $tgtempnohint tgbindhintcmd]
}
}
if {$tghintnum >= [expr $tgmaxhintcurrent+1]} {
incr tgmissed
set _msg ""
append _msg "[tgcolmiss][lindex $tgnobodygotit [rand [llength $tgnobodygotit]]]"
if {$tgshowanswer==1} {
append _msg " Cevap [tgcolmisc2]$tgcurrentanswer[tgcolmiss]."
}
if {$tgmaxmissed>0&&$tgmissed>=$tgmaxmissed} {
append _msg " $tgmissed soru sordum ve cevap alamadim ve oyunu durduruyorum. Yeniden baslatmak için $tgcmdstart yazmal&#253;s&#253;n&#253;z."
tgquietstop
} else {
append _msg " [lindex $tgtrythenextone [rand [llength $tgtrythenextone]]]"
}
tggamemsg "[tgcolmiss]$_msg"
if {$tgstreakmin>0&&[lindex [split $tgstreak ,] 1]>=$tgstreakmin} { tgstreakend }
set tgstreak 0
catch {unbind pubm -|- "$tgchan *" tgcheckanswer}
if {$tgmaxmissed==0||$tgmissed<$tgmaxmissed} {
set tgnextqtimer [utimer $tgtimenext tgnextq]
}
return
} elseif {$tghintnum == 0} {
set i 0
set _hint {}
set tghintcharsused {}
foreach word [split $tgcurrentanswer] {
regsub -all -- "\[A-Za-z0-9\]" $word $tghintchar _current
lappend _hint $_current
}
if {$tgtimeanswer==1} {
set tgtimestart [clock clicks -milliseconds]
}
} elseif {$tghintnum == 1} {
set i 0
set _hint {}
while {$i<[llength [split $tgcurrentanswer]]} {
set _word [lindex [split $tgcurrentanswer] $i]
set j 0
set _newword {}
while {$j<[strlen $_word]} {
if {$j==0} {
append _newword [stridx $_word $j]
lappend tghintcharsused $i,$j
} else {
if {[string is alnum [stridx $_word $j]]} {
append _newword $tghintchar
} else {
append _newword [stridx $_word $j]
lappend tghintcharsused $i,$j
}
}
incr j
}
lappend _hint $_newword
incr i
}
} else {
set i 0
set _hint {}
while {$i<[llength [split $tgcurrentanswer]]} {
set _word [lindex [split $tgcurrentanswer] $i]
set j 0
set _newword {}
set _selected [rand [strlen $_word]]
regsub -all -- "\[^A-Za-z0-9\]" $_word "" _wordalnum
if {[strlen $_wordalnum]>=$tghintnum} {
while {[lsearch $tghintcharsused $i,$_selected]!=-1||[string is alnum [stridx $_word $_selected]]==0} {
set _selected [rand [strlen $_word]]
}
}
lappend tghintcharsused $i,$_selected
while {$j<[strlen $_word]} {
if {[lsearch $tghintcharsused $i,$j]!=-1||[string is alnum [stridx $_word $j]]==0} {
append _newword [stridx $_word $j]
} else {
if {[string is alnum [stridx $_word $j]]} {
append _newword $tghintchar
}
}
incr j
}
lappend _hint $_newword
incr i
}
}
if {$tgcapshint==1} {
set _hint [strupr $_hint]
}
tggamemsg "[tgcolqhead]===== SoruNo [expr $tgquestionnumber+1]/$tgquestionstotal [expr $tghintnum?"(Ipucu $tghintnum/$tgmaxhintcurrent)":""] ====="
if {$tgalwaysshowq==1||$tghintnum==0} {
tggamemsg "[tgcolqbody]$tgcurrentquestion"
}
tggamemsg "[tgcolhint]&#221;pucu: [join $_hint]"
set tghinttimer [utimer $tgtimehint tghint]
}

#triggered when someone uses !top10 command
proc tgshowtop10 {nick host hand chan text} {
global tgscores tgchan tgscorestotal
if {[strlwr $chan]==[strlwr $tgchan]} {
tggetscores
if {$tgscorestotal>0} {
if {$tgscorestotal>9} {
set _max 9
} else {
set _max [expr $tgscorestotal-1]
}
set i 0
while {$i<=$_max} {
set _item [lindex $tgscores $i]
set _nick [join [lindex [split $_item ,] 2]]
set _score [join [lindex [split $_item ,] 0]]
if {$i==0} {
append _scores "[tgcolscr1]$_nick $_score"
} elseif {$i==1} {
append _scores ", [tgcolscr2]$_nick $_score"
} elseif {$i==2} {
append _scores ", [tgcolscr3]$_nick $_score"
} else {
append _scores ", [tgcolmisc1]$_nick $_score"
}
incr i
}
tggamemsg "[tgcolmisc1]Top 10: $_scores"
} else {
tggamemsg "[tgcolmisc1]Skor tablosu bo&#254;."
}
}
}

#checks if anyone has said the correct answer on channel.
proc tgcheckanswer {nick host hand chan text} {
global tgcurrentanswer
if {[strlwr $tgcurrentanswer] == [tgstripcodes [strlwr [string trim $text]]]} {
tgcorrectanswer $nick
}
}

#triggered when someone says the correct answer.
proc tgcorrectanswer {nick} {
global tgcurrentanswer tghinttimer tgtimenext tgchan tgnextqtimer tgstreak tgstreakmin
global tgscoresbyname tgranksbyname tgranksbynum tgcongrats tgscorestotal tgmissed
global tgtimestart tgshowallscores tgrealnames tgscoresbyrank tgtimeanswer
tggetscores
if {![info exists tgranksbyname([strlwr $nick])]} {
set _oldrank 0
} else {
set _oldrank $tgranksbyname([strlwr $nick])
}
tgincrscore $nick
tggetscores
set _newrank $tgranksbyname([strlwr $nick])
set _timetoanswer ""
if {$tgtimeanswer==1} {
set _timetoanswer [expr [expr [clock clicks -milliseconds]-$tgtimestart]/1000.00]
}
set _msg "[tgcolmisc1][lindex $tgcongrats [rand [llength $tgcongrats]]] [tgcolmisc2]$nick[tgcolmisc1]! Do&#240;ru Cevap [tgcolmisc2]$tgcurrentanswer[tgcolmisc1].[expr $tgtimeanswer==1?" Soruyu [tgcolmisc2]$_timetoanswer[tgcolmisc1] Saniyede Bildiniz.":""]"
if {$_newrank<$_oldrank} {
if {$_newrank==1} {
append _msg " &#222;u an birincisiniz!"
} else {
if {$tgshowallscores==0} {
append _msg " Seviyeniz yükseldi.!"
} else {
append _msg " [tgcolmisc2]$tgscorestotal[tgcolmisc1] ki&#254;i içinde [tgcolmisc2][ordnumber $tgranksbyname([strlwr $nick])][tgcolmisc1] s&#253;radas&#253;n&#253;z. [tgcolmisc2]$tgrealnames($tgranksbynum([expr $_newrank-1]))[tgcolmisc1] [tgcolmisc2]$tgscoresbyrank([expr $_newrank-1])[tgcolmisc1] puanla hemen önünüzde."

}
}
}
tggamemsg "$_msg"
if {$tgstreak!=0} {
if {[lindex [split $tgstreak ,] 0]==[strlwr $nick]} {
set tgstreak [strlwr $nick],[expr [lindex [split $tgstreak ,] 1]+1]
if {$tgstreakmin>0&&[lindex [split $tgstreak ,] 1]>=$tgstreakmin} {
tggamemsg "[tgcolstrk][tgcolmisc2]$nick[tgcolstrk] Cevap serisi yakalad&#253;!! [tgcolmisc2][lindex [split $tgstreak ,] 1] [tgcolstrk]tane soruyu ust uste bildi!"
}
} else {
if {$tgstreakmin>0&&[lindex [split $tgstreak ,] 1]>=$tgstreakmin} { tgstreakend }
set tgstreak [strlwr $nick],1
}
} else {
set tgstreak [strlwr $nick],1
}
set tgmissed 0
tgshowscores $nick
catch {unbind pubm -|- "$tgchan *" tgcheckanswer}
killutimer $tghinttimer
set tgnextqtimer [utimer $tgtimenext tgnextq]
}

#read current scores from file, sort and store in variable.
proc tggetscores {} {
global tgscf tgscorestotal tgscores tgscoresbyname tgranksbyname tgranksbynum
global tgrealnames tgscoresbyrank
if {[file exists $tgscf]&&[file size $tgscf]>2} {
set _sfile [open $tgscf r]
set tgscores [lsort -dict -decreasing [split [gets $_sfile]]]
close $_sfile
set tgscorestotal [llength $tgscores]
} else {
set tgscores ""
set tgscorestotal 0
}
if {[info exists tgscoresbyname]} {unset tgscoresbyname}
if {[info exists tgranksbyname]} {unset tgranksbyname}
if {[info exists tgrealnames]} {unset tgrealnames}
if {[info exists tgranksbynum]} {unset tgranksbynum}
set i 0
while {$i<[llength $tgscores]} {
set _item [lindex $tgscores $i]
set _nick [lindex [split $_item ,] 2]
set _lwrnick [lindex [split $_item ,] 3]
set _score [lindex [split $_item ,] 0]
set tgscoresbyname($_lwrnick) $_score
set tgrealnames($_lwrnick) $_nick
set tgranksbyname($_lwrnick) [expr $i+1]
set tgranksbynum([expr $i+1]) $_lwrnick
set tgscoresbyrank([expr $i+1]) $_score
incr i
}
return
}

#increment someone's score.
proc tgincrscore {who} {
global tgscores tgscf tgpointsperanswer tgscorestotal tgscoresbyname
tggetscores
if {$tgscorestotal>0} {
set i 0
if {![info exists tgscoresbyname([strlwr $who])]} {
append _newscores "1,[expr 1000000000000.0/[unixtime]],$who,[strlwr $who] "
}
while {$i<[llength $tgscores]} {
set _item [lindex $tgscores $i]
set _nick [lindex [split $_item ,] 2]
set _time [lindex [split $_item ,] 1]
set _score [lindex [split $_item ,] 0]
if {[strlwr $who]==[strlwr $_nick]} {
append _newscores "[expr $_score+$tgpointsperanswer],[expr 1000000000000.0/[unixtime]],$who,[strlwr $who][expr [expr [llength $tgscores]-$i]==1?"":"\ "]"
} else {
append _newscores "$_score,$_time,$_nick,[strlwr $_nick][expr [expr [llength $tgscores]-$i]==1?"":"\ "]"
}
incr i
}
} else {
append _newscores "1,[expr 1000000000000.0/[unixtime]],$who,[strlwr $who]"
}
set _sfile [open $tgscf w]
puts $_sfile "$_newscores"
close $_sfile
return
}

#shows the current scores on channel.
proc tgshowscores {nick} {
global tgscores tgchan tgscorestotal tgshowallscores tgranksbyname tgranksbynum
global tgscoresbyname tgrealnames tgscoresbyrank
tggetscores
set i 0
if {$tgshowallscores} {
while {$i<[llength $tgscores]} {
set _item [lindex $tgscores $i]
set _nick [lindex [split $_item ,] 2]
set _score [lindex [split $_item ,] 0]
if {$i==0} {
append _scores "[tgcolscr1]$_nick $_score"
} elseif {$i==1} {
append _scores ", [tgcolscr2]$_nick $_score"
} elseif {$i==2} {
append _scores ", [tgcolscr3]$_nick $_score"
} elseif {[onchan $_nick $tgchan]} {
append _scores ", [tgcolmisc1]$_nick $_score"
}
incr i
}
tggamemsg "[tgcolmisc1]Skorlar: $_scores"
} else {
if {$tgranksbyname([strlwr $nick])==1} {
set _tgt "."
} else {
set _tgt ", behind [tgcolmisc2]$tgrealnames($tgranksbynum([expr $tgranksbyname([strlwr $nick])-1]))[tgcolmisc1] with [tgcolmisc2]$tgscoresbyrank([expr $tgranksbyname([strlwr $nick])-1])[tgcolmisc1]."
}
tggamemsg "[tgcolmisc2]$nick [tgcolmisc1]now has [tgcolmisc2]$tgscoresbyname([strlwr $nick]) [tgcolmisc1][expr $tgscoresbyname([strlwr $nick])==1?"point":"points"] and is ranked [tgcolmisc2][ordnumber $tgranksbyname([strlwr $nick])] [tgcolmisc1]of [tgcolmisc2]$tgscorestotal[tgcolmisc1]$_tgt"
}
}

#reset current scores.
proc tgresetscores {nick host hand text} {
global tgscf tgscorestotal tgscores tgplaying tgresetreqpw
if {($tgresetreqpw==1 && [passwdok $hand $text]) || $tgresetreqpw==0} {
if {[file exists $tgscf]&&[file size $tgscf]>2} {
set _sfile [open $tgscf w]
puts $_sfile ""
close $_sfile
set tgscores ""
set tgscorestotal 0
}
tggamemsg "[tgcolrset]===== Skor tablosu \002$nick\002 taraf&#253;ndan silindi! ====="
}
}

#triggered when a winning streak ends.
proc tgstreakend {} {
global tgstreak tgrealnames
tggamemsg "[tgcolstend]&#221;yi gidiyordun [tgcolmisc2]$tgrealnames([lindex [split $tgstreak ,] 0])[tgcolstend] iyi bir cevap serisi yakalamisti"
return
}

#triggered when someone joins trivia chan.
#triggered when someone joins trivia chan.
proc tgjoinmsg {nick host hand chan} {
global botnick tgplaying tgcmdhelp tgcmdstart tgflagsstart tgcmdstop tgflagsstop tgchan
global tgscorelookupjoin tgscoresbyname tgranksbyname tgscorestotal tgranksbynum tgrealnames
global tgscoresbyrank tgscores
tggetscores
if {$nick != $botnick} {
set _msg ""
append _notice "Soru Cevap Oyun kanal&#253;na ho&#254; geldiniz. Oyun &#254;u anda"
if {$tgplaying==1} {
append _notice " \002Aç&#253;k\002."
} else {
append _notice " \002Kapal&#253;\002."
}
if {[matchattr $hand $tgflagsstart $tgchan]&&$tgplaying==0} {
append _notice " Oyunu ba&#254;latmak için, \002$tgcmdstart\002 yazmal&#253;s&#253;n&#253;z $tgchan kanal&#253;na"
}
append _notice " Oyun hakk&#253;nda yard&#253;ma ihtiyac&#253;n&#253;z olursa \002/msg $botnick [strupr $tgcmdhelp]\002 yazman&#253;z yeterli olacakt&#253;r! "
[tgpriv] $nick "$_msg"

if {![info exists tgscoresbyname([strlwr $nick])]} {
tggamemsg "[tgcolmisc1]Ho&#254; geldin [tgcolmisc2]$nick [tgcolmisc1]! Oyuncular aras&#253;nda ad&#253;n&#253;z yok. Aram&#253;za kat&#253;lmak için sorular&#253; cevaplaman&#253;n tam zaman&#253;.!!! "
} else {
tggamemsg "[tgcolmisc1]Selam [tgcolmisc2]$nick ![tgcolmisc1] Toplam -> [tgcolmisc2]$tgscoresbyname([strlwr $nick]) [tgcolmisc1]<- [expr $tgscoresbyname([strlwr $nick])==1?"puan":"puan"]&#253;n&#253;z var ! Durumunuz [tgcolmisc2][ordnumber $tgranksbyname([strlwr $nick])] [tgcolmisc1]S&#253;radas&#253;n&#253;z. [tgcolmisc2]$tgscorestotal[tgcolmisc1] ki&#254;i aras&#253;nda, [tgcolmisc2]$tgrealnames($tgranksbynum([expr $tgranksbyname([strlwr $nick])-1]))[tgcolmisc1] ise [tgcolmisc2]$tgscoresbyrank([expr $tgranksbyname([strlwr $nick])-1])[tgcolmisc1]. puanla önünüzde"

}
set i 0

while {$i<[llength $tgscores]} {
set _item [lindex $tgscores $i]
set _nick [lindex [split $_item ,] 2]
set _score [lindex [split $_item ,] 0]
if {$i<=9&&$nick==$_nick&&[botisop $tgchan]} {
putserv "MODE $tgchan +v $nick"
putserv "PRIVMSG $tgchan :[tgcolmisc1] Wo
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
Yar&#253;&#254;mac&#253;lar aras&#253;nda ilk 10 ki&#254;i aras&#253;nda."
}
incr i
}
}
}
#triggered when someone /msgs the bot with the score lookup command.
proc tgscorelookup {nick host hand text} {
global tgscoresbyname tgranksbyname tgscorestotal tgrealnames
if {$text==""} { set text $nick } else { set text [lindex [split $text] 0] }
tggetscores
if {![info exists tgscoresbyname([strlwr $text])]} {
if {[strlwr $text]==[strlwr $nick]} {
set _who "[tgcolmisc1]Nickinizin"
} else {
set _who "[tgcolmisc2]$text [tgcolmisc1]"
}
[tgpriv] $nick "[tgbold]$_who [tgcolmisc1]skor tablosunda yok."
} else {
if {[strlwr $text]==[strlwr $nick]} {
set _who "[tgcolmisc1]Nickinizin"
} else {
set _who "[tgcolmisc2]$tgrealnames([strlwr $text]) [tgcolmisc1]"
}
[tgpriv] $nick "[tgbold]$_who [tgcolmisc2]$tgscoresbyname([strlwr $text])[tgcolmisc1] puan&#253; var, [tgcolmisc2]$tgscorestotal[tgcolmisc1] [tgcolmisc1]ki&#254;i içinde [tgcolmisc2][ordnumber $tgranksbyname([strlwr $text])] s&#253;rada"
}
}

#triggered when someone /msgs the bot with the target lookup command.
proc tgtargetlookup {nick host hand text} {
global tgscoresbyname tgranksbyname tgscorestotal tgranksbynum tgrealnames
tggetscores
if {![info exists tgscoresbyname([strlwr $nick])]} {
[tgpriv] $nick "[tgbold][tgcolmisc1]Skor tablosunda yer alm&#253;yorsunuz."
} elseif {$tgranksbyname([strlwr $nick])==1} {
[tgpriv] $nick "[tgbold][tgcolmisc1]Birinci s&#253;radas&#253;n&#253;z!"
} else {
[tgpriv] $nick "[tgbold][tgcolmisc1]Toplam puan&#253;n&#253;z [tgcolmisc2]$tgscoresbyname([strlwr $nick])[tgcolmisc1]. Hemen önünüzde [tgcolmisc2]$tgrealnames($tgranksbynum([expr $tgranksbyname([strlwr $nick])-1])) [tgcolmisc1] puanla [tgcolmisc2]$tgscoresbyname($tgranksbynum([expr $tgranksbyname([strlwr $nick])-1]))[tgcolmisc1], s&#253;rada [tgcolmisc2][ordnumber [expr $tgranksbyname([strlwr $nick])-1]] [tgcolmisc2]$tgscorestotal[tgcolmisc1] [tgcolmisc1] ki&#254;i aras&#253;nda."
}
}

#triggered when someone /msgs the bot with the error reporting command.
proc tgerror {nick host hand text} {
global tgquestionstotal tgquestionslist tgerrmethod tgerrfil tgerremail tgerrmailtmp
if {$text==""||![string is int [lindex [split $text] 0]]} {
[tgpriv] $nick "[tgbold][tgcolmisc1]Soru numaras&#253; girmediniz."
return
}
tgreadqdb
set _qnum [lindex [split $text] 0]
if {$_qnum>$tgquestionstotal} {
[tgpriv] $nick "[tgbold][tgcolmisc1]Bu numaraya ait soru bulunamad&#253;."
return
}
set _qques [lindex [split [lindex $tgquestionslist [expr $_qnum-1]] |] 1]
set _qans [lindex [split [lindex $tgquestionslist [expr $_qnum-1]] |] 0]
set _desc [join [lrange [split $text] 1 end]]
if {$_desc==""} { set _desc "Bu hata ile ilgili daha fazla bilgi yok." }
if {$tgerrmethod==1} {
set _fname $tgerrmailtmp\trivia[rand 100000].tmp
set _file [open $_fname w]
} else {
set _file [open $tgerrfil a]
}
puts $_file ""
puts $_file "Error report generated [strftime %A,\ %d\ %B\ %Y\ @\ %H:%M:%S]"
puts $_file "raporu bildiren:\t$nick!$host"
puts $_file "SoruNo #:\t$_qnum"
puts $_file "Soru:\t$_qques"
puts $_file "Cevap:\t\t$_qans"
puts $_file "Mesaj:\t$_desc"
puts $_file "------------------------------"
close $_file
if {$tgerrmethod==1} {
exec mail -s "trivia.tcl error report from $nick" $tgerremail < $_fname
file delete $_fname
[tgpriv] $nick "[tgbold][tgcolmisc1]Te&#254;ekkürler! hatal&#253; soru e-mail yolu ile yetkililere ulastirilacaktir."
} else {
[tgpriv] $nick "[tgbold][tgcolmisc1]Te&#254;ekkürler! hatal&#253; soru kaydedildi ve en k&#253;sa zamanda yetkililere bildirilecektir."
}
}

#triggered when someone /msgs the bot with the rules command.
proc tgrulesmsg {nick host hand text} {
global tgrules
[tgpriv] $nick "Oyun kuralar&#253;: $tgrules"
}

#triggered when someone /msgs the bot with the help command.
proc tggivehelp {nick host hand {text ""}} {
global botnick tgcmdlookup tgcmdhelp tgcmdstart tgcmdstop tgchan tgflagsstop
global tgcmdstop tgflagshint tgcmdhint tgflagsskip tgcmdskip tgflagsreset tgcmdreset
global tgcmdtarget tgcmderror tgcmdrules tgflagsstart
if {$text==""} {
[tgpriv] $nick "komutlar hakk&#253;nda yard&#253;m almak için:"
[tgpriv] $nick "/MSG $botnick <komut> yazmal&#253;s&#253;n&#253;z"
[tgpriv] $nick " \002[strupr $tgcmdrules]\002"
[tgpriv] $nick " -- Kanal kurallar&#253;n&#253; listelemek için."
[tgpriv] $nick " \002[strupr $tgcmdlookup]\002 \[nick\]"
[tgpriv] $nick " -- Belirtilen \[nick\] sirasini ve skorunu verir"
[tgpriv] $nick " Eger bir nick belirtilmezse sizin bilgileriniz gosterilecektir."
[tgpriv] $nick " \002[strupr $tgcmdtarget]\002"
[tgpriv] $nick " -- Belirtilen kullanici ile sizin aranizdaki"
[tgpriv] $nick " sira sayisini ve skor farkini gosterir."
[tgpriv] $nick " \002[strupr $tgcmderror]\002 <number> \[description\]"
[tgpriv] $nick " -- numarasi belirtilen sorunun varsa hatalarini bildirmenizi saglar"
[tgpriv] $nick " hata aciklamasi kismini yazmayabilirsiniz..."
if {[matchattr $hand $tgflagsreset $tgchan]} {
[tgpriv] $nick " \002[strupr $tgcmdreset]\002"
[tgpriv] $nick " -- Skor tablosunu siler."
}
[tgpriv] $nick "Kanalda kullanabileceginiz komutlarin listesini gormek icin"
[tgpriv] $nick "/MSG $botnick [strupr $tgcmdhelp] PUBCMDS yazin"
}
if {[strlwr $text]=="pubcmds"} {
[tgpriv] $nick "Kullanabilece&#240;iniz kanal komutlar&#253;:"
if {[matchattr $hand $tgflagsstart $tgchan]} {
[tgpriv] $nick " \002$tgcmdstart\002 -- Oyunu ba&#254;lat&#253;r."
}
if {[matchattr $hand $tgflagsstop $tgchan]} {
[tgpriv] $nick " \002$tgcmdstop\002 -- Oyunu durdurur."
}
if {[matchattr $hand $tgflagshint $tgchan]} {
[tgpriv] $nick " \002$tgcmdhint\002 -- Soru hakk&#253;nda ipucu verir."
}
if {[matchattr $hand $tgflagsskip $tgchan]} {
[tgpriv] $nick " \002$tgcmdskip\002 -- Soruyu atlar."
}
[tgpriv] $nick "komutlari listesi icin, /MSG $botnick [strupr $tgcmdhelp] yazin."
}
}

# Returns text without colour, bold, etc. control codes.
# This is a stripped down version of the proc in MC_8's mc.moretools.tcl.
proc tgstripcodes {text} {
regsub -all -- "\003(\[0-9\]\[0-9\]?(,\[0-9\]\[0-9\]?)?)?" $text "" text
set text "[string map -nocase [list \002 "" \017 "" \026 "" \037 ""] $text]"
return $text
}

proc tggamemsg {what} {
global tgchan
putquick "PRIVMSG $tgchan :[tgbold]$what"
}

proc tgbold {} {
global tgusebold
if {$tgusebold==1} { return "\002" }
}
proc tgcolstart {} {
global tgcolourstart
if {$tgcolourstart!=""} { return "\003$tgcolourstart" }
}
proc tgcolstop {} {
global tgcolourstop
if {$tgcolourstop!=""} { return "\003$tgcolourstop" }
}
proc tgcolskip {} {
global tgcolourskip
if {$tgcolourskip!=""} { return "\003$tgcolourskip" }
}
proc tgcolerr {} {
global tgcolourerr
if {$tgcolourerr!=""} { return "\003$tgcolourerr" }
}
proc tgcolmiss {} {
global tgcolourmiss
if {$tgcolourmiss!=""} { return "\003$tgcolourmiss" }
}
proc tgcolqhead {} {
global tgcolourqhead
if {$tgcolourqhead!=""} { return "\003$tgcolourqhead" }
}
proc tgcolqbody {} {
global tgcolourqbody
if {$tgcolourqbody!=""} { return "\003$tgcolourqbody" }
}
proc tgcolhint {} {
global tgcolourhint
if {$tgcolourhint!=""} { return "\003$tgcolourhint" }
}
proc tgcolstrk {} {
global tgcolourstrk
if {$tgcolourstrk!=""} { return "\003$tgcolourstrk" }
}
proc tgcolscr1 {} {
global tgcolourscr1
if {$tgcolourscr1!=""} { return "\003$tgcolourscr1" }
}
proc tgcolscr2 {} {
global tgcolourscr2
if {$tgcolourscr2!=""} { return "\003$tgcolourscr2" }
}
proc tgcolscr3 {} {
global tgcolourscr3
if {$tgcolourscr3!=""} { return "\003$tgcolourscr3" }
}
proc tgcolrset {} {
global tgcolourrset
if {$tgcolourrset!=""} { return "\003$tgcolourrset" }
}
proc tgcolstend {} {
global tgcolourstend
if {$tgcolourstend!=""} { return "\003$tgcolourstend" }
}
proc tgcolmisc1 {} {
global tgcolourmisc1
if {$tgcolourmisc1!=""} { return "\003$tgcolourmisc1" }
}
proc tgcolmisc2 {} {
global tgcolourmisc2
if {$tgcolourmisc2!=""} { return "\003$tgcolourmisc2" }
}
proc tgpriv {} {
global tgpriv2msg
if {$tgpriv2msg==1} { return "putmsg" } else { return "putnotc" }
}

#this generates an html file with all the people on the chan with
#their score, as well as a list of all scores, sorted by rank
proc tghtml {} {
global tgchan botnick tghtmlfile tghtmlrefresh server tgscoresbyname tgranksbyname
global tgscorestotal tgranksbyname tgrealnames tgscoresbyrank tgranksbynum tgplaying
global tgquestionstotal tghtmlrefreshtimer tghtmlfont
tggetscores
tgreadqdb
set _file [open $tghtmlfile~new w]
puts $_file "<!DOCTYPE HTML PUBLIC \"-/W3C/DTD HTML 4.01 Transitional/EN\">"
puts $_file "<html>"
puts $_file " <head>"
puts $_file " <title>$botnick's trivia channel: $tgchan on [lindex [split $server :] 0]</title>"
puts $_file " <meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\">"
puts $_file " <meta http-equiv=\"refresh\" content=\"$tghtmlrefresh\">"
puts $_file " <meta name=\"generator\" content=\"trivia.tcl script for eggdrop.
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
puts $_file " <style type=\"text/css\">"
puts $_file " <!--"
puts $_file " body,td{font-family:$tghtmlfont;font-size:13px;}"
puts $_file " a{text-decoration:none;color:#09f;}"
puts $_file " -->"
puts $_file " </style>"
puts $_file " </head>"
puts $_file " <body>"
puts $_file " <h1>$tgchan on [lindex [split $server :] 0]</h1>"
puts $_file " <hr size=\"1\" noshade>"
if {![onchan $botnick $tgchan]} {
puts $_file " <p>Hmmm... for some reason I'm not on $tgchan at the moment. Please try again later.</p>"
} else {
puts $_file " <p>Trivia game is currently <b>[expr $tgplaying==1?"on":"off"]</b>. There are <b>$tgquestionstotal</b> questions in the database."
puts $_file " <p>People on $tgchan right now:<br>"
puts $_file " <table width=\"50%\" border=\"1\" cellspacing=\"0\" cellpadding=\"0\"><tr><td><table width=\"100%\" cellspacing=\"3\" border=\"0\">"
puts $_file " <tr>"
puts $_file " <td><b>Nick</b></td>"
puts $_file " <td><b>Score</b></td>"
puts $_file " <td><b>Rank</b></td>"
puts $_file " <td><b>Idle</b></td>"
puts $_file " </tr>"
foreach nick [lsort [chanlist $tgchan]] {
puts $_file " <tr>"
puts $_file " <td>[expr [isop $nick $tgchan]?"@":""][expr [isvoice $nick $tgchan]?"+":""]$nick[expr [string match $nick $botnick]?" (that's me!)":""]</td>"
if {[info exists tgscoresbyname([strlwr $nick])]} {
puts $_file " <td>$tgscoresbyname([strlwr $nick])</td>"
} else {
puts $_file " <td>-</td>"
}
if {[info exists tgranksbyname([strlwr $nick])]} {
puts $_file " <td>$tgranksbyname([strlwr $nick])</td>"
} else {
puts $_file " <td>-</td>"
}
puts $_file " <td>[expr [getchanidle $nick $tgchan]>10?"[getchanidle $nick $tgchan]m":"-"]</td>"
puts $_file " </tr>"
}
puts $_file " </table></td></tr></table>"
}
if {$tgscorestotal>0} {
puts $_file " <p><small>There [expr $tgscorestotal==1?"is":"are"] currently <b>$tgscorestotal</b> [expr $tgscorestotal==1?"nick":"nicks"] in the score table:<br>"
set _rank 1
while {$_rank<=$tgscorestotal} {
puts $_file " <b>$_rank</b>. $tgrealnames($tgranksbynum($_rank)) $tgscoresbyrank($_rank)<br>"
incr _rank
}
} else {
puts $_file " <p><small>There are currently no nicks in the score table.<br>"
}
puts $_file " </small></p>"
puts $_file " <hr size=\"1\" noshade>"
puts $_file " <small>Generated on [strftime %A,\ %d\ %B\ %Y\ @\ %H:%M:%S] by <a href=\"
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
for <a href=\"
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.
puts $_file " This page is automatically updated (and refreshed if supported by your browser) every [expr $tghtmlrefresh==1?"second":"$tghtmlrefresh seconds"].</small>"
puts $_file " </body>"
puts $_file "</html>"
close $_file
file rename -force $tghtmlfile~new $tghtmlfile
set tghtmlrefreshtimer [utimer $tghtmlrefresh tghtml]
}

bU tcl benim eggdrop 1.6.13+laston UnixShell
calismiyor sizce tcl de mi problem var

 
Alıntı ile Cevapla

IRCForumlari.NET Reklamlar
sohbet odaları sohbet odaları Benimmekan Mobil Sohbet
Alt 27 Şubat 2011, 00:27   #2
Çevrimdışı
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
IF Ticaret Sayısı: (0)
IF Ticaret Yüzdesi:(%)
Cevap: eggdrop1.6.13+laston




kanala giriyor ama !basla !baslat yazinca calismiyor sebep nedir beyler yardime etti n acil pleas

 
Alıntı ile Cevapla

Alt 27 Şubat 2011, 03:09   #3
Çevrimdışı
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
IF Ticaret Sayısı: (0)
IF Ticaret Yüzdesi:(%)
Cevap: eggdrop1.6.13+laston




arkadaslar söyle birsey cikiyor islam.tcl failed to load:pleas load alltools.tcl.1.14 or higher (avaiblable with Eggdrop 1.6.13 or Higher)before attempting to load this script ne demek bu arkadaslar bu cikiyor lütfen acil yardim

 
Alıntı ile Cevapla

Alt 27 Şubat 2011, 14:53   #4
Çevrimdışı
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
IF Ticaret Sayısı: (0)
IF Ticaret Yüzdesi:(%)
Cevap: eggdrop1.6.13+laston




Eggdrop sürümünü yükselt.

 
Alıntı ile Cevapla

Alt 27 Şubat 2011, 15:55   #5
Çevrimdışı
Kullanıcıların profil bilgileri misafirlere kapatılmıştır.
IF Ticaret Sayısı: (0)
IF Ticaret Yüzdesi:(%)
Cevap: eggdrop1.6.13+laston




sorun hal etilmistir arkadaslar tskler altools tcl 1.4 yükledik calisti :
Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.

Bu forumdaki linkleri ve resimleri görebilmek için en az 25 mesajınız olması gerekir.

 
Alıntı ile Cevapla

Cevapla

Etiketler
eggdrop, laston


Konuyu Toplam 1 Üye okuyor. (0 Kayıtlı üye ve 1 Misafir)
 
Seçenekler
Stil

Yetkileriniz
Konu Acma Yetkiniz Yok
Cevap Yazma Yetkiniz Yok
Eklenti Yükleme Yetkiniz Yok
Mesajınızı Değiştirme Yetkiniz Yok

BB code is Açık
Smileler Açık
[IMG] Kodları Açık
HTML-Kodu Kapalı
Trackbacks are Kapalı
Pingbacks are Açık
Refbacks are Açık


Benzer Konular
Konu Konuyu Başlatan Forum Cevaplar Son Mesaj
Robby'nin eggdrop1.6.21 versionu. saywhat Eggdrop, NeoStats, BNC 0 29 Ağustos 2013 15:50
Eggdrop1.8 ile Tanışın: saywhat Eggdrop, NeoStats, BNC 8 17 Ağustos 2013 09:33
eggdrop1.8 CVS Güncellemeleri. saywhat Eggdrop, NeoStats, BNC 1 03 Ağustos 2013 05:18
Eggdrop1.6.18 kurulum hatası. OzGuR Eggdrop, NeoStats, BNC 25 09 Ekim 2011 19:18
eggdrop1.6.18 woody Eggdrop, NeoStats, BNC 15 10 Ağustos 2008 16:58