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

	<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-01-15T07:07:20-04:00</updated>

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

		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-01-15T07:07:20-04:00</updated>

		<published>2003-01-15T07:07:20-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15342#p15342</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15342#p15342"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15342#p15342"><![CDATA[
I have also noticed that the user is not removed from the list and fixed that. Seems that someone forgot to add them. <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br><br>So, how to fix the bold thinghie then?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Wed Jan 15, 2003 7:07 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-01-15T06:47:11-04:00</updated>

		<published>2003-01-15T06:47:11-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15338#p15338</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15338#p15338"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15338#p15338"><![CDATA[
Oups.. You are right, as usualy.. :]<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Wed Jan 15, 2003 6:47 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[ppslim]]></name></author>
		<updated>2003-01-15T06:42:23-04:00</updated>

		<published>2003-01-15T06:42:23-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15337#p15337</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15337#p15337"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15337#p15337"><![CDATA[
No - it is the way Tcl handles lists.<br><br>Lists are handled as is, without any normal subtitution.<br><br>IE.<br><div class="codebox"><p>Code: </p><pre><code>set list {hello $nick, \002how\002 are you [time]}set string "hello $nick, \002how\002 are you [time]"</code></pre></div>In the above, the $string varialbe will be correct, with both the $nick, the codes correctly translated and the command "time" replaced with whatever it returns.<br><br>Lists however, are considered lieraly. IE, $ nick is considered a word, and not a variable, and should be placed as is. The same applies to the codes.<br><br>The "subst" command can be used to get around this, and will make the substitution on demand, rather than the time the variable is set.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2">ppslim</a> — Wed Jan 15, 2003 6:42 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-01-15T06:39:31-04:00</updated>

		<published>2003-01-15T06:39:31-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15336#p15336</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15336#p15336"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15336#p15336"><![CDATA[
When the welcome msg is like this: "You are number \002!number!\002 in line." It dosen't return the value of !number! Ex: You are number \002!number!\002 in line. <br><br>When the welcome msg is like this: "You are number \002 !number! \002 in line." It dosen't get number with bold and is the same till now. Ex: "You are number \0021 \002 in line."<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Wed Jan 15, 2003 6:39 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-01-15T06:34:11-04:00</updated>

		<published>2003-01-15T06:34:11-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15335#p15335</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15335#p15335"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15335#p15335"><![CDATA[
As I can see the next:moretools:replace proc is 'eating' them..<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Wed Jan 15, 2003 6:34 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[ppslim]]></name></author>
		<updated>2003-01-15T06:32:50-04:00</updated>

		<published>2003-01-15T06:32:50-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15334#p15334</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15334#p15334"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15334#p15334"><![CDATA[
Find the proc next:moretools:replace<br><br>At the end of it, you have "return $text"<br><br>Change this to<blockquote class="uncited"><div>return [subst $text]</div></blockquote><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2">ppslim</a> — Wed Jan 15, 2003 6:32 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-01-15T06:25:04-04:00</updated>

		<published>2003-01-15T06:25:04-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15331#p15331</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15331#p15331"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15331#p15331"><![CDATA[
Nope. Same thing happens. "You are number \002 1 \002 in line."<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Wed Jan 15, 2003 6:25 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[ppslim]]></name></author>
		<updated>2003-01-15T06:20:55-04:00</updated>

		<published>2003-01-15T06:20:55-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15330#p15330</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15330#p15330"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15330#p15330"><![CDATA[
Change the line in the next(welcome) setting from<blockquote class="uncited"><div>You are number \002!number!\002 in line. NO colours</div></blockquote>to<blockquote class="uncited"><div>You are number\002 !number! \002in line. NO colours</div></blockquote><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2">ppslim</a> — Wed Jan 15, 2003 6:20 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-01-15T06:17:20-04:00</updated>

		<published>2003-01-15T06:17:20-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15329#p15329</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15329#p15329"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15329#p15329"><![CDATA[
Seems that we have fixed the problem. Thanks. How to fix this thing: "You are number \0021\002 in line". The number 1 should be with bold and is not. Where is the problem?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Wed Jan 15, 2003 6:17 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[ppslim]]></name></author>
		<updated>2003-01-15T05:56:33-04:00</updated>

		<published>2003-01-15T05:56:33-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15326#p15326</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15326#p15326"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15326#p15326"><![CDATA[
