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

	<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>2006-05-09T06:03:54-04:00</updated>

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

		<entry>
		<author><name><![CDATA[iamdeath]]></name></author>
		<updated>2006-05-09T06:03:54-04:00</updated>

		<published>2006-05-09T06:03:54-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62830#p62830</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62830#p62830"/>
		<title type="html"><![CDATA[variable not found.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62830#p62830"><![CDATA[
That work, thanks alot <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br>Thanks once again.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5982">iamdeath</a> — Tue May 09, 2006 6:03 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Sir_Fz]]></name></author>
		<updated>2006-05-08T19:36:45-04:00</updated>

		<published>2006-05-08T19:36:45-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62812#p62812</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62812#p62812"/>
		<title type="html"><![CDATA[variable not found.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62812#p62812"><![CDATA[
What I mean is something like this:<div class="codebox"><p>Code: </p><pre><code>set ac(chan) "#channel"set notifyusers "owner"set ac(bot_username) "botusername"set ac(owner_username) "ownerusername"bind dcc n bonus ac:bonusbind notc - "USER: * ACCESS: *" ac:bonus_pointsproc ac:bonus {hand idx arg} { global ac baccess set text [split $text] set username1 [lindex $text 0] set reason1 [lrange $text 1 end] if {$username1 == ""} { putdcc $idx "Syntax: .bonus &lt;CService Username&gt; &lt;Reason&gt;"; return } if {$username1 == "$ac(bot_username)"} { putdcc $idx "You can't bonus me or I can't modify myself."; return } if {$username1 == "$ac(owner_username)"} { putdcc $idx "Do you think $ac(owner_username) needs modification?, get a life."; return } if {$reason1 == ""} { putdcc $idx "Syntax: .bonus &lt;CService Username&gt; &lt;Reason&gt;. You're required to mention reason for bonus."; return } puthelp "PRIVMSG X :ACCESS $ac(chan) $username1" set baccess([string tolower $username1]) [list $hand $reason1]}proc ac:bonus_points {nick uhost hand arg dest} { global ac baccess notifyusers if {![isbotnick $dest]} {return 0} if {![string equal -nocase X $nick]} {return 0} set user [string tolower [lindex [split $arg] 1]] if {![info exists baccess($user)]} {return 0} foreach {handle reason} $baccess($user) {break} set access [lindex [split $arg] 3] puthelp "PRIVMSG X :MODINFO $ac(chan) ACCESS $user [expr {$access + 5}]" if {$notifyusers != "" &amp;&amp; $notifyusers != " "} {  foreach notfuser $notifyusers {   sendnote IDA_SYSTEM $notfuser "Bonus +5 given to $user by $handle in $ac(chan). The reason was: $reason"  } }}</code></pre></div>Note that baccess is being used as an array here, so you might want to .restart after loading this (or .tcl unset baccess before loading).<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3085">Sir_Fz</a> — Mon May 08, 2006 7:36 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[iamdeath]]></name></author>
		<updated>2006-05-08T05:58:47-04:00</updated>

		<published>2006-05-08T05:58:47-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62797#p62797</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62797#p62797"/>
		<title type="html"><![CDATA[variable not found.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62797#p62797"><![CDATA[
<div class="codebox"><p>Code: </p><pre><code>set baccess ""</code></pre></div>This works fine, do you think that's right?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5982">iamdeath</a> — Mon May 08, 2006 5:58 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Sir_Fz]]></name></author>
		<updated>2006-05-07T17:25:20-04:00</updated>

		<published>2006-05-07T17:25:20-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62781#p62781</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62781#p62781"/>
		<title type="html"><![CDATA[variable not found.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62781#p62781"><![CDATA[
What you need to do, iamdeath, is issue the service command when the dcc command is triggered. Then, you wait for the notice and perform the needed action. Ofcourse you will need a variable which will contain the needed info for the notc proc to process it.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3085">Sir_Fz</a> — Sun May 07, 2006 5:25 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[iamdeath]]></name></author>
		<updated>2006-05-07T17:04:12-04:00</updated>

		<published>2006-05-07T17:04:12-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62780#p62780</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62780#p62780"/>
		<title type="html"><![CDATA[variable not found.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62780#p62780"><![CDATA[
I did;nt get your point, sorry ;/<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5982">iamdeath</a> — Sun May 07, 2006 5:04 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[De Kus]]></name></author>
		<updated>2006-05-07T15:04:15-04:00</updated>

		<published>2006-05-07T15:04:15-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62776#p62776</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62776#p62776"/>
		<title type="html"><![CDATA[variable not found.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62776#p62776"><![CDATA[
well, how do you know whos baccess is in the var anyway? the expr expression is calculated before the access request leaves your bot, so there will of course be no reply yet either. You must include this calculation within the proc which handles the feedbacks. you should then of course also read whos feedback you are getting and, if you actually wanted to modify it (you never know when someone might make your bot to recieve a reply).<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2382">De Kus</a> — Sun May 07, 2006 3:04 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[iamdeath]]></name></author>
		<updated>2006-05-07T14:07:00-04:00</updated>

		<published>2006-05-07T14:07:00-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62772#p62772</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62772#p62772"/>
		<title type="html"><![CDATA[variable not found.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62772#p62772"><![CDATA[
Did'nt work actually, the actuall access of tht person was 300 so the bot was supposed to add 5 but the bot makes it "5" the whole removed 300 <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_razz.gif" width="15" height="15" alt=":P" title="Razz"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5982">iamdeath</a> — Sun May 07, 2006 2:07 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Sir_Fz]]></name></author>
		<updated>2006-05-07T11:13:09-04:00</updated>

		<published>2006-05-07T11:13:09-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62758#p62758</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62758#p62758"/>
		<title type="html"><![CDATA[variable not found.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62758#p62758"><![CDATA[
<div class="codebox"><p>Code: </p><pre><code>set ac(chan) "#channel"set notifyusers "owner"set ac(bot_username) "botusername"set ac(owner_username) "ownerusername"set baccess 0 ;# initialized baccess to 0</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3085">Sir_Fz</a> — Sun May 07, 2006 11:13 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[iamdeath]]></name></author>
		<updated>2006-05-07T09:47:13-04:00</updated>

		<published>2006-05-07T09:47:13-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62750#p62750</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62750#p62750"/>
		<title type="html"><![CDATA[variable not found.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62750#p62750"><![CDATA[
could you please give me an idea how could I do that?<br>Thanks<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5982">iamdeath</a> — Sun May 07, 2006 9:47 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Sir_Fz]]></name></author>
		<updated>2006-05-07T08:59:01-04:00</updated>

		<published>2006-05-07T08:59:01-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62747#p62747</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62747#p62747"/>
		<title type="html"><![CDATA[variable not found.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62747#p62747"><![CDATA[
In your code, baccess is set only when the bot recieves a notice. What you need to do is initialize to some number (probably 0) outside the procs.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3085">Sir_Fz</a> — Sun May 07, 2006 8:59 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[iamdeath]]></name></author>
		<updated>2006-05-07T14:24:54-04:00</updated>

		<published>2006-05-07T08:55:45-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=62746#p62746</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=62746#p62746"/>
		<title type="html"><![CDATA[variable not found.]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=62746#p62746"><![CDATA[
I am trying to write a small DCC code, in which I will type<br>.bonus username reason<br>That will add +5 of the current access of a username in X (Undernet)<br><div class="codebox"><p>Code: </p><pre><code>set ac(chan) "#channel"set notifyusers "owner"set ac(bot_username) "botusername"set ac(owner_username) "ownerusername"bind notc - "USER: * ACCESS: *" ac:bonus_pointsbind dcc n bonus ac:bonusproc ac:bonus_points {nick uhost hand text dest} {set text [split $text]set baccess [lindex $text 3]}proc ac:bonus { handle idx text } {global ac user_names notifyusers baccessset text [split $text]set username1 [lindex $text 0]set reason1 [lrange $text 1 end]if {$username1 == ""} { putdcc $idx "Syntax: .bonus &lt;CService Username&gt; &lt;Reason&gt;"; return }if {$username1 == "$ac(bot_username)"} { putdcc $idx "You can't bonus me or I can't modify myself."; return }if {$username1 == "ac(owner_username)"} { putdcc $idx "Do you think $ac(owner_username) needs modification?, get a life."; return } if {$reason1 == ""} { putdcc $idx "Syntax: .bonus &lt;CService Username&gt; &lt;Reason&gt;. You're required to mention reason for bonus."; return }puthelp "PRIVMSG X :ACCESS $ac(chan) $username1"puthelp "PRIVMSG X :MODINFO $ac(chan) ACCESS $username1 [expr $baccess + 5]"if {$notifyusers != "" &amp;&amp; $notifyusers != " "} {foreach notfuser $notifyusers {sendnote IDA_SYSTEM $notfuser "Bonus +5 given to $username1 by $handle in $ac(chan). The reason was: $reason1"}}}</code></pre></div>but I am getting this error.<br><div class="codebox"><p>Code: </p><pre><code>[17:54] Tcl error [ac:bonus]: can't read "baccess": no such variable</code></pre></div>normal X reply when someone types: /msg x access #Channel username<div class="codebox"><p>Code: </p><pre><code>-X- USER: cricket ACCESS: 400 LU-X- CHANNEL: #Cricket -- AUTOMODE: OP-X- LAST SEEN: 0 days, 00:07:16 ago.-X- LAST MODIFIED: (iamdeath) |AmDeAtH!~iamdeath@iamdeath.users.undernet.org (1 day, 21:12:14 ago)-X- End of access list</code></pre></div>Can you suggest me. <br>Thanks.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5982">iamdeath</a> — Sun May 07, 2006 8:55 am</p><hr />
]]></content>
	</entry>
	</feed>
