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

	<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-03-16T17:00:41-04:00</updated>

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

		<entry>
		<author><name><![CDATA[Dark_Aaron]]></name></author>
		<updated>2009-03-16T17:00:41-04:00</updated>

		<published>2009-03-16T17:00:41-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=87888#p87888</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=87888#p87888"/>
		<title type="html"><![CDATA[!topic &amp; !status commands]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=87888#p87888"><![CDATA[
<blockquote class="uncited"><div>Ok now i have another question lol. Is there a way to make it so the commands only work on one channel?</div></blockquote><div class="codebox"><p>Code: </p><pre><code>proc status:proc { nick host hand chan text } {  global status topic  if {[$nick isop $chan]} {    if {[$chan == &lt;yourchan&gt;]} {     set status $text     putserv "TOPIC $chan :$topic / SL0RD $status"  }}</code></pre></div>UNTESTED<br><br>im guessing that how u do it idk<br><br>have i seen u b4 on WR<strong class="text-strong"><span style="text-decoration:underline"></span></strong><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10550">Dark_Aaron</a> — Mon Mar 16, 2009 5:00 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[SL0RD]]></name></author>
		<updated>2008-10-07T17:10:48-04:00</updated>

		<published>2008-10-07T17:10:48-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=85455#p85455</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=85455#p85455"/>
		<title type="html"><![CDATA[!topic &amp; !status commands]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=85455#p85455"><![CDATA[
Ok now i have another question lol. Is there a way to make it so the commands only work on one channel?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10253">SL0RD</a> — Tue Oct 07, 2008 5:10 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[SL0RD]]></name></author>
		<updated>2008-10-07T16:17:54-04:00</updated>

		<published>2008-10-07T16:17:54-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=85452#p85452</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=85452#p85452"/>
		<title type="html"><![CDATA[!topic &amp; !status commands]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=85452#p85452"><![CDATA[
ok thanks a lot it works now W00T!<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10253">SL0RD</a> — Tue Oct 07, 2008 4:17 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[nml375]]></name></author>
		<updated>2008-10-07T15:24:21-04:00</updated>

		<published>2008-10-07T15:24:21-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=85451#p85451</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=85451#p85451"/>
		<title type="html"><![CDATA[!topic &amp; !status commands]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=85451#p85451"><![CDATA[
There is a slight flaw in both procs..<br>In tcl, the command always comes first followed by the parameter lines; hence the following line is incorrect:<div class="codebox"><p>Code: </p><pre><code>if {[$nick isop $chan]} {</code></pre></div>The proper way of doing it is this way:<div class="codebox"><p>Code: </p><pre><code>if {[isop $nick $chan]} {</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8052">nml375</a> — Tue Oct 07, 2008 3:24 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[SL0RD]]></name></author>
		<updated>2008-10-07T15:12:12-04:00</updated>

		<published>2008-10-07T15:12:12-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=85450#p85450</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=85450#p85450"/>
		<title type="html"><![CDATA[!topic &amp; !status commands]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=85450#p85450"><![CDATA[
Ok this is starting to make sense to me but I am getting an error could anyone help right it?<div class="codebox"><p>Code: </p><pre><code># Here are our on *:TEXT.... basically, we need bind which is equivilent to on. then we have the flags.. so if we want to restrict it to friends on the bot we would have f then we have what it triggers on.. so "!topic" then we have the alias name it will run. which is topic:procbind pub m|m "!topic" topic:cmdbind pub m|m "!status" status:cmd# Have our aliases.....proc topic:cmd { nick host hand chan text } {  global topic status  if {[$nick isop $chan]} {    set topic $text    putserv "TOPIC $chan :$text / SL0RD $status"  }}proc status:cmd { nick host hand chan text } {  global status topic  if {[$nick isop $chan]} {    set status $text    putserv "TOPIC $chan :$topic / SL0RD $status"  }} </code></pre></div>Now when i do "!topic testing" for example in the channel i get this error in the terminal that i am running the bot it (my nick on irc is SL0RD)<br><div class="codebox"><p>Code: </p><pre><code>Tcl error [topic:cmd]: invalid command name "SL0RD"</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10253">SL0RD</a> — Tue Oct 07, 2008 3:12 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Furbs]]></name></author>
		<updated>2008-10-06T02:31:59-04:00</updated>

		<published>2008-10-06T02:31:59-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=85431#p85431</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=85431#p85431"/>
		<title type="html"><![CDATA[Re: !topic &amp; !status commands]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=85431#p85431"><![CDATA[
<blockquote class="uncited"><div>I currently have an mirc bot, but i am trying to change everything over to eggdrop but i don't really understand the tcl scripting, i am learning though. On my mIRC bot i have a topic script, with two commands !topic and !status. !topic will change one part of the topic and !status changes the other. It looks like this:<div class="codebox"><p>Code: </p><pre><code>on 1:TEXT:!topic *:#:{  if ( $nick !isop $chan) { msg $chan Command Ignored (Must be OP) }  else {    /set %topic $2- | /topic $chan Topic: %topic / SL0RD %status   } }on *:TEXT:!status *:#:{  if ( $nick !isop $chan) { msg $chan Command Ignored (Must be OP) }  else {    /set %status $2- | /topic $chan  Topic: %topic / SL0RD %status  }}</code></pre></div> I was wondering if there is anyway to do this in eggdrop. I have searched for hours and haven't came up with anything close. Any help would be muchly appreciated.</div></blockquote>I'll get you startedish....<br><div class="codebox"><p>Code: </p><pre><code># Here are our on *:TEXT.... basically, we need bind which is equivilent to on. then we have the flags.. so if we want to restrict it to friends on the bot we would have f then we have what it triggers on.. so "!topic" then we have the alias name it will run. which is topic:procbind - "!topic" topic:procbind - "!status" status:proc# Just set the two things to nothing atm.set topic ""set status ""# Have our aliases.....proc topic:proc { nick host hand chan text } {  global topic status  if {[$nick isop $chan]} {    set topic $text    putserv "TOPIC $chan :$text / SL0RD $status"  }}proc status:proc { nick host hand chan text } {  global status topic  if {[$nick isop $chan]} {    set status $text    putserv "TOPIC $chan :$topic / SL0RD $status"  }}</code></pre></div><strong class="text-strong"><span style="text-decoration:underline">UNTESTED</span></strong><br><br>Not the best, but it should work<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10242">Furbs</a> — Mon Oct 06, 2008 2:31 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[SL0RD]]></name></author>
		<updated>2008-10-05T12:04:08-04:00</updated>

		<published>2008-10-05T12:04:08-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=85424#p85424</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=85424#p85424"/>
		<title type="html"><![CDATA[!topic &amp; !status commands]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=85424#p85424"><![CDATA[
I currently have an mirc bot, but i am trying to change everything over to eggdrop but i don't really understand the tcl scripting, i am learning though. On my mIRC bot i have a topic script, with two commands !topic and !status. !topic will change one part of the topic and !status changes the other. It looks like this:<div class="codebox"><p>Code: </p><pre><code>on 1:TEXT:!topic *:#:{  if ( $nick !isop $chan) { msg $chan Command Ignored (Must be OP) }  else {    /set %topic $2- | /topic $chan Topic: %topic / SL0RD %status   } }on *:TEXT:!status *:#:{  if ( $nick !isop $chan) { msg $chan Command Ignored (Must be OP) }  else {    /set %status $2- | /topic $chan  Topic: %topic / SL0RD %status  }}</code></pre></div> I was wondering if there is anyway to do this in eggdrop. I have searched for hours and haven't came up with anything close. Any help would be muchly appreciated.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10253">SL0RD</a> — Sun Oct 05, 2008 12:04 pm</p><hr />
]]></content>
	</entry>
	</feed>
