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

	<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>2009-02-20T19:45:36-04:00</updated>

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

		<entry>
		<author><name><![CDATA[Kaio]]></name></author>
		<updated>2009-02-20T19:45:36-04:00</updated>

		<published>2009-02-20T19:45:36-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=87493#p87493</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=87493#p87493"/>
		<title type="html"><![CDATA[Problem with &quot;timer loop&quot; or topic arg]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=87493#p87493"><![CDATA[
It works! Thank you very much ^^<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10506">Kaio</a> — Fri Feb 20, 2009 7:45 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[nml375]]></name></author>
		<updated>2009-02-20T19:27:44-04:00</updated>

		<published>2009-02-20T19:27:44-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=87492#p87492</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=87492#p87492"/>
		<title type="html"><![CDATA[Problem with &quot;timer loop&quot; or topic arg]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=87492#p87492"><![CDATA[
'k, let me point you in the right direction then:<br><blockquote class="uncited"><div>    (4)  PUB<br>         bind pub &lt;flags&gt; &lt;command&gt; &lt;proc&gt;<br>         procname &lt;nick&gt; &lt;user@host&gt; &lt;handle&gt; &lt;channel&gt; &lt;text&gt;<br><br>         Description: used for commands given on a channel. The first word<br>           becomes the command and everything else is the text argument.<br>         Module: irc</div></blockquote>This means, that when the binding triggers, &lt;proc&gt; will be called with 5 parameters (being <em class="text-italics">nick</em> <em class="text-italics">user@host</em> <em class="text-italics">handle</em> <em class="text-italics">channel</em> and <em class="text-italics">text</em>). Your proc must be able to accept these parameters as arguments...<br><br>In your case, your proc has only 1 argument, which you've called topic. Obviously, that's 4 arguments short of what bind expects, and more important, it's not the order bind expects..<br><br>Hence, bind calls the proc with the wrong number and order of arguments, and you get the error posted.<br><br>Solution?<br>Adjust your proc to accept the proper amount of parameters:<div class="codebox"><p>Code: </p><pre><code>proc yourproc {nickname host handle channel text} {</code></pre></div>Then adjust your proc to make use of these arguments appropriately.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8052">nml375</a> — Fri Feb 20, 2009 7:27 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Kaio]]></name></author>
		<updated>2009-02-20T18:54:06-04:00</updated>

		<published>2009-02-20T18:54:06-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=87490#p87490</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=87490#p87490"/>
		<title type="html"><![CDATA[Problem with &quot;timer loop&quot; or topic arg]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=87490#p87490"><![CDATA[
i noticed...it issnt the timer who does the error... but i cant find out ...<br><br><br>(sorry for the bad english ;P)<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10506">Kaio</a> — Fri Feb 20, 2009 6:54 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[nml375]]></name></author>
		<updated>2009-02-20T16:35:03-04:00</updated>

		<published>2009-02-20T16:35:03-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=87488#p87488</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=87488#p87488"/>
		<title type="html"><![CDATA[Problem with &quot;timer loop&quot; or topic arg]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=87488#p87488"><![CDATA[
Make sure the argument-list in the proc header matches the parameters passed when the binding triggers (see doc/tcl-commands.doc).<br><br>Also, you'll have to modify your utimer-command to pass the very same number of parameters if you intend to use that recursive calling. This would also have to be done in a safe manner, so I'd recommend using lists there.<br>IE:<div class="codebox"><p>Code: </p><pre><code>utimer 30 [list command param1 param2 param3]</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8052">nml375</a> — Fri Feb 20, 2009 4:35 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Kaio]]></name></author>
		<updated>2009-02-20T15:59:10-04:00</updated>

		<published>2009-02-20T15:59:10-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=87485#p87485</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=87485#p87485"/>
		<title type="html"><![CDATA[Problem with &quot;timer loop&quot; or topic arg]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=87485#p87485"><![CDATA[
Teh script: <a href="http://pastebin.com/m2d5a0a1c" class="postlink">http://pastebin.com/m2d5a0a1c</a><br><br>I get this error if i call the script with ?topic_status<br><br>#<br>error:  Tcl error [topic_status]: wrong # args: should be "topic_status topic"<br><br><br><br>I have no idea how to pass the argument or a other method to get the topic title<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10506">Kaio</a> — Fri Feb 20, 2009 3:59 pm</p><hr />
]]></content>
	</entry>
	</feed>
