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

	<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>2010-08-20T06:45:13-04:00</updated>

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

		<entry>
		<author><name><![CDATA[Angel]]></name></author>
		<updated>2010-08-20T06:45:13-04:00</updated>

		<published>2010-08-20T06:45:13-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=94023#p94023</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=94023#p94023"/>
		<title type="html"><![CDATA[how to solve this .chanset #chan +/-]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=94023#p94023"><![CDATA[
can someone pls post the final coding of this script please<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11300">Angel</a> — Fri Aug 20, 2010 6:45 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Luminous]]></name></author>
		<updated>2010-08-19T15:39:53-04:00</updated>

		<published>2010-08-19T15:39:53-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=94004#p94004</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=94004#p94004"/>
		<title type="html"><![CDATA[how to solve this .chanset #chan +/-]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=94004#p94004"><![CDATA[
I was a tab unclear myself... looks like nml got it though.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11101">Luminous</a> — Thu Aug 19, 2010 3:39 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Angel]]></name></author>
		<updated>2010-08-19T15:28:24-04:00</updated>

		<published>2010-08-19T15:28:24-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=94003#p94003</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=94003#p94003"/>
		<title type="html"><![CDATA[how to solve this .chanset #chan +/-]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=94003#p94003"><![CDATA[
first post i edited....<br><br>deleted some return added lindex and +bmotion i hope it will do it<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11300">Angel</a> — Thu Aug 19, 2010 3:28 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[nml375]]></name></author>
		<updated>2010-08-19T13:48:23-04:00</updated>

		<published>2010-08-19T13:48:23-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=94002#p94002</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=94002#p94002"/>
		<title type="html"><![CDATA[how to solve this .chanset #chan +/-]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=94002#p94002"><![CDATA[
<div class="codebox"><p>Code: </p><pre><code>set chan [split $text] 0]]</code></pre></div>You lost the lindex command, and you've got a stray ] at the end of the line:<div class="codebox"><p>Code: </p><pre><code>set chan [lindex [split $text] 0]</code></pre></div><div class="codebox"><p>Code: </p><pre><code>if {[channel get $chan "active"]} {  channel set $chan -inactive  return 0}</code></pre></div>This will still cause the script to end before the channel is set +bmotion in case it's set +inactive. It is set -inactive however. I'm not sure if this is the behaviour you intended?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8052">nml375</a> — Thu Aug 19, 2010 1:48 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Angel]]></name></author>
		<updated>2010-08-19T13:43:27-04:00</updated>

		<published>2010-08-19T13:43:27-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=94001#p94001</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=94001#p94001"/>
		<title type="html"><![CDATA[how to solve this .chanset #chan +/-]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=94001#p94001"><![CDATA[
so what will be the coding then?<br><div class="codebox"><p>Code: </p><pre><code>#syntax:/msg bot chanset channel +/-bmotionbind msg n set chanproc chan {nick host hand text} {   set chan [split $text] 0]]   if {![string length $chan]} {      putserv "PRIVMSG $nick :no specified channel."   }   if {[validchan $chan]} {      if {[channel get $chan "active"]} {         channel set $chan -inactive         return 0      }          channel set  $chan +bmotion      putserv "PRIVMSG $nick :$chan bmotion activated."      return 0   }   } </code></pre></div><br>i hope i ddidn't screw the whole yet on this 1....<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11300">Angel</a> — Thu Aug 19, 2010 1:43 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[nml375]]></name></author>
		<updated>2010-08-19T13:28:50-04:00</updated>

		<published>2010-08-19T13:28:50-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=94000#p94000</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=94000#p94000"/>
		<title type="html"><![CDATA[how to solve this .chanset #chan +/-]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=94000#p94000"><![CDATA[
A few more things to fix:<ul><li><strong class="text-strong">lindex</strong> returns a single list item, not a list. Don't use <strong class="text-strong">join</strong> here.</li><li>Whenever you call <strong class="text-strong">return</strong>, the proc will immediately exit without running the following code. Thus, if the channel is +inactive, it will be set -inactive, but the rest of the code will not be executed. If the channel is already -inactive, it will print the "bmotion activated" message and then exit, not executing the <strong class="text-strong">channel set</strong> command further down.</li><li>"+/-setting" is not a valid channel setting, enter the actual setting you are trying to alter (perhaps +bmotion ?).</li></ul><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8052">nml375</a> — Thu Aug 19, 2010 1:28 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Angel]]></name></author>
		<updated>2010-08-19T11:54:56-04:00</updated>

		<published>2010-08-19T11:54:56-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=93997#p93997</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=93997#p93997"/>
		<title type="html"><![CDATA[how to solve this .chanset #chan +/-]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=93997#p93997"><![CDATA[
<div class="codebox"><p>Code: </p><pre><code>#syntax:/msg bot chanset channel +/-bmotionbind msg n set chan proc chan {nick host hand text} {    set chan [join [lindex [split $text] 0]]    if {![string length $chan]} {       putserv "PRIVMSG $nick :no specified channel."       return 0    }    if {[validchan $chan]} {       if {[channel get $chan "inactive"]} {          channel set $chan -inactive          return 0       }       putserv "PRIVMSG $nick :$chan bmotion activated."       return 0    }    channel set  $chan +/-setting} </code></pre></div>already edited but still error and not working <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_sad.gif" width="15" height="15" alt=":(" title="Sad"><br><br>got a headache now figuring out what is wrong<br><br>help please<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11300">Angel</a> — Thu Aug 19, 2010 11:54 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Luminous]]></name></author>
		<updated>2010-08-19T11:02:32-04:00</updated>

		<published>2010-08-19T11:02:32-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=93995#p93995</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=93995#p93995"/>
		<title type="html"><![CDATA[how to solve this .chanset #chan +/-]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=93995#p93995"><![CDATA[
Okay, I see two issues right off the bat. First one is that you have named your proc the name of an already existing proc. I have done this several times myself. "Chanset" is already a dcc command, so that could very well be messing things up for you. Avoid using pre-existing command names for your procs. <br><br>Issues two I see is this: <div class="codebox"><p>Code: </p><pre><code>channel chanset $chan </code></pre></div> <br><br>"Channel chanset" is not a tcl command. I assume you meant to do something like: <div class="codebox"><p>Code: </p><pre><code>channel set $chan -/+setting</code></pre></div>, like you did the first time, when you turned off inactive chanset.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11101">Luminous</a> — Thu Aug 19, 2010 11:02 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Angel]]></name></author>
		<updated>2010-08-19T15:27:20-04:00</updated>

		<published>2010-08-19T10:54:41-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=93994#p93994</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=93994#p93994"/>
		<title type="html"><![CDATA[how to solve this .chanset #chan +/-]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=93994#p93994"><![CDATA[
the syntax +/-bmotion is for example to this script and maybe used for other script too.<br>the use of this is just to msg the bot to do the chanset thing for the script to work on every channel..and no need to go to partyline or telnet the bot..<br><br>been bugging me for a couple of days but i can't get it to work.<br><div class="codebox"><p>Code: </p><pre><code>#syntax:/msg bot chanset channel +/-bmotionbind msg n set chanproc chan {nick host hand text} {   set chan [lindex split $text] 0]   if {![string length $chan]} {      putserv "PRIVMSG $nick :no specified channel."   }   if {[validchan $chan]} {      if {[channel get $chan "active"]} {         channel set $chan +bmotion      }          channel set  $chan +bmotion      putserv "PRIVMSG $nick :$chan bmotion activated."      return 0   }   } </code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11300">Angel</a> — Thu Aug 19, 2010 10:54 am</p><hr />
]]></content>
	</entry>
	</feed>
