<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-gb">
	<link rel="self" type="application/atom+xml" href="https://forum.eggheads.org/app.php/feed/topic/21233" />

	<title>egghelp/eggheads community</title>
	<subtitle>Discussion of eggdrop bots, shell accounts and tcl scripts.</subtitle>
	<link href="https://forum.eggheads.org/index.php" />
	<updated>2023-01-14T07:32:27-04:00</updated>

	<author><name><![CDATA[egghelp/eggheads community]]></name></author>
	<id>https://forum.eggheads.org/app.php/feed/topic/21233</id>

		<entry>
		<author><name><![CDATA[flink]]></name></author>
		<updated>2023-01-14T07:32:27-04:00</updated>

		<published>2023-01-14T07:32:27-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111624#p111624</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111624#p111624"/>
		<title type="html"><![CDATA[see if you can correct me and help me with this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111624#p111624"><![CDATA[
as it is good practice to contribute I paste the code with which it works for me.<br>it picks up the request. it sends it to the dj room, it sends it to the dj.<br>if the user requests before the time limit, it warns him only once of the time left to request and puts an ignore for the time we tell the eggdrop.<br><div class="codebox"><p>Code: </p><pre><code> set rest [expr $limit - $timeago]  putserv "privmsg $chan :6 $nick  4L14e 4Q14uedan 4 [duration $rest] 4P14ara 4S14olicitar 4N14uevamente. 4Gracias"newignore $im "antiflood2min" "2"putlog "Ignore ($nick): $im  antiflood 2min"     if {$rest &gt; 160} {putnow "PRIVMSG $chan :6 $nick 14espera 4 [duration $resto] 14para solicitar otra 6canción nuevamente."newignore $ident1  "antiflood2min" "2"putlog "Ignore ($nick): $ident1 antiflood 2min"putnow "PRIVMSG $adminchans1 :4AVISO1!!!14 Se ha puesto en \002ignore\002 a \002$nick\002 (Antiflood 1 minutos) " } else { return }}} else { </code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12899">flink</a> — Sat Jan 14, 2023 7:32 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[flink]]></name></author>
		<updated>2023-01-12T12:34:42-04:00</updated>

		<published>2023-01-12T12:34:42-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111618#p111618</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111618#p111618"/>
		<title type="html"><![CDATA[see if you can correct me and help me with this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111618#p111618"><![CDATA[
I don't get any errors in the party-line as the code is now.<br>I made changes to the code again:<br><br> set rest [expr $limit - $timeago]<br> putserv "privmsg $chan :6 $nick 14espera 4 [duration $rest] 14para solicitar otra 6canción nuevamente."<br>    } else { <br>          return 0<br>   }<br> <br>if {$rest &gt; 160} {<br>putserv "privmsg $chan :6 $nick 14sea Paciente le que dan4 [duration $rest] 14para solicitar otra 6canción nuevamente.4?"<br>putnow "privmsg $adminchans1 :4AVISO1!!!14 Se ha puesto en \002ignore\002 a \002$nick\002 (Antiflood 1 minutos) "<br>putlog "Ignore ($nick): $im antiflood 1min"<br>putlog "Ignore ($nick): $ident1 antiflood 1min"<br>newignore $im "antiflood1min" "1"<br>newignore $ident1 "antiflood1min" "1"<br><br> } else { return 0 }<br><br>}<br><br><strong class="text-strong"><span style="color:red">sorry for copying the code like this, but the other way it didn't work, it ate: else return and the last braces. </span><br></strong><br>this way it does this:<br><br>because sometimes I got this error in party-line:<br> <div class="codebox"><p>Code: </p><pre><code>Tcl error [pub_wish]: can't read "handle": no such variable[/code ][list] radio room:15:53  user ¦ !peticion otro de jugo de higos picos15:53  @radio ¦ user Tu Peticion: otro de jugo de higos picos a Sido Registrada, En Un Momento Dj  Radio-Auto Te Complacera.15:53  user ¦ !peticion otro de jugo de higos picos15:53  @radio ¦  user espera  2 minutes 48 seconds para solicitar otra canción nuevamente.15:53  @radio ¦  user sea Paciente le que dan 2 minutes 48 seconds para solicitar otra canción nuevamente.?15:53  @radio ¦  user Tu Peticion: otro de jugo de higos picos a Sido Registrada, En Un Momento Dj  Radio-Auto Te Complacera.15:54  user ¦ !peticion uno de lomo15:54  @radio¦  user espera  2 minutes 26 seconds para solicitar otra canción nuevamente.15:54  user ¦ !peticion uno de lomo15:54  @radio ¦  user espera  2 minutes 21 seconds para solicitar otra canción nuevamente.15:54  user ¦ !peticion otro de jugo de higos picos15:54  @radio ¦  ma-la-je espera  2 minutes 17 seconds para solicitar otra canción nuevamente.[/list]in this case he accepts 2 requests and when he asks for a third one he does not write it any more but he does not ignore the user and continues to answer him with the time left to request again.[list] radio dj:15:53  @radio ¦ PETICION  Radio-Auto EL Nick  user A Solicitado  otro de jugo de higos picos En El Canal  #radio-room15:53  @radio ¦ AVISO!!! Se ha puesto en ignore a user (Antiflood 1 minutos)15:53  @radio ¦ PETICION  Radio-Auto EL Nick  user A Solicitado  otro de jugo de higos picos En El Canal  #radio-room [/list]in the dj room you can see that he accepted the user's request he sends the message that he has ignored it... only he does not read the request command. but if the user requests again he answers the time left to request another one. when he is supposed to have put a ginore[list]party-line:15:53        radio ¦  &lt;&lt;user&gt;&gt; !*! !peticion otro de jugo de higos picos15:53        radio ¦  Ignore (user): ma-la-je antiflood 1min15:53        radio ¦  Ignore (user): *!@ antiflood 1min15:53        radio ¦  &lt;&lt;user&gt;&gt; !*! !peticion otro de jugo de higos picos16:00        radio ¦  No longer ignoring *!Tod@NUC.351.1p2bfb.virtual (expired)16:00        radio ¦  No longer ignoring *!*@NUC.351.1p2bfb.virtual (expired)16:00        radio ¦  Writing user file...16:00        radio ¦  Writing channel file...16:04        radio ¦  No longer ignoring user (expired)16:04        radio ¦  No longer ignoring *!@ (expired) [/list]</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12899">flink</a> — Thu Jan 12, 2023 12:34 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[CrazyCat]]></name></author>
		<updated>2023-01-12T03:12:19-04:00</updated>

		<published>2023-01-12T03:12:19-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111617#p111617</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111617#p111617"/>
		<title type="html"><![CDATA[see if you can correct me and help me with this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111617#p111617"><![CDATA[
Well, if you only see the first sentence, are you in #tcls (and also your eggdrop) and can your eggdrop speak in it ?<br>What did you get in party-line (the 3 last messages are using putlog) ?<br>Set your console to +d (debug) and check for error message.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=691">CrazyCat</a> — Thu Jan 12, 2023 3:12 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[flink]]></name></author>
		<updated>2023-01-11T09:29:33-04:00</updated>

		<published>2023-01-11T09:29:33-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111616#p111616</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111616#p111616"/>
		<title type="html"><![CDATA[see if you can correct me and help me with this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111616#p111616"><![CDATA[
thanks CrazyCat for replying. i tried what you said and i got the same result. only the 1st message pops up:<br>$nick wait [duration $rest] to request another song again.<br><blockquote class="uncited"><div>$rest is an integer, why using llength (length of a list) which will return 1 in your case.<div class="codebox"><p>Code: </p><pre><code>if {$rest &gt; 160} {</code></pre></div></div></blockquote><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12899">flink</a> — Wed Jan 11, 2023 9:29 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[CrazyCat]]></name></author>
		<updated>2023-01-10T18:30:43-04:00</updated>

		<published>2023-01-10T18:30:43-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111615#p111615</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111615#p111615"/>
		<title type="html"><![CDATA[see if you can correct me and help me with this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111615#p111615"><![CDATA[
$rest is an integer, why using llength (length of a list) which will return 1 in your case.<div class="codebox"><p>Code: </p><pre><code>if {$rest &gt; 160} {</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=691">CrazyCat</a> — Tue Jan 10, 2023 6:30 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[flink]]></name></author>
		<updated>2023-01-10T16:00:08-04:00</updated>

		<published>2023-01-10T16:00:08-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111612#p111612</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111612#p111612"/>
		<title type="html"><![CDATA[see if you can correct me and help me with this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111612#p111612"><![CDATA[
<div class="codebox"><p>Code: </p><pre><code># shoutcast.tcl v1.03 by domsen &lt;domsen@domsen.org&gt; (c)2oo5## comments? bugs? ideas? requests? money? beer?# plz mail me or visit my homepage @ www.domsen.org# visit #newsticker@ircnet################################################################## shoutcast.tcl v1.03 by Chino &lt;chino@canal-ayuda.org&gt; (c)2oo6# "TCL con Permiso, Editado y Traducido con credito a domsen."## Favor no tocar nada de lo que no entiendas de haber# algún problema no es responsabilidad mia ni de domsen## Colores usados: Negro Azul Rojo Marrón y Fucsia## Para cualquier ayuda me encuentra en:# &lt; #Ayuda #Trujilo #Ayuda-Eggdrop &gt; &lt;eu.Undernet.oRG&gt;## No quitar los creditos dados a:## - domsen# - Chino# - #Ayuda-Eggdrop################################################################# Saludos:# A Spinetta que aportó mucho con la traducción.################################################################# Configuracion ##################################################set radiochans "#tcls #lapaz"set adminchans "#tcls"set streamip "radioirc.sytes.net"set streamport "8000"set streampass "Radiopass"set scstatstrigger "!estado"set scstreamtrigger "!enlace"set scplayingtrigger "!tocando"set sclistenertrigger "!oyentes"set scdjtrigger "!dj"set scsetdjtrigger ".serdj"set scunsetdjtrigger ".noserdj"set scwishtrigger "!pedidos"set scgreettrigger "!saludos"set sclastsongstrigger "!ultimas"set schelptrigger "!radio"set alertadmin ""set doalertadmin "1"set announce "1"set urltopic "0"set ctodjc "1"set tellsongs "1"set tellusers "1"set tellbitrate "1"set advertise "1"set advertiseonlyifonline "1"set offlinetext "La Radio Esta 4APAGADA !!!"set offlinetopic ""set onlinetext "1Radio IRC 6TRANSMITIENDO a 4 /bitrate/  kbits 1Sitonizanos en -&gt; 12http://$streamip:$streamport/listen.pls"set onlinetopic ""set streamtext "Sintoniza Radio IRC en www.Sonidomegga.com"set advertisetext "Radio IRC 4TRANSMITIENDO ---&gt; 2 http://$streamip:$streamport/listen.pls - ... Para Ver Comandos de la Radio Teclea 2!radio "# end of config #####################bind pub - $scstatstrigger pub_scstatbind msg - $scstatstrigger msg_scstatbind pub - $scplayingtrigger pub_playingbind msg - $scplayingtrigger msg_playingbind pub - $scdjtrigger pub_djbind msg - $scdjtrigger msg_djbind pub D $scsetdjtrigger pub_setdjbind msg D $scsetdjtrigger msg_setdjbind pub D $scunsetdjtrigger pub_unsetdjbind msg D $scunsetdjtrigger msg_unsetdjbind pub - $scwishtrigger pub_wishbind msg - $scwishtrigger msg_wishbind pub - $scgreettrigger pub_greetbind msg - $scgreettrigger msg_greetbind pub - $scstreamtrigger pub_streambind msg - $scstreamtrigger msg_streambind pub - $sclastsongstrigger pub_lastsongsbind msg - $sclastsongstrigger msg_lastsongsbind pub - $sclistenertrigger pub_listenerbind msg - $sclistenertrigger msg_listenerbind pub - $schelptrigger pub_helpbind msg - $schelptrigger msg_helpbind time - "* * * * *" envivobind time - "?0 * * * *" advertisebind nick f * djnickchangeset dj ""set surl ""set bitrate ""set stitle ""if {[file exists dj]} {set temp [open "dj" r]set dj [gets $temp]close $temp}proc shrink { calc number string start bl} { return [expr [string first "$string" $bl $start] $calc $number] }proc status { } {global streamip streamport streampassif {[catch {set sock [socket $streamip $streamport] } sockerror]} {putlog "error: $sockerror"return 0 } else {puts $sock "GET /admin.cgi?pass=$streampass&amp;mode=viewxml&amp;page=0 HTTP/1.0"puts $sock "User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.9)"puts $sock "Host: $streamip"puts $sock "Connection: close"puts $sock ""flush $sockwhile {[eof $sock] != 1} {set bl [gets $sock]if { [string first "standalone" $bl] != -1 } {set streamstatus [string range $bl [shrink + 14 "" 0 $bl] [shrink - 1 "" 0 $bl]]}}close $sock}if { $streamstatus == "1" } { return 1 } else { return 0 }}proc poststuff { mode text } {global radiochans djset curlist "0"set curhigh "0"set surl ""set cursong ""set sgenre ""set bitrate "0"set stitle ""set temp [open "envivo" r]while {[eof $temp] != 1} {set zeile [gets $temp]if {[string first "curlist:" $zeile] != -1 } { set curlist $zeile }if {[string first "curhigh:" $zeile] != -1 } { set curhigh $zeile }if {[string first "cursong:" $zeile] != -1 } { set cursong [lrange $zeile 1 [llength $zeile]]] }if {[string first "sgenre:" $zeile] != -1 } { set sgenre [lrange $zeile 1 [llength $zeile]]}if {[string first "serverurl:" $zeile] != -1 } { set surl [lindex $zeile 1] }if {[string first "bitrate:" $zeile] != -1 } { set bitrate [lindex $zeile 1] }if {[string first "stitle:" $zeile] != -1 } { set stitle [lindex $zeile 1] }}close $tempregsub -all "/stitle/" $text "$stitle" textregsub -all "/curlist/" $text "$curlist" textregsub -all "/curhigh/" $text "$curhigh" textregsub -all "/cursong/" $text "$cursong" textregsub -all "/sgenre/" $text "$sgenre" textregsub -all "/surl/" $text "$surl" textregsub -all "/bitrate/" $text "$bitrate" textregsub -all "/dj/" $text "$dj" textforeach chan [channels] {if {$radiochans == "" } { putserv "$mode $chan :$text" }if {$radiochans != "" } {if {([lsearch -exact [string tolower $radiochans] [string tolower $chan]] != -1)} {putserv "$mode $chan :$text"}}}}proc schelp { target } {global scstatstrigger scstreamtrigger scplayingtrigger scdjtrigger sclastsongstrigger scwishtrigger scgreettrigger sclistenertriggerputserv "notice $target :1Los Comandos Que Puede Usar Son:"putserv "notice $target :4$scstatstrigger1: Ver el Estado - 4$scstreamtrigger1: Ver Nuestro Link - 4$scplayingtrigger1: Ver el SONG que esta actualmente Sonando - 4$scdjtrigger1: Ver Nuestro Actual DJ de la Radio - 4$sclastsongstrigger1: Ver Las 10 ULTIMAS Song sonadas en radio - 4$scwishtrigger1: Mandar pedidos Musicales Ej: $scwishtrigger &lt;tus_songs&gt; - 4$scgreettrigger1: Mandar Tus Mensaje de Saludos Ej: $scgreettrigger &lt;tus_saludos&gt; 4$sclistenertrigger1: Ver N° Actual de Oyentes "putserv "notice $target :1Radio IRC -&gt;&gt; 5http://radioirc.sytes.net:8000/listen.pls51 - domsen &amp; Chino"}proc pub_help {nick uhost hand chan arg} {global radiochansif {$radiochans == "" } { schelp $nick }if {$radiochans != "" } {if {([lsearch -exact [string tolower $radiochans] [string tolower $chan]] != -1) || ($radiochans == "")} { schelp $nick}}}proc advertise { nick uhost hand chan arg } {global advertisetext advertise advertiseonlyifonlineif {$advertise == "1" &amp;&amp; $advertiseonlyifonline == "0"} { poststuff privmsg "$advertisetext" }if {$advertise == "1" &amp;&amp; $advertiseonlyifonline == "1" &amp;&amp; [status] == 1} { poststuff privmsg "$advertisetext" }}proc setdj {nickname djnickname } {if {$djnickname == "" } { set djnickname $nickname }global streamip streamport streampass djputlog "shoutcast: Nuevo Dj: $djnickname ($nickname)"set temp [open "dj" w+]puts $temp $djnicknameclose $tempset temp [open "djnick" w+]puts $temp $nicknameclose $tempif { [status] == "1" } { poststuff privmsg "$djnickname Es Ahora Nuestro DJ."if { $::ctodjc == "1" } {set temp [open "envivo" r]while {[eof $temp] != 1} {set zeile [gets $temp]if {[string first "envivo:" $zeile] != -1 } { set oldenvivo $zeile }if {[string first "curlist:" $zeile] != -1 } { set oldcurlist $zeile }if {[string first "curhigh:" $zeile] != -1 } { set oldcurhigh $zeile }if {[string first "cursong:" $zeile] != -1 } { set oldsong $zeile }if {[string first "bitrate:" $zeile] != -1 } { set oldbitrate $zeile }}close $temp}} else {putserv "privmsg $nickname :Comando invalido por tener el servidor OFF Line" }}proc msg_setdj { nick uhost hand arg } { setdj $nick $arg }proc pub_setdj { nick uhost hand chan arg } { global adminchans; if {([lsearch -exact [string tolower $adminchans] [string tolower $chan]] != -1) || ($adminchans == "")} { setdj $nick $arg }}proc unsetdj { nick } {global djset dj ""file delete djputserv "notice $nick :Dj Borrado .. Puede Entrar otro Dj Poniendo el Comando .setdj Nickname"}proc msg_unsetdj { nick uhost hand arg } { unsetdj $nick }proc pub_unsetdj { nick uhost hand chan arg } { global adminchans; if {([lsearch -exact [string tolower $adminchans] [string tolower $chan]] != -1) || ($adminchans == "")} { unsetdj $nick }}proc listener { target } {global streamip streamport streampassputlog "Radio: $target Pedido De Conteo de Oyentes"if {[catch {set sock [socket $streamip $streamport] } sockerror]} {putlog "error: $sockerror"return 0 } else {puts $sock "GET /admin.cgi?pass=$streampass&amp;mode=viewxml&amp;page=0 HTTP/1.0"puts $sock "User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.9)"puts $sock "Host: $streamip"puts $sock "Connection: close"puts $sock ""flush $sockwhile {[eof $sock] != 1} {set bl [gets $sock]if { [string first "standalone" $bl] != -1 } {set repl [string range $bl [shrink + 19 "" 0 $bl] [shrink - 1 "" 0 $bl]]set curhigh [string range $bl [shrink + 15 "" 0 $bl] [shrink - 1 "" 0 $bl]]set maxl [string range $bl [shrink + 14 "" 0 $bl] [shrink - 1 "" 0 $bl]]set avgtime [string range $bl [shrink + 13 "" 0 $bl] [shrink - 1 "" 0 $bl]]}}close $sockputserv "notice $target :Actualmente hay $repl Oyente(s), La Radio Tiene Capacidad para $maxl Oyentes, el número máximo de Oyentes Hasta Ahora es de $curhigh Oyentes, el promedio de escucha es a $avgtime"}}proc msg_listener { nick uhost hand arg } { listener $nick }proc pub_listener { nick uhost hand chan arg } { global radiochans; if {([lsearch -exact [string tolower $radiochans] [string tolower $chan]] != -1) || ($radiochans == "")} { listener $nick }}proc wish { nick chan arg } {global radiochans  adminchans limitset temp [open "peticiones" r]             set peticiones [gets $temp]     close $temp     if {$peticiones == "Abiertas"} {if {$arg == ""} { putserv "privmsg $chan : 12$nick 10P2or 10F2avor 10E2specifica 10E2l 10T2ema 10Q2ue 10D2eseas 10P2edir 10!peticion 10Tema 2Cantante 10G2racias 10P2or 10S2intonizarnos"; return 0}set host [lindex [split [getchanhost $nick $chan] @] 1]     set idents [lindex [split [getchanhost $nick $chan] @] 0]     if {[onchan $nick]} {set im "*!*@[join [lrange [split $host .] 0 end] .]"} else {set im "$nick"} if {[onchan $nick]} {set ident1 "*![join $idents]@*" } if {"$idents" == "ircap"} {set ident1 "*![join $idents]@[join $host]"     } else {     set ident1 "*![join $idents]@[join $host]" }if { [info exist arg] } {set temp [open "djnick" r]set djnick [gets $temp]close $temp       if {![info exist limit]} { set limit 180}     foreach {_nick time} [array get ::flood] { if {[expr [clock seconds] - $time] &gt; $limit} { unset ::flood($_nick) } }     foreach {_ident1 time} [array get ::flood] { if {[expr [clock seconds] - $time] &gt; $limit} { unset ::flood($_ident1) } }if {([info exists ::flood($nick)]) || ([info exists ::flood($ident1)])} {set timeago [expr [clock seconds] - $::flood($nick)]set timeago [expr [clock seconds] - $::flood($ident1)]if {$timeago &lt; $limit} { set rest [expr $limit - $timeago] putserv "privmsg $chan :6 $nick 14espera 4 [duration $rest] 14para solicitar otra 6canción nuevamente." return 0 } if {[llength $rest] &gt; 160} {putserv "privmsg $chan :6 $nick 14sea Paciente le que dan4 [duration $rest] 14para solicitar otra 6canción nuevamente.4?"putserv "privmsg $adminchans :4AVISO1!!!14 Se ha puesto en \002ignore\002 a \002$nick\002 (Antiflood 2 minutos) "putlog "Ignore ($nick): $im $handle antiflood 2min"putlog "Ignore ($nick): $ident1 $handle antiflood 2min"putlog "Ignore ($nick): $im $handle antiflood 2min"newignore $im $handle "antiflood 2min" "2"newignore $ident1 $handle "antiflood2min" "2" } else { return }}putserv "privmsg $adminchans : 10PETICION 12 $djnick 10E2L 10N2ick 12 $nick 10A 2S10olicitado 12 $arg 10En 2El 10Canal 12 $chan"putserv "privmsg $$djnick : 10PETICION 12 $djnick 10E2L 10N2ick 12 $nick 10A 2S10olicitado 12 $arg 10En 2El 10Canal 12 $chan"putserv "privmsg $chan :  12$nick 10T2u 10P2eticion 2a 10S2ido 10R2egistrada, 10E2n 10U2n 10M2omento 10D2j 6 $djnick 10T2e 10C2omplacera."set ::flood($nick) [clock seconds]set ::flood($ident1) [clock seconds]} else {putserv "privmsg $chan :10L2o 10S2iento 12$nick 10l2a 10R2adio 10E2sta 10E2n 10M2odo: 12Automatico :2(" }  } }proc msg_wish { nick uhost hand arg } { wish $nick $arg }proc pub_wish { nick uhost hand chan arg } { global radiochans; if {([lsearch -exact [string tolower $radiochans] [string tolower $chan]] != -1) || ($radiochans == "")} { wish $nick $arg }}proc sclastsongs { target } {global streamip streamport streampassputlog "Radio: $target Pedidos las Song ultimas"if {[catch {set sock [socket $streamip $streamport] } sockerror]} {putlog "error: $sockerror"return 0 } else {puts $sock "GET /admin.cgi?pass=$streampass&amp;mode=viewxml&amp;page=0 HTTP/1.0"puts $sock "User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.9)"puts $sock "Host: $streamip"puts $sock "Connection: close"puts $sock ""flush $sockwhile {[eof $sock] != 1} {set bl [gets $sock]if { [string first "standalone" $bl] != -1 } {set songs [string range $bl [string first "&lt;title&gt;" $bl] [expr [string last "&lt;/title&gt;" $bl] + 7]]regsub -all "&lt;" $songs "&lt;" songsregsub -all "&gt;" $songs "&gt;" songsregsub -all "&amp;" $songs "+" songsregsub -all """ $songs "\"" songsregsub -all "'" $songs "'" songsregsub -all "ÿ" $songs "" songsregsub -all "&lt;title&gt;" $songs "(" songsregsub -all "&lt;/title&gt;" $songs ")" songsregsub -all "" $songs "" songsregsub -all "" $songs " - " songsregsub -all "" $songs "" songsregsub -all "" $songs "" songsregsub -all {\d} $songs "" songsregsub -all "´" $songs "´" songsregsub -all "&amp;#x96;" $songs "-" songsregsub -all "ö" $songs "ö" songsregsub -all "ä" $songs "ä" songsregsub -all "ü" $songs "ü" songsregsub -all "Ö" $songs "Ö" songsregsub -all "Ä" $songs "Ä" songsregsub -all "Ü" $songs "Ü" songsregsub -all "ß" $songs "ß" songs}}close $sockputserv "notice $target :$songs"}}proc msg_lastsongs { nick uhost hand arg } { sclastsongs $nick }proc pub_lastsongs { nick uhost hand chan arg } { global radiochans; if {([lsearch -exact [string tolower $radiochans] [string tolower $chan]] != -1) || ($radiochans == "")} { sclastsongs $nick }}proc scstream { target } {global streamip streamport streamtextputlog "Radio: Informacion pedida por $target"putserv "notice $target :$streamtext"}proc msg_stream { nick uhost hand arg } { scstream $nick }proc pub_stream { nick uhost hand chan arg } { global radiochans; if {([lsearch -exact [string tolower $radiochans] [string tolower $chan]] != -1) || ($radiochans == "")} { scstream $nick }}proc scgreet { nick arg } {if {$arg == ""} { putserv "notice $nick :"; return 0}if { [status] == "1" } {set temp [open "djnick" r]set djnick [gets $temp]close $tempputserv "privmsg $djnick :(Saludo) - $nick - $arg"} else {putserv "notice $nick :" }}proc msg_greet { nick uhost hand arg } { scgreet $nick $arg }proc pub_greet { nick uhost hand chan arg } { global radiochans; if {([lsearch -exact [string tolower $radiochans] [string tolower $chan]] != -1) || ($radiochans == "")} { scgreet $nick $arg }}proc djnickchange { oldnick uhost hand chan newnick } {set temp [open "djnick" r]set djnick [gets $temp]close $tempif {$oldnick == $djnick} {putlog "Radio: Cambia de Nick del Dj $oldnick -&gt; $newnick"set temp [open "djnick" w+]puts $temp $newnickclose $temp}}proc dj { target } {global streamip streamport streampass djputlog "Radio: $target pidio la Informacio de Dj"if {[status] == 1} {if {[file exists dj]} {set temp [open "dj" r]set dj [gets $temp]close $tempputserv "notice $target :Le Presento a 4$dj Nuestro(a) DJ de la Radio IRC"} else { putserv "notice $target :No hay ningun DJ seteado" }} else { putserv "notice $target :La Radio se encuentra OFF Line" }}proc msg_dj { nick uhost hand arg } { dj $nick"}proc pub_dj { nick uhost hand chan arg } { global radiochans; if {([lsearch -exact [string tolower $radiochans] [string tolower $chan]] != -1) || ($radiochans == "")} { dj $nick }}proc scstat {target} {global streamip streamport streampassputlog "Radio: $target Pidio el Estado de la Radio"if {[catch {set sock [socket $streamip $streamport] } sockerror]} {putlog "error: $sockerror"return 0 } else {puts $sock "GET /admin.cgi?pass=$streampass&amp;mode=viewxml&amp;page=0 HTTP/1.0"puts $sock "User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.9)"puts $sock "Host: $streamip"puts $sock "Connection: close"puts $sock ""flush $sockwhile {[eof $sock] != 1} {set bl [gets $sock]if { [string first "standalone" $bl] != -1 } {set streamstatus [string range $bl [shrink + 14 "" 0 $bl] [shrink - 1 "" 0 $bl]]set repl [string range $bl [shrink + 19 "" 0 $bl] [shrink - 1 "" 0 $bl]]set curhigh [string range $bl [shrink + 15 "" 0 $bl] [shrink - 1 "" 0 $bl]]set currentl [string range $bl [shrink + 18 "" 0 $bl] [shrink - 1 "" 0 $bl]]set surl [string range $bl [shrink + 11 "" 0 $bl] [shrink - 1 "" 0 $bl]]set maxl [string range $bl [shrink + 14 "" 0 $bl] [shrink - 1 "" 0 $bl]]set bitrate [string range $bl [shrink + 9 "" 0 $bl] [shrink - 1 "" 0 $bl]]set stitle [string range $bl [shrink + 13 "" 0 $bl] [shrink - 1 "" 0 $bl]]set sgenre [string range $bl [shrink + 13 "" 0 $bl] [shrink - 1 "" 0 $bl]]if {$sgenre != ""} {set sgenre " ($sgenre)"}set avgtime [string range $bl [shrink + 13 "" 0 $bl] [shrink - 1 "" 0 $bl]]set irc [string range $bl [shrink + 5 "" 0 $bl] [shrink - 1 "" 0 $bl]]set icq [string range $bl [shrink + 5 "" 0 $bl] [shrink - 1 "" 0 $bl]]if {$icq == 0} { set icq "N/A" }set aim [string range $bl [shrink + 5 "" 0 $bl] [shrink - 1 "" 0 $bl]]set webhits [string range $bl [shrink + 9 "" 0 $bl] [shrink - 1 "" 0 $bl]]set streamhits [string range $bl [shrink + 12 "" 0 $bl] [shrink - 1 "" 0 $bl]]set version [string range $bl [shrink + 9 "" 0 $bl] [shrink - 1 "" 0 $bl]]if {$streamstatus == 1} {if {[file exists dj]} {set temp [open "dj" r]set dj [gets $temp]close $temp} else { set dj "none" }putserv "notice $target :Radio IRC ESTA EN LINEA, en shoutcast y Transmitiendo a $bitrate kbps, mas información en $surl"} else {putserv "notice $target :Radio IRC Actualmente ESTA APAGADA, Mas información en www.SonidoMegga.Com" }putserv "notice $target :La Capacidad maxima de oyentes es $maxl, Total de Oyentes En la Radio fue de $curhigh oyentes."putserv "notice $target :El tiempo promedio de escucha es de $avgtime segundos, La Radio tiene $webhits webhits y $streamhits streamhits."putserv "notice $target :Tu puedes contactarte en el IRC en el canal $irc, Via Internet."}}close $sock}}proc msg_scstat { nick uhost hand arg } { scstat $nick}proc pub_scstat { nick uhost hand chan arg } { global radiochans; if {([lsearch -exact [string tolower $radiochans] [string tolower $chan]] != -1) || ($radiochans == "")} { scstat $nick }}proc playing {target} {global streamip streamport streampass djputlog "Radio: $target pidio el titulo de la Song"if {[catch {set sock [socket $streamip $streamport] } sockerror]} {putlog "error: $sockerror"return 0 } else {puts $sock "GET /admin.cgi?pass=$streampass&amp;mode=viewxml&amp;page=0 HTTP/1.0"puts $sock "User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.9)"puts $sock "Host: $streamip"puts $sock "Connection: close"puts $sock ""flush $sockwhile {[eof $sock] != 1} {set bl [gets $sock]if { [string first "standalone" $bl] != -1 } {set streamstatus [string range $bl [shrink + 14 "" 0 $bl] [shrink - 1 "" 0 $bl]]set songtitle [string range $bl [shrink + 11 "set songurl [string range $bl [shrink + 9 "" 0 $bl] [shrink - 1 "" 0 $bl]]if {$songurl != ""} { set songurl " ($songurl)"}regsub -all "&lt;" $songtitle "&lt;" songtitleregsub -all "&gt;" $songtitle "&gt;" songtitleregsub -all "&amp;" $songtitle "+" songtitleregsub -all """ $songtitle "\"" songtitleregsub -all "'" $songtitle "'" songtitleregsub -all "ÿ" $songtitle "" songtitleregsub -all "´" $songtitle "´" songtitleregsub -all "&amp;#x96;" $songtitle "-" songtitleregsub -all "ö" $songtitle "ö" songtitleregsub -all "ä" $songtitle "ä" songtitleregsub -all "ü" $songtitle "ü" songtitleregsub -all "Ö" $songtitle "Ö" songtitleregsub -all "Ä" $songtitle "Ä" songtitleregsub -all "Ü" $songtitle "Ü" songtitleregsub -all "ß" $songtitle "ß" songtitleif {$streamstatus == 1} {putserv "notice $target :Radio IRC, Tocando -&gt; $songtitle"} else {putserv "notice $target :"}}}close $sock}}proc msg_playing { nick uhost hand arg } { playing $nick}proc pub_playing { nick uhost hand chan arg } { global radiochans; if {([lsearch -exact [string tolower $radiochans] [string tolower $chan]] != -1) || ($radiochans == "")} { playing $nick }}proc envivo { nick uhost hand chan arg } {global radiochans announce tellusers tellsongs tellbitrate urltopic djglobal offlinetext offlinetopic onlinetext onlinetopicglobal streamip streampass streamport djglobal doalertadmin alertadminif {$announce == 1 || $tellsongs == 1 || $tellusers == 1 || $tellbitrate == 1} {set envivofile "envivo"set oldenvivo "envivo: 0"set oldcurlist "curlist: 0"set oldcurhigh "curhigh: 0"set oldsong "cursong: 0"set oldbitrate "bitrate: 0"if {[file exists $envivofile]} {putlog "Radio: Viendo la Conexion de Radio"set temp [open "envivo" r]while {[eof $temp] != 1} {set zeile [gets $temp]if {[string first "envivo:" $zeile] != -1 } { set oldenvivo $zeile }if {[string first "curlist:" $zeile] != -1 } { set oldcurlist $zeile }if {[string first "curhigh:" $zeile] != -1 } { set oldcurhigh $zeile }if {[string first "cursong:" $zeile] != -1 } { set oldsong $zeile }if {[string first "bitrate:" $zeile] != -1 } { set oldbitrate $zeile }}close $temp}if {[catch {set sock [socket $streamip $streamport] } sockerror]} {putlog "error: $sockerror"return 0} else {puts $sock "GET /admin.cgi?pass=$streampass&amp;mode=viewxml&amp;page=0 HTTP/1.0"puts $sock "User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.9)"puts $sock "Host: $streamip"puts $sock "Connection: close"puts $sock ""flush $sockwhile {[eof $sock] != 1} {set bl [gets $sock]if { [string first "standalone" $bl] != -1 } {set streamstatus "envivo: [string range $bl [shrink + 14 "" 0 $bl] [shrink - 1 "" 0 $bl]]"set repl "curlist: [string range $bl [shrink + 19 "" 0 $bl] [shrink - 1 "" 0 $bl]]"set curhigh "curhigh: [string range $bl [shrink + 15 "" 0 $bl] [shrink - 1 "" 0 $bl]]"set currentl [string range $bl [shrink + 18 "" 0 $bl] [shrink - 1 "" 0 $bl]]set surl "serverurl: [string range $bl [shrink + 11 "" 0 $bl] [shrink - 1 "" 0 $bl]]"set cursong "cursong: [string range $bl [shrink + 11 "&lt;songtitle" 0 $bl] [shrink - 1 "" 0 $bl]]"set songurl [string range $bl [shrink + 9 "" 0 $bl] [shrink - 1 "" 0 $bl]]set bitrate "bitrate: [string range $bl [shrink + 9 "" 0 $bl] [shrink - 1 "" 0 $bl]]"set stitle "stitle: [string range $bl [shrink + 13 "" 0 $bl] [shrink - 1 "" 0 $bl]]"set sgenre "sgenre: [string range $bl [shrink + 13 "" 0 $bl] [shrink - 1 "" 0 $bl]]"}}close $sock}set temp [open "envivo" w+]puts $temp "$streamstatus\n$repl\n$curhigh\n$cursong\n$bitrate\n$stitle\n$sgenre\n$surl"close $tempif {$announce == 1 } {if {$streamstatus == "envivo: 0" &amp;&amp; $oldenvivo == "envivo: 1"} {poststuff privmsg $offlinetextif {$doalertadmin == "1"} { sendnote domsen $alertadmin "" }if {$urltopic == 1} { poststuff topic $offlinetopic }}if {$streamstatus == "envivo: 1" &amp;&amp; $oldenvivo == "envivo: 0" } {if {$sgenre != ""} {set sgenre " ([lrange $sgenre 1 [llength $sgenre]] )"}poststuff privmsg "$onlinetext"if {$urltopic == 1} { poststuff topic "$onlinetopic" }}}if {($tellusers == 1) &amp;&amp; ($streamstatus == "envivo: 1") &amp;&amp; ($oldcurhigh != "curhigh: 0") } {if {$oldcurhigh != $curhigh} {poststuff privmsg "Posibles Oyentes: [lindex $curhigh 1]"}if {$oldcurlist != $repl} {poststuff privmsg ""}}if {($tellsongs == 1) &amp;&amp; ($oldsong != $cursong) &amp;&amp; ($streamstatus == "envivo: 1") } {if {$songurl != ""} { set songurl " ($songurl)"}regsub -all "&lt;" $cursong "&lt;" cursongregsub -all "&gt;" $cursong "&gt;" cursongregsub -all "&amp;" $cursong "+" cursongregsub -all """ $cursong "\"" cursongregsub -all "'" $cursong "'" cursongregsub -all "ÿ" $cursong "" cursongregsub -all "´" $cursong "´" cursongregsub -all "&amp;#x96;" $cursong "-" cursongregsub -all "ö" $cursong "ö" cursongregsub -all "ä" $cursong "ä" cursongregsub -all "ü" $cursong "ü" cursongregsub -all "Ö" $cursong "Ö" cursongregsub -all "Ä" $cursong "Ä" cursongregsub -all "Ü" $cursong "Ü" cursongregsub -all "ß" $cursong "ß" cursongputlog $cursongpoststuff privmsg "1Quieres Escuchar La Radio IRC Haz Doble Click en -&gt;&gt; 12 http://radioirc.sytes.net:8000/listen.pls  En Linea 6$dj...La Actual Canción es: 4 [lrange $cursong 1 [llength $cursong]] .. Para Ver Comandos de la Radio Teclea 6!radio "}if {($tellbitrate == 1) &amp;&amp; ($oldbitrate != $bitrate) &amp;&amp; ($streamstatus == "envivo: 1") &amp;&amp; ($oldbitrate != "bitrate: 0")} {poststuff privmsg "Calidad Seteada a [lindex $bitrate 1]kbps"}}}putlog "-= Cargado: shoutcast.tcl Por *#Ayuda-eggdrop* =-"</code></pre></div><br>in this part of the code I have the problem <div class="codebox"><p>Code: </p><pre><code>proc wish { nick chan arg } {global radiochans  adminchans limitset temp [open "peticiones" r]             set peticiones [gets $temp]     close $temp     if {$peticiones == "Abiertas"} {if {$arg == ""} { putserv "privmsg $chan : 12$nick 10P2or 10F2avor 10E2specifica 10E2l 10T2ema 10Q2ue 10D2eseas 10P2edir 10!peticion 10Tema 2Cantante 10G2racias 10P2or 10S2intonizarnos"; return 0}set host [lindex [split [getchanhost $nick $chan] @] 1]     set idents [lindex [split [getchanhost $nick $chan] @] 0]     if {[onchan $nick]} {set im "*!*@[join [lrange [split $host .] 0 end] .]"} else {set im "$nick"} if {[onchan $nick]} {set ident1 "*![join $idents]@*" } if {"$idents" == "ircap"} {set ident1 "*![join $idents]@[join $host]"     } else {     set ident1 "*![join $idents]@[join $host]" }if { [info exist arg] } {set temp [open "djnick" r]set djnick [gets $temp]close $temp       if {![info exist limit]} { set limit 180}     foreach {_nick time} [array get ::flood] { if {[expr [clock seconds] - $time] &gt; $limit} { unset ::flood($_nick) } }     foreach {_ident1 time} [array get ::flood] { if {[expr [clock seconds] - $time] &gt; $limit} { unset ::flood($_ident1) } }if {([info exists ::flood($nick)]) || ([info exists ::flood($ident1)])} {set timeago [expr [clock seconds] - $::flood($nick)]set timeago [expr [clock seconds] - $::flood($ident1)]if {$timeago &lt; $limit} { set rest [expr $limit - $timeago] putserv "privmsg $chan :6 $nick 14espera 4 [duration $rest] 14para solicitar otra 6canción nuevamente." return 0 } if {[llength $rest] &gt; 160} {putserv "privmsg $chan :6 $nick 14sea Paciente le que dan4 [duration $rest] 14para solicitar otra 6canción nuevamente.4?"putserv "privmsg $adminchans :4AVISO1!!!14 Se ha puesto en \002ignore\002 a \002$nick\002 (Antiflood 2 minutos) "putlog "Ignore ($nick): $im $handle antiflood 2min"putlog "Ignore ($nick): $ident1 $handle antiflood 2min"putlog "Ignore ($nick): $im $handle antiflood 2min"newignore $im $handle "antiflood 2min" "2"newignore $ident1 $handle "antiflood2min" "2" } else { return }}putserv "privmsg $adminchans : 10PETICION 12 $djnick 10E2L 10N2ick 12 $nick 10A 2S10olicitado 12 $arg 10En 2El 10Canal 12 $chan"putserv "privmsg $$djnick : 10PETICION 12 $djnick 10E2L 10N2ick 12 $nick 10A 2S10olicitado 12 $arg 10En 2El 10Canal 12 $chan"putserv "privmsg $chan :  12$nick 10T2u 10P2eticion 2a 10S2ido 10R2egistrada, 10E2n 10U2n 10M2omento 10D2j 6 $djnick 10T2e 10C2omplacera."set ::flood($nick) [clock seconds]set ::flood($ident1) [clock seconds]} else {putserv "privmsg $chan :10L2o 10S2iento 12$nick 10l2a 10R2adio 10E2sta 10E2n 10M2odo: 12Automatico :2(" }  } }</code></pre></div><br>when some user makes a request.<br>1º it does it right it passes all the messages where it has to send them. admin room, dj , to the user.<br>2º if the user before the time (180 minutes) asks again another request jumps: $nick wait [duration $rest] to request another song again. and does not pick up the request or send the corresponding messages room admin, dj, user does it well.<br><br><br><strong class="text-strong">3º if the user before the time (160 or other seconds) request again it doesn't jump :<br>$nick be Patient you are given [duration $rest] to request another song again.<br>WARNING 1!!! $nick has been put on ignore (Antiflood 2 minutes)<br>and he is not put in ignore mode to be.<br><br>This is the part where I notice the bug as the code does not continue.<br></strong><div class="codebox"><p>Code: </p><pre><code>if {[llength $rest] &gt; 160} {putserv "privmsg $chan :6 $nick 14sea Paciente le que dan4 [duration $rest] 14para solicitar otra 6canción nuevamente.4?"putserv "privmsg $adminchans :4AVISO1!!!14 Se ha puesto en \002ignore\002 a \002$nick\002 (Antiflood 2 minutos) "putlog "Ignore ($nick): $im $handle antiflood 2min"putlog "Ignore ($nick): $ident1 $handle antiflood 2min"putlog "Ignore ($nick): $im $handle antiflood 2min"newignore $im $handle "antiflood 2min" "2"newignore $ident1 $handle "antiflood2min" "2" } else { return }}</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12899">flink</a> — Tue Jan 10, 2023 4:00 pm</p><hr />
]]></content>
	</entry>
	</feed>
