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

	<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>2004-09-06T08:40:15-04:00</updated>

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

		<entry>
		<author><name><![CDATA[user]]></name></author>
		<updated>2004-09-06T08:40:15-04:00</updated>

		<published>2004-09-06T08:40:15-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=40636#p40636</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=40636#p40636"/>
		<title type="html"><![CDATA[How to make a script that runs on specified time?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=40636#p40636"><![CDATA[
The "day" passed from a time bind is the day of month, so there's no way to easily convert it into day of week. 'clock format' to the rescue...<div class="codebox"><p>Code: </p><pre><code>if {[clock format [clock seconds] -format %u]==7} {it's sunday}</code></pre></div><a href="http://tcl.tk/man/tcl8.5/TclCmd/clock.htm#M36" class="postlink">http://tcl.tk/man/tcl8.5/TclCmd/clock.htm#M36</a><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2878">user</a> — Mon Sep 06, 2004 8:40 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Freez]]></name></author>
		<updated>2004-09-06T08:00:08-04:00</updated>

		<published>2004-09-06T08:00:08-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=40635#p40635</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=40635#p40635"/>
		<title type="html"><![CDATA[How to make a script that runs on specified time?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=40635#p40635"><![CDATA[
Thank you! It works good!<br><br>Do someone know how i can check the day? Not the date! <br>Like this:<br><div class="codebox"><p>Code: </p><pre><code>if ($day == Sunday) then proc</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5363">Freez</a> — Mon Sep 06, 2004 8:00 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[awyeah]]></name></author>
		<updated>2004-09-06T00:31:14-04:00</updated>

		<published>2004-09-06T00:31:14-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=40610#p40610</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=40610#p40610"/>
		<title type="html"><![CDATA[How to make a script that runs on specified time?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=40610#p40610"><![CDATA[
<blockquote class="uncited"><div>It works! I would to like to know how i callup an procedure.<br><br>But how?<br><div class="codebox"><p>Code: </p><pre><code>proc tgstop {nick host hand chan text} {global tghinttimer tgnextqtimer tgplaying tgchan tgcurrentanswer tgstreak tgstreakminglobal tgerrremindtimer tgrebindhinttimerif {[strlwr $tgchan]==[strlwr $chan]} {if {$tgplaying==1} {tggamemsg "[tgcolstop]Triviant is gestopt door $nick!"if {$tgstreakmin&gt;0&amp;&amp;[lindex [split $tgstreak ,] 1]&gt;=$tgstreakmin} { tgstreakend }set tgstreak 0set tgplaying 0catch {unbind pubm -|- "$tgchan *" tgcheckanswer}if {[utimerexists tghint]!=""} {killutimer $tghinttimer}if {[utimerexists tgnextq]!=""} {killutimer $tgnextqtimer}if {[timerexists tgerrremind]!=""} {killtimer $tgerrremindtimer}if {[utimerexists tgrebindhinttimer]!=""} {killtimer $tgrebindhinttimer}}}}</code></pre></div>This is the proc i want to callup. Do you know how? Thank you!<br>[/code]</div></blockquote>To callup another procedure from an existing/running procedure use:<br><blockquote class="uncited"><div>procedure:name arg1 arg2 arg3....argN<br><br>#You will need to set the same number of arguments as in your call procedure when you are calling.<br>#If you want to use a bit of delay to call, you can use timers with 'list'<br><br>utimer $myutimer [list procedure:name arg1 arg2 arg3....argN]<br><br>To call your procedure use:<br>tgstop $nick $host $hand $chan $text<br><br>But remember nick, host, hand, chan and text all have to be defined.</div></blockquote>Hope this helps!  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_wink.gif" width="15" height="15" alt=":wink:" title="Wink"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4875">awyeah</a> — Mon Sep 06, 2004 12:31 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[greenbear]]></name></author>
		<updated>2004-09-02T13:29:23-04:00</updated>

		<published>2004-09-02T13:29:23-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=40545#p40545</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=40545#p40545"/>
		<title type="html"><![CDATA[How to make a script that runs on specified time?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=40545#p40545"><![CDATA[
This will bind it to the public trigger !stop and everyone is able to use it.<div class="codebox"><p>Code: </p><pre><code>bind pub -|- !stop tgstop</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=24">greenbear</a> — Thu Sep 02, 2004 1:29 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Freez]]></name></author>
		<updated>2004-09-02T13:14:40-04:00</updated>

		<published>2004-09-02T13:14:40-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=40543#p40543</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=40543#p40543"/>
		<title type="html"><![CDATA[How to make a script that runs on specified time?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=40543#p40543"><![CDATA[
It works! I would to like to know how i callup an procedure.<br><br>But how?<br><div class="codebox"><p>Code: </p><pre><code>proc tgstop {nick host hand chan text} {global tghinttimer tgnextqtimer tgplaying tgchan tgcurrentanswer tgstreak tgstreakminglobal tgerrremindtimer tgrebindhinttimerif {[strlwr $tgchan]==[strlwr $chan]} {if {$tgplaying==1} {tggamemsg "[tgcolstop]Triviant is gestopt door $nick!"if {$tgstreakmin&gt;0&amp;&amp;[lindex [split $tgstreak ,] 1]&gt;=$tgstreakmin} { tgstreakend }set tgstreak 0set tgplaying 0catch {unbind pubm -|- "$tgchan *" tgcheckanswer}if {[utimerexists tghint]!=""} {killutimer $tghinttimer}if {[utimerexists tgnextq]!=""} {killutimer $tgnextqtimer}if {[timerexists tgerrremind]!=""} {killtimer $tgerrremindtimer}if {[utimerexists tgrebindhinttimer]!=""} {killtimer $tgrebindhinttimer}}}}</code></pre></div>This is the proc i want to callup. Do you know how? Thank you!<br>[/code]<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5363">Freez</a> — Thu Sep 02, 2004 1:14 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[greenbear]]></name></author>
		<updated>2004-09-02T12:43:13-04:00</updated>

		<published>2004-09-02T12:43:13-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=40542#p40542</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=40542#p40542"/>
		<title type="html"><![CDATA[How to make a script that runs on specified time?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=40542#p40542"><![CDATA[
You forgot to add it to the proc.<div class="codebox"><p>Code: </p><pre><code>set tgchan "#triviant"bind time - "* * * * *" timed_modesproc timed_modes {min hour day month year} {global tgchanif {$hour == 18 &amp;&amp; $min == 30} { pushmode $tgchan -mi }if {$hour == 00} { pushmode $tgchan +mi }} </code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=24">greenbear</a> — Thu Sep 02, 2004 12:43 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Freez]]></name></author>
		<updated>2004-09-02T12:28:29-04:00</updated>

		<published>2004-09-02T12:28:29-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=40541#p40541</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=40541#p40541"/>
		<title type="html"><![CDATA[How to make a script that runs on specified time?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=40541#p40541"><![CDATA[
I have this but it don't work... something wrong?<div class="codebox"><p>Code: </p><pre><code>set tgchan "#triviant"bind time - "* * * * *" timed_modes proc timed_modes {min hour day month year} { if {$hour == 18 &amp;&amp; $min == 30} { pushmode $tgchan -mi }if {$hour == 00} { pushmode $tgchan +mi }} </code></pre></div>Update: [18:30] Tcl error [timed_modes]: can't read "tgchan": no such variable<br><br>He can't read the variable but i have specified...<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5363">Freez</a> — Thu Sep 02, 2004 12:28 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[greenbear]]></name></author>
		<updated>2004-09-02T12:22:06-04:00</updated>

		<published>2004-09-02T12:22:06-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=40540#p40540</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=40540#p40540"/>
		<title type="html"><![CDATA[How to make a script that runs on specified time?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=40540#p40540"><![CDATA[
seems like you forgot to declare $tgchan<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=24">greenbear</a> — Thu Sep 02, 2004 12:22 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Freez]]></name></author>
		<updated>2004-09-02T12:20:33-04:00</updated>

		<published>2004-09-02T12:20:33-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=40539#p40539</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=40539#p40539"/>
		<title type="html"><![CDATA[How to make a script that runs on specified time?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=40539#p40539"><![CDATA[
I have try also with minutes, but i don't work. What do i have made wrong?<br><div class="codebox"><p>Code: </p><pre><code>bind time - "* * * * *" timed_modes proc timed_modes {min hour day month year} { if {$hour == 18 &amp;&amp; $min == 20} { pushmode $tgchan -mi }if {$hour == 00} { pushmode $tgchan +mi }} </code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5363">Freez</a> — Thu Sep 02, 2004 12:20 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2004-09-01T09:24:20-04:00</updated>

		<published>2004-09-01T09:24:20-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=40511#p40511</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=40511#p40511"/>
		<title type="html"><![CDATA[Re: How to make a script that runs on specified time?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=40511#p40511"><![CDATA[
<blockquote class="uncited"><div>I would like to excute soms tcl commands at one specified time. <br>Time = 18:00 &gt; set mode $chan +mi<br>Time = 00:00 &gt; set mode $chan -mi</div></blockquote>bind time - "00 * * * *" timed_modes<br>proc timed_modes {min hour day month year} { <br> if {$hour == 18} {pushmode #channel +mi}<br> if {$hour == 00} {pushmode #channel -mi}<br>}<br><br>Belive that should do what ya want.<p>Statistics: Posted by Guest — Wed Sep 01, 2004 9:24 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Freez]]></name></author>
		<updated>2004-09-01T09:16:31-04:00</updated>

		<published>2004-09-01T09:16:31-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=40510#p40510</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=40510#p40510"/>
		<title type="html"><![CDATA[How to make a script that runs on specified time?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=40510#p40510"><![CDATA[
Hi!<br><br>I would like to excute soms tcl commands at one specified time. <br><br>Time = 18:00 &gt; set mode $chan +mi<br>Time = 00:00 &gt; set mode $chan -mi<br><br>But how? I means its with if ($time == 18:00) but i think it don't work. <br><br>Tank You!<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5363">Freez</a> — Wed Sep 01, 2004 9:16 am</p><hr />
]]></content>
	</entry>
	</feed>
