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

	<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-04-10T09:04:07-04:00</updated>

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

		<entry>
		<author><name><![CDATA[eiSi]]></name></author>
		<updated>2003-04-10T09:04:07-04:00</updated>

		<published>2003-04-10T09:04:07-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=18860#p18860</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=18860#p18860"/>
		<title type="html"><![CDATA[can't get the usercount in channel]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=18860#p18860"><![CDATA[
thx ppslim for this detailed answer!<br>it all works fine now!<br><br>but caesar, also thank you <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=939">eiSi</a> — Thu Apr 10, 2003 9:04 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-04-10T05:34:11-04:00</updated>

		<published>2003-04-10T05:34:11-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=18836#p18836</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=18836#p18836"/>
		<title type="html"><![CDATA[can't get the usercount in channel]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=18836#p18836"><![CDATA[
Uhhm.. yes, ignore my previous post.. This seems to be one a bad day..<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Thu Apr 10, 2003 5:34 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[ppslim]]></name></author>
		<updated>2003-04-10T05:20:28-04:00</updated>

		<published>2003-04-10T05:20:28-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=18834#p18834</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=18834#p18834"/>
		<title type="html"><![CDATA[can't get the usercount in channel]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=18834#p18834"><![CDATA[
No, this is the speed of your script, and parts need to be delayed.<br><br>You are adding a channel, getting a channel count and them removing it, all wihtin the one script cycle.<br><br>1: Adding channels.<br><br>Eggdrop will add the channel and the settings to its internal records and then send the "JOIN #channel" command.<br><br>2: Getting channel count.<br><br>This is where you bot is stuck. When you join a channel, any clinet including eggdrop, will download a list of the users in the channel, the ban list, channel modes and the topic.<br><br>The problem here, eggdrop is in the middle of a script, and can't parse this incoming data, thus doesn't have it on record.<br><br>3: Remove channel<br><br>As above, eggdrop has not yet parsed the incoming data fromt he server, because it is stuck in a script.<br><br>This command removes any information stored in memory about the channel, and then sends a "PART #channel" message to the server.<br><br>The reason you get the "Join but didn't want to", is because of this incoming data that is waiting. Once the above script has finished, the bot will parse this data. The data shows a channel it doesn't know about (more like no longer knows about), so it displays that message.<br><br>There is only one way around this. Delay obtaining a channel count, and delete the channel then.<br><br>This can be done somthing like this<br><div class="codebox"><p>Code: </p><pre><code>proc delaychancount {nick chan} {  get count [llength [chanlist $chan]]  channel remove $chan  notice $nick $count}</code></pre></div>You can now remove the lines that get the count, send the message and remove the channel, from your script, and replace them with 1 single line<br><div class="codebox"><p>Code: </p><pre><code>utimer 5 [list delatchancount $nick $channel]</code></pre></div>This will use a timer to delay the count and removal, allowing eggdrop tiem to parse the script (so long as another script doesn't take too much time).<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2">ppslim</a> — Thu Apr 10, 2003 5:20 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-04-10T03:31:09-04:00</updated>

		<published>2003-04-10T03:31:09-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=18823#p18823</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=18823#p18823"/>
		<title type="html"><![CDATA[can't get the usercount in channel]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=18823#p18823"><![CDATA[
The code seems to be correct.. this sounds like an net-type wrong setting. Review it and change as suits the server he is running better.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Thu Apr 10, 2003 3:31 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[eiSi]]></name></author>
		<updated>2003-04-10T02:47:49-04:00</updated>

		<published>2003-04-10T02:47:49-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=18820#p18820</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=18820#p18820"/>
		<title type="html"><![CDATA[can't get the usercount in channel]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=18820#p18820"><![CDATA[
hi there!<br><br>my problem: the bot doesn't get the usercount in a channel.<br><br>my code:<br><br>set defchanoptions {<br>    chanmode "+t"<br>    idle-kick 0 <br>    need-op { } <br>    need-invite { } <br>    need-key { } <br>    need-unban { } <br>    need-limit { } <br>    flood-chan 30:60 <br>    flood-deop 10:10 <br>    flood-kick 10:10 <br>    flood-join 10:60 <br>    flood-ctcp 10:60<br>}<br><br>...<br>channel add $channel $defchanoptions<br>savechannels<br>set chancount [llength [chanlist $channel]]<br>channel remove $channel<br>savechannels<br>notice $nick $chancount<br>...<br><br>($channel is for example "#mychan")<br><br>the bot also says: joined #mychanbut didn't want to!<br><br>so, what can I do for this to work?<br><br>thanks for any help!<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=939">eiSi</a> — Thu Apr 10, 2003 2:47 am</p><hr />
]]></content>
	</entry>
	</feed>
