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

	<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>2003-08-22T17:42:09-04:00</updated>

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

		<entry>
		<author><name><![CDATA[Feanixxx]]></name></author>
		<updated>2003-08-22T17:42:09-04:00</updated>

		<published>2003-08-22T17:42:09-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=25481#p25481</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=25481#p25481"/>
		<title type="html"><![CDATA[Tiddles the cat ...]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=25481#p25481"><![CDATA[
Yes, that works fine, thank you, I should be able to finish it myself now <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"> Plus my lovelife looks safer ....<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3570">Feanixxx</a> — Fri Aug 22, 2003 5:42 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-08-22T16:24:37-04:00</updated>

		<published>2003-08-22T16:24:37-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=25478#p25478</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=25478#p25478"/>
		<title type="html"><![CDATA[Tiddles the cat ...]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=25478#p25478"><![CDATA[
<div class="codebox"><p>Code: </p><pre><code>set num [rand 4]</code></pre></div>but the result will be a number from 0 to 3, so by transforming it to:<div class="codebox"><p>Code: </p><pre><code>set num [expr [rand 4] +1]</code></pre></div>will become from 1 to 4, bouth included.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Fri Aug 22, 2003 4:24 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[spock]]></name></author>
		<updated>2003-08-22T16:14:18-04:00</updated>

		<published>2003-08-22T16:14:18-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=25477#p25477</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=25477#p25477"/>
		<title type="html"><![CDATA[Tiddles the cat ...]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=25477#p25477"><![CDATA[
set var "[command arg]"<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2369">spock</a> — Fri Aug 22, 2003 4:14 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Feanixxx]]></name></author>
		<updated>2003-08-22T15:59:24-04:00</updated>

		<published>2003-08-22T15:59:24-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=25476#p25476</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=25476#p25476"/>
		<title type="html"><![CDATA[Tiddles the cat ...]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=25476#p25476"><![CDATA[
Hmm, I think I'm getting there, I now have:<br><br># Bindings<br>bind pubm - "% *hello*" Greeting<br>bind pubm - "% *Hello*" Greeting<br><br>proc Greeting {nick uhost hand chan text} {<br>global our_chan<br>if {$chan != $our_chan} {return 0}<br>set num {rand [4]}<br>if {$num == 0} {putserv "PRIVMSG $our_chan :\001ACTION says Hello to $nick"}<br>      return 0<br>}<br><br>Just cannot get the RAND statement working - it sets $num to "rand[4]" rather than a number - any clues, anyone ?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3570">Feanixxx</a> — Fri Aug 22, 2003 3:59 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Feanixxx]]></name></author>
		<updated>2003-08-22T11:28:44-04:00</updated>

		<published>2003-08-22T11:28:44-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=25468#p25468</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=25468#p25468"/>
		<title type="html"><![CDATA[Tiddles the cat ...]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=25468#p25468"><![CDATA[
Hi All <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br><br>I have a pet cat written in mIrc that scans the text input and responds acordingly, with several hundred actions. <br>My girlfriend loves him, of course <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"> I now wish to convert him to eggdrop tcl.<br><br>This is the basic skeleton of the mirc script (just the one word and a couple of responses)<br><br>on 1:text:hello*:#: { /Greeting }<br>on 1:text:hiya*:#: { /Greeting }<br><br>alias Greeting {<br>  /set %bt.rand $rand(1,2)<br>  if (%bt.rand == 1) { .describe $chan purrs happily at $nick }<br>  if (%bt.rand == 2) { .describe $chan gently headbutts $nick }<br>}<br><br><br>And this is what I've come up with so far to say hello as a CTTP Action:<br><br>bind pub - hello my_talk_handler<br>bind pub - Hello my_talk_handler<br><br>proc my_talk_handler {nick uhost hand chan text} {<br>putserv "PRIVMSG $chan :\001ACTION says Hello to $nick"<br>return 0<br>}<br><br>Can anyone point me any further in terms of using PUBM to get the whole text, parsing the text in TCL and so forth?<br><br>My lovelife is at serious risk over this ...........<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3570">Feanixxx</a> — Fri Aug 22, 2003 11:28 am</p><hr />
]]></content>
	</entry>
	</feed>