OK - From your posting, it has become self evident what the issue is. It seems the list is being malformed. Those values should be on one line, rather than 2.<br><br>I have found the issue from this.<br><br>When the first person is added to the list, the script will select between using the "set" or "lappend" commands, based on if the list for that channel exists.<br><br>The problem is, it uses "set" if the list doesn't exist.<br><br>To fix this, we can hardcode it to use "lappend", which creates the list if need be.<br><br>Find and locate the "next:cmds" proc. The first switch method is add_list. Within this segment, locate the 2 line<br><div class="codebox"><p>Code: </p><pre><code>set temp(cmd) [expr {![info exists next(:list:$channel)]?"set":"lappend"}]$temp(cmd) next(:list:$channel) [list $nick [clock seconds]]</code></pre></div>Change them to the following<div class="codebox"><p>Code: </p><pre><code>lappend next(:list:$channel) [list $nick [clock seconds]]</code></pre></div>AKA, delete the first line (can be done with CTRL+K while on the line in pico), and change the first part of the second command.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2">ppslim</a> — Wed Jan 15, 2003 5:56 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-01-15T05:43:38-04:00</updated>

		<published>2003-01-15T05:43:38-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15324#p15324</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15324#p15324"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15324#p15324"><![CDATA[
I've used this code:<br><br>bind pub n .users list:users<br><br>proc list:users {nick host hand chan arg} {<br>global next<br>set temp(list) [next:cmds get_list $chan] <br>foreach element $temp(list) { <br>putlog "Element on list: $element" <br> } <br>}<br><br>and here is what I got:<br>[11:40] Element on list: moo<br>[11:40] Element on list: 1042623583<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Wed Jan 15, 2003 5:43 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-01-14T12:25:03-04:00</updated>

		<published>2003-01-14T12:25:03-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15315#p15315</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15315#p15315"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15315#p15315"><![CDATA[
Well I didn't had a problem with the duration till I've upgraded my eggdrop to 1.6.13, so I think there is not an problem with the list. Anyway I'll test if the list is well made as should be done.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Tue Jan 14, 2003 12:25 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[egghead]]></name></author>
		<updated>2003-01-14T12:01:13-04:00</updated>

		<published>2003-01-14T12:01:13-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15312#p15312</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15312#p15312"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15312#p15312"><![CDATA[
<blockquote class="uncited"><div>Oh and..<br><br>A1: yes and on other commands that use "duration".<br><br>A2: It seems to work fine, I'm getting the error only when I use one of the commands that use "duration".</div></blockquote>Caesar, there are 2 instances in your script where the "temp(duration)" is computed just after you have created the list  by using "set temp(list) [next:cmds get_list $chan]".<br><br>By adding putlog statements can you inspect that this list is a proper list? Like as follows:<br><div class="codebox"><p>Code: </p><pre><code>set temp(list) [next:cmds get_list $chan]foreach element $temp(list) {   putlog "Element on list: $element"}</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=282">egghead</a> — Tue Jan 14, 2003 12:01 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-01-14T11:14:33-04:00</updated>

		<published>2003-01-14T11:14:33-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15309#p15309</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15309#p15309"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15309#p15309"><![CDATA[
Oh and..<br><br>A1: yes and on other commands that use "duration".<br><br>A2: It seems to work fine, I'm getting the error only when I use one of the commands that use "duration". Normal users and helpers join the channel and the normal ones recive the notice (as shoud do) and the helpers recive an voice (again like should do).<br><br>Commands that use the "duration": .next and .list<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Tue Jan 14, 2003 11:14 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[ppslim]]></name></author>
		<updated>2003-01-14T11:13:29-04:00</updated>

		<published>2003-01-14T11:13:29-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=15308#p15308</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=15308#p15308"/>
		<title type="html"><![CDATA[premature end of expression?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=15308#p15308"><![CDATA[
I havn't sugested that you get the error when they join.<br><br>The error occurs when a list is requested.<br><br>I need to know, where the data (or lack of) is coming from, that cuases it.<br><br>Information is changed, when a user joins, quits, parts or changes nicknames.<br><br>It is at these times the data becomes currept, but which one.<br><br>As such, you need to force it to send a list, each time of of these events occurs, and state after whcih one it occurs.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2">ppslim</a> — Tue Jan 14, 2003 11:13 am</p><hr />
]]></content>
	</entry>
	</feed>
