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

	<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>2005-06-20T19:02:26-04:00</updated>

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

		<entry>
		<author><name><![CDATA[Sir_Fz]]></name></author>
		<updated>2005-06-20T19:02:26-04:00</updated>

		<published>2005-06-20T19:02:26-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=51142#p51142</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=51142#p51142"/>
		<title type="html"><![CDATA[show whos active]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=51142#p51142"><![CDATA[
if you add <div class="codebox"><p>Code: </p><pre><code>global whoson</code></pre></div>to the proc then you can use $whoson in the proc since it became a global variable. while if you don't add the global line, you can use $::whoson or ::whoson for set...etc<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3085">Sir_Fz</a> — Mon Jun 20, 2005 7:02 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[kanibus]]></name></author>
		<updated>2005-06-20T18:18:45-04:00</updated>

		<published>2005-06-20T18:18:45-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=51141#p51141</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=51141#p51141"/>
		<title type="html"><![CDATA[show whos active]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=51141#p51141"><![CDATA[
so now if i were to write binds to remove on quit and part how could i make the list global so that i can use it in other processes. i tried naming it ::whoson and global ::whoson but its still not grabbing the list.<br>now im not sure if this is going to slow the bot down a lot by checking on every part and quit so any advice is more than welcomed, thanks again in advance <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"> here is what i had written<div class="codebox"><p>Code: </p><pre><code>bind part - * leavebind sign - * signoffproc leave {nick uhost hand chan {reason ""}} { global ::whoson  if {[set nickindex [lsearch -exact $::whoson $nick]] != -1} {   set ::whoson [lreplace $::whoson $nickindex $nickindex]  }}proc signoff {nick uhost hand chan reason} {global ::whoson  if {[set nickindex [lsearch -exact $::whoson $nick]] != -1} {   set ::whoson [lreplace $::whoson $nickindex $nickindex]  }}</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=6186">kanibus</a> — Mon Jun 20, 2005 6:18 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[kanibus]]></name></author>
		<updated>2005-06-16T17:41:44-04:00</updated>

		<published>2005-06-16T17:41:44-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=50897#p50897</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=50897#p50897"/>
		<title type="html"><![CDATA[show whos active]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=50897#p50897"><![CDATA[
thanks sir_fz, you never cease to amaze me <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=6186">kanibus</a> — Thu Jun 16, 2005 5:41 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Sir_Fz]]></name></author>
		<updated>2005-06-16T17:07:52-04:00</updated>

		<published>2005-06-16T17:07:52-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=50893#p50893</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=50893#p50893"/>
		<title type="html"><![CDATA[show whos active]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=50893#p50893"><![CDATA[
<div class="codebox"><p>Code: </p><pre><code>bind pubm - * triggers proc triggers {nick uhost hand chan arg} {  global whoson if {![isop $nick $chan]} {return 0} set trigger [lindex [split $arg] 0]  if {![info exists whoson]} {set whoson [list]} switch -exact -- [string tolower $trigger] {   "!on" {    if {[lsearch -exact $whoson $nick] == -1} {    lappend whoson $nick     putquick "NOTICE $nick :You've been added to the 'on-line' list."   } {    putquick "NOTICE $nick :You already are on my 'on-line' list."   }  }   "!off" {    if {[set nickindex [lsearch -exact $whoson $nick]] != -1} {     set whoson [lreplace $whoson $nickindex $nickindex]     putquick "NOTICE $nick :You've been removed to the 'on-line' list. later!"    } {    putquick "NOTICE $nick :You're not on my 'on-line' list."   }  }   "!liston" {    if {[llength $whoson] != 0} {    putquick "NOTICE $nick :/0030,1d/0037,1D/0030,1ect members online:"     foreach online $whoson {      putquick "NOTICE $nick :$online"     }   } {    putquick "NOTICE $nick :There are no users oline."   }   }  } }</code></pre></div>I assume you meant channel operaters, so I removed the O|F bind flags and added a check to see if nick is oped.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3085">Sir_Fz</a> — Thu Jun 16, 2005 5:07 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[kanibus]]></name></author>
		<updated>2005-06-16T14:31:28-04:00</updated>

		<published>2005-06-16T14:31:28-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=50884#p50884</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=50884#p50884"/>
		<title type="html"><![CDATA[show whos active]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=50884#p50884"><![CDATA[
hey im trying to write a script for my team thats pretty simple. it just has to add you to a list if you say !on remove you if you say !off and list all active if you say !liston. this should be for channel operators only. here is what i have so far:<div class="codebox"><p>Code: </p><pre><code>bind pubm O|F * triggersglobal whosonset whoson [list "no one"]proc triggers {nick uhost hand chan arg} {    set trigger [lindex [split $arg] 0]    switch -exact -- [string tolower $trigger] {        "!on" {           if {lindex [$whoson 0] == "no one"} {           set whoson [list $nick]           putquick "NOTICE $nick :You've been added to the 'on-line' list, noone else is on at the moment though."       } else {           set whoson [linsert $whoson end $nick]           putquick "NOTICE $nick :You've been added to the 'on-line' list."         }        }        "!off" {            if { [lsearch -exact $whoson $nick ] &gt;-1 } {            set playerindex [lsearch -exact $whoson $nick]            set whoson [lreplace $whoson $playerindex ""]            putquick "NOTICE $nick :You've been removed to the 'on-line' list. later!"         }        }        "!liston" {            set x 0            set listlong [llength $whoson]            putquick "NOTICE $nick :/0030,1d/0037,1D/0030,1ect members online:"            while {$x&lt;$listlong} {            putquick "NOTICE $nick :[lindex $x]"            incr x      }    }  }}</code></pre></div>but it doesnt work, and i get no tcl errors<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=6186">kanibus</a> — Thu Jun 16, 2005 2:31 pm</p><hr />
]]></content>
	</entry>
	</feed>
