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

	<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>2014-07-27T09:03:22-04:00</updated>

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

		<entry>
		<author><name><![CDATA[willyw]]></name></author>
		<updated>2014-07-27T09:03:22-04:00</updated>

		<published>2014-07-27T09:03:22-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=103066#p103066</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=103066#p103066"/>
		<title type="html"><![CDATA[Re: When do I put &quot;return 0&quot;?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=103066#p103066"><![CDATA[
<blockquote class="uncited"><div>...<br>Where is/are the proper place(s) to put a "return 0"?</div></blockquote>That could depend on what you want to happen.<br><br>You'll get a better feel for it, if as Get_A_Fix suggested, you experiment with it.<br><br>In addition the the page that he gave you to read, here's some more good info on the subject, found here:<br><a href="http://www.eggheads.org/support/egghtml/1.6.21/tcl-commands.html#bindb" class="postlink">http://www.eggheads.org/support/egghtml ... html#bindb</a><br><br><br>I hope this helps.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10420">willyw</a> — Sun Jul 27, 2014 9:03 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Get_A_Fix]]></name></author>
		<updated>2014-07-26T19:18:47-04:00</updated>

		<published>2014-07-26T19:18:47-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=103064#p103064</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=103064#p103064"/>
		<title type="html"><![CDATA[When do I put &quot;return 0&quot;?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=103064#p103064"><![CDATA[
Firstly, you have to understand that by declaring the global variable within the procedure, you do not then need to use the global variable in the manner you're calling it.<br><br>For example<div class="codebox"><p>Code: </p><pre><code>  global givechan    if {$chan eq $::givechan} { </code></pre></div>You had already declared global givechan. This means that you just have to do<br><div class="codebox"><p>Code: </p><pre><code>if {$chan eq $givechan} {</code></pre></div>If you do NOT declare the 'global variable' in the proc, then you would use the $::method<br><br>Secondly, for return, check <a href="https://www.tcl.tk/man/tcl8.5/TclCmd/return.htm" class="postlink">this</a> out. It can be a bit confusing, but a lot of the time it's best to just test it yourself, being on partyline with debug. If you add debugging code, it makes it even better so you can see everything that's going on when triggered.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=6204">Get_A_Fix</a> — Sat Jul 26, 2014 7:18 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[daigo]]></name></author>
		<updated>2014-07-26T18:35:24-04:00</updated>

		<published>2014-07-26T18:35:24-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=103063#p103063</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=103063#p103063"/>
		<title type="html"><![CDATA[When do I put &quot;return 0&quot;?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=103063#p103063"><![CDATA[
For example:<br><div class="codebox"><p>Code: </p><pre><code>proc give {nick host hand chan arg} {  global givechan  if {$chan eq $::givechan} {  puthelp "PRIVMSG $givechan :Here is $arg for you"  }  return 0} </code></pre></div>VS.<br><div class="codebox"><p>Code: </p><pre><code>proc give {nick host hand chan arg} {  global givechan  if {$chan eq $::givechan} {  puthelp "PRIVMSG $givechan :Here is $arg for you"  return 0  }} </code></pre></div>VS.<br><br><div class="codebox"><p>Code: </p><pre><code>proc give {nick host hand chan arg} {  global givechan  if {$chan eq $::givechan} {  puthelp "PRIVMSG $givechan :Here is $arg for you"  return 0  }return 0} </code></pre></div>etc.<br><br>Where is/are the proper place(s) to put a "return 0"?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12410">daigo</a> — Sat Jul 26, 2014 6:35 pm</p><hr />
]]></content>
	</entry>
	</feed>
