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

	<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>2004-01-09T18:39:35-04:00</updated>

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

		<entry>
		<author><name><![CDATA[Buffy_25]]></name></author>
		<updated>2004-01-09T18:39:35-04:00</updated>

		<published>2004-01-09T18:39:35-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32384#p32384</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32384#p32384"/>
		<title type="html"><![CDATA[Putbot problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32384#p32384"><![CDATA[
Hi,<br><br>Thnx for your replies!<br><br>So i can do it like this:<br><br>For bot1:<br><br>bind join - * detect:bot<br>proc detect:bot {nick uhost hand chan}<br>if {islinked &lt;bot2 names&gt;} {<br> if {info exists exists /usr/home/account/eggdrop/logs/usersbackup.txt} {<br>  dccsend /usr/home/account/eggdrop/logs/usersbackup.txt &lt;botname on botlist&gt;<br>}<br>}<br><br><br>For my bot2, i can do the following then:<br><br>bind rcvd - * got:file<br>proc got:file {hand nick path} {<br>-&gt; i will need to move this file to /usr/home/account2/eggdrop/logs/   Any help appreciated<br>-&gt; i need to append this txt file, to the existing txt file in \logs on my bot2  (existing file = usersuptime.txt)   Any help appreciated<br>file delete /usr/home/account2/eggdrop/logs/usersbackup.txt<br>}<br><br><br>Any further help is appreciated.<br><br>Thnx a lot.<br><br>Best regards,<br><br>Buffy<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4178">Buffy_25</a> — Fri Jan 09, 2004 6:39 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2004-01-06T16:09:02-04:00</updated>

		<published>2004-01-06T16:09:02-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32283#p32283</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32283#p32283"/>
		<title type="html"><![CDATA[Putbot problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32283#p32283"><![CDATA[
Yes, it's correct the "islinked $hand"<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Tue Jan 06, 2004 4:09 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Sir_Fz]]></name></author>
		<updated>2004-01-06T15:44:12-04:00</updated>

		<published>2004-01-06T15:44:12-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32278#p32278</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32278#p32278"/>
		<title type="html"><![CDATA[Putbot problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32278#p32278"><![CDATA[
<blockquote class="uncited"><div>im not shure about islinked $hand maybe someone else could give advice on that one.</div></blockquote>always check Tcl-commands.doc:<blockquote class="uncited"><div>  islinked &lt;bot&gt;<br>    Returns: 1 if the bot is currently linked; 0 otherwise<br>    Module: core</div></blockquote>I guess you shouldn't use $hand on islinked.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3085">Sir_Fz</a> — Tue Jan 06, 2004 3:44 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2004-01-06T15:35:28-04:00</updated>

		<published>2004-01-06T15:35:28-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32276#p32276</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32276#p32276"/>
		<title type="html"><![CDATA[Putbot problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32276#p32276"><![CDATA[
Use an "lower case" check like <em class="text-italics">[string tolower $nick] == "bot2"</em><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Tue Jan 06, 2004 3:35 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[TALES]]></name></author>
		<updated>2004-01-06T15:20:12-04:00</updated>

		<published>2004-01-06T15:20:12-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32274#p32274</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32274#p32274"/>
		<title type="html"><![CDATA[Putbot problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32274#p32274"><![CDATA[
This looks a little insecure<div class="codebox"><p>Code: </p><pre><code>if {$nick == "bot2"} {</code></pre></div>maybe some more check before sending the file<div class="codebox"><p>Code: </p><pre><code>if {$nick =="bot2" &amp;&amp; [matchattr $hand b] &amp;&amp; [islinked $hand]} {</code></pre></div>im not shure about islinked $hand maybe someone else could give advice on that one.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4104">TALES</a> — Tue Jan 06, 2004 3:20 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[CrazyCat]]></name></author>
		<updated>2004-01-06T14:21:23-04:00</updated>

		<published>2004-01-06T14:21:23-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32273#p32273</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32273#p32273"/>
		<title type="html"><![CDATA[Putbot problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32273#p32273"><![CDATA[
I don't read all your tcl, put reading a file line per line and transmit it is quite slow...<br>why don't you use dcc and file transfert components?<br>get a local copy of your file by a file transfert, and then append the copy to your main file...<br><br>And be carrefull:<br>you have <strong class="text-strong">bind bot - "!Transferftpinfo" ftp:transferinfo<br>bind bot - "!Transferuserinfo" user:transferinfo</strong><br>and next lines are<br><strong class="text-strong">proc ftp:transerinfo {botnick command arg} {<br>proc user:transerinfo {botnick command arg} {</strong><br>transferinfo != transerinfo , a "f" is missing<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=691">CrazyCat</a> — Tue Jan 06, 2004 2:21 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Buffy_25]]></name></author>
		<updated>2004-01-06T12:53:55-04:00</updated>

		<published>2004-01-06T12:53:55-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=32267#p32267</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=32267#p32267"/>
		<title type="html"><![CDATA[Putbot problem]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=32267#p32267"><![CDATA[
Hi, <br><br>I have two bots in my channel. Bot1 and Bot2 (on two different shells) <br>When one is connected, and the second one connects to the network, they get linked immidiately (botattr +h). <br>What i would like to do: <br>I have on bot1 some information in txt file, that i would like to transfer to bot2 when bot2 connects to the channel. <br><br>For bot1 i have the following: <br><br>bind join - * detect:bot <br><br>proc detect:bot {nick uhost hand chan} { <br>if {$nick == "bot2"} { <br>timer 45 { <br>set file [open /usr/home/account/eggdrop/logs/user.txt r] <br>set buf [read $file] <br>foreach line [split $buf \n] { <br>set line [string trim $line " "] <br>if {$line == ""} {continue} <br>putallbots !Transferuserinfo $line <br>} <br>set file [open /usr/home/account/eggdrop/logs/ftp.txt r] <br>set buf1 [read $file] <br>foreach line [split $buf1 \n] { <br>set line [string trim $line " "] <br>if {$line == ""} {continue} <br>putallbots !Transferftpinfo $line <br>} <br>timer 60 { file delete /usr/home/account/eggdrop/logs/user.txt <br>file delete /usr/home/account/eggdrop/logs/ftp.txt } <br>} <br>} <br>} <br><br><br>For my bot2 i have the following: <br>bind bot - "!Transferftpinfo" ftp:transferinfo <br>bind bot - "!Transferuserinfo" user:transferinfo <br><br>proc ftp:transerinfo {botnick command arg} { <br>set file [open /home/account/eggdrop/logs/ftpsuptime.txt a+] <br>puts $file "$arg" <br>close $file <br>} <br><br>proc user:transerinfo {botnick command arg} { <br>set file [open /home/account/eggdrop/logs/usersuptime.txt a+] <br>puts $file "$arg" <br>close $file <br>} <br><br>I tried this, and i get no response at all...and no errors. Is there something wrong with it? <br>Additionaly, Is this the right way to transfer txt info from one bot to the other one? <br>Thnx in advance. <br><br>Best regards, <br>Buffy<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4178">Buffy_25</a> — Tue Jan 06, 2004 12:53 pm</p><hr />
]]></content>
	</entry>
	</feed>
