<?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/9499" />

	<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>2005-04-28T08:46:45-04:00</updated>

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

		<entry>
		<author><name><![CDATA[thedude0001]]></name></author>
		<updated>2005-04-28T08:46:45-04:00</updated>

		<published>2005-04-28T08:46:45-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=48653#p48653</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=48653#p48653"/>
		<title type="html"><![CDATA[Problem with bind time in existing script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=48653#p48653"><![CDATA[
That actually worked  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_biggrin.gif" width="15" height="15" alt=":D" title="Very Happy"> <br><br>Thanks a lot! <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_biggrin.gif" width="15" height="15" alt=":D" title="Very Happy"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5806">thedude0001</a> — Thu Apr 28, 2005 8:46 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[De Kus]]></name></author>
		<updated>2005-04-28T03:37:06-04:00</updated>

		<published>2005-04-28T03:37:06-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=48644#p48644</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=48644#p48644"/>
		<title type="html"><![CDATA[Problem with bind time in existing script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=48644#p48644"><![CDATA[
did you try 'bind time - "00 * * * *" gtgltraffic'?<br>I hope read TCL-Commands.tcl close to recognize, that this would result in something like:<br>nick=00<br>host=17<br>hand=28<br>chan=04<br>arg=2005<br>^-^<br>so you have to "reply" it with a proc like:<div class="codebox"><p>Code: </p><pre><code>bind time - "00 *" gtgltraffic:tproc gtgltraffic:t {min h d m y} {   gtgltraffic {} {} {} #channel {}   return 0}</code></pre></div>dont forget to replace your channel name <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_razz.gif" width="15" height="15" alt=":P" title="Razz">.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2382">De Kus</a> — Thu Apr 28, 2005 3:37 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[thedude0001]]></name></author>
		<updated>2005-04-27T19:11:17-04:00</updated>

		<published>2005-04-27T19:11:17-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=48635#p48635</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=48635#p48635"/>
		<title type="html"><![CDATA[Problem with bind time in existing script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=48635#p48635"><![CDATA[
Hi everybody!<br><br>I have a working script for announcing the traffic stats of a glftpd with a public trigger here. Now i wanted to modify it so the script announces the monthly traffic every hour in the chan. After looking around a bit I thought a simple 'bind time - "00 * * * *" procname' would do the trick, but it didn't. <br>After searching around the web for several hours I still have no idea where the problem is or how to solve it...<br><br>Here's the script:<div class="codebox"><p>Code: </p><pre><code># v-1.05 22 Feb 05 (21:06:58)# Don't know who the original author is, but I'm releasing this# out with a few fixes to get around looping into negatives above# 2GB when reading k size. -Genocaust# glftpd users directoryset glftpdusers "/glftpd/ftp-data/users"# output themes#  variables:#   $traffick - traffic in kilobytes#   $trafficm - traffic in megabytes#   $trafficg - traffic in gigabytes#   $msgtag   - i just prepend to the outputs to match my bot themeset msgtag          "\002Alcatraz\002 :: \[\002stats \002\]"set gtoutput(all)   {$msgtag \002${trafficg}\002GB have passed through Alcatraz.}set gtoutput(month) {$msgtag While passing through Alcatraz, \002${trafficg}\002GB had an out of body experience this month.}set gtoutput(wk)    {$msgtag \002${trafficg}\002GB saw Elvis this week in Alcatraz.}set gtoutput(day)   {$msgtag Today \002${trafficg}\002GB all agreed that 'if the dick don't fit, you must acquit.'}# triggerset gtcommand "!traffic"# usage is: trigger [day/wk/month/all] - if not period is specified the default will be usedset gtdefault "month"proc gtgltraffic {nick host hand chan arg} {set monthup 0set monthdn 0global msgtagif {[llength [split $arg]]==0} {set period $::gtdefault} else {set period [lindex $arg 0]}if {![info exists ::gtoutput($period)]} {puthelp "PRIVMSG $chan :usage: $::gtcommand \[day/wk/month/all\]"return}foreach user [glob -nocomplain $::glftpdusers/*] {#putlog $userif {[catch {open $user} fp]} {#putlog "glftpd-traffic.tcl: $fp :("continue}set lines [split [read $fp] \n]foreach line $lines {if {[lindex [split $line] 0]=="[string toupper $period]UP"} {#putlog $lineforeach {files size time} [lrange [split $line] 1 end] {if {$size==""} {continue}incr monthup $size}} elseif {[lindex [split $line] 0]=="[string toupper $period]DN"} {#putlog $lineforeach {files size time} [lrange [split $line] 1 end] {if {$size==""} {continue}incr monthdn $size}}}}set traffick [expr wide($monthdn) + wide($monthup)]set trafficm [format %.1f [expr wide($traffick) /1024.0]]set trafficg [format %.1f [expr wide($trafficm) /1024.0]]puthelp "PRIVMSG $chan :[subst -nocommands $::gtoutput($period)]"}bind pub - $gtcommand gtgltrafficputlog "glFTPD Traffic 1.05 loaded"</code></pre></div>Any help is really appreciated.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5806">thedude0001</a> — Wed Apr 27, 2005 7:11 pm</p><hr />
]]></content>
	</entry>
	</feed>
