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

	<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>2011-02-19T04:17:58-04:00</updated>

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

		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2011-02-19T04:17:58-04:00</updated>

		<published>2011-02-19T04:17:58-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96098#p96098</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96098#p96098"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96098#p96098"><![CDATA[
That's because only the ignore uses the regexp. Just replace:<div class="codebox"><p>Code: </p><pre><code>if {[regexp -nocase -- {^[-_./\\]+?([a-z0-9]+)[-_./\\]+$} [lindex [split $text] 0] a b}</code></pre></div>with:<div class="codebox"><p>Code: </p><pre><code>if {[regexp -nocase -- {^[-_./\\]+?([a-z0-9]+)[-_./\\]+$} [lindex [split $text] 0] a b]}</code></pre></div>notice the ']' after 'b'.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Sat Feb 19, 2011 4:17 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Jahner]]></name></author>
		<updated>2011-02-18T13:45:12-04:00</updated>

		<published>2011-02-18T13:45:12-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96082#p96082</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96082#p96082"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96082#p96082"><![CDATA[
I created the ignore.tcl using the code Luminous created and am running eggdrop 1.6.20 and tcl 8.5.9<br><br>When I run !ignore user I receive this error:<br><br>Tcl error [pub:cmdignore: missing close-bracket<br>in expression "[regexp -nocase -- {^[-..."<br><br>Any thoughts or ideas? !unignore and !listignores work fine.<br><br>Any help is greatly appreciated<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11557">Jahner</a> — Fri Feb 18, 2011 1:45 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[RowdyOne]]></name></author>
		<updated>2011-01-21T10:26:50-04:00</updated>

		<published>2011-01-21T10:26:50-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=95752#p95752</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=95752#p95752"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=95752#p95752"><![CDATA[
Using a botnet relay to connect this across 5 different networks. Using CrazyCat Chanrelay 3.0<br><br>Is this adaptable to work across the relay without a major rewrite?<br><br>Thank you in advance.<br><br>Rowdyone<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10831">RowdyOne</a> — Fri Jan 21, 2011 10:26 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Luminous]]></name></author>
		<updated>2010-08-13T10:55:47-04:00</updated>

		<published>2010-08-13T10:55:47-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=93919#p93919</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=93919#p93919"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=93919#p93919"><![CDATA[
Okay, I made a few tweaks regarding how nicks are set. This -should- catch nicks like amigo_blah and just turn it into *amigo*!*, but I made it so that it will first attempt to ignore via their hostmask if they are on channel. If they are not, it uses the modified version of this nick. <br><br>I also added the ignorelist too. Syntax is !ignorelist. <br><br>I went ahead and wrote the whole thing out as one script. Ignorelist is at the end. <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"> I fancied up the output of it for you some. Hope it works as planned, I wasn't able to test all of this in full, aside from the ignorelist. <br><div class="codebox"><p>Code: </p><pre><code>bind pub o|o !ignore pub:cmdignorebind pub o|o !unignore pub:cmdunignore bind pub o|o !listignores listignoresproc pub:cmdignore {nick uhost handle channel text} { if {$text == ""} {return 0}  if {[regexp -nocase -- {^[-_./\\]+?([a-z0-9]+)[-_./\\]+$} [lindex [split $text] 0] a b} { set target *$b*!*@*  } else {  set target [join [lindex [split $text] 0]]   }  set reason [join [lrange [split $text] 1 end]] set host [lindex [split [getchanhost $target $chan] @] 1]        if {$reason == ""} {set ir "Requested By $nick on [join [ctime [unixtime]]]."} else {set ir "$reason Set By $nick on [join [ctime [unixtime]]]."}       if {![string match *!*@* $target] &amp;&amp; ![onchan $target]} {        putserv "PRIVMSG $channel :invalid target; no such nickname/hostmask."         return 0        }         if {[onchan $target]} {set im "*!*@*.[join [lrange [split $host .] end-2 end] .]"} else {"set im $target"}          newignore $im $handle "$ir" 0           putserv "PRIVMSG $channel :$nick, now ignoring $im for $it minutes."            return 1}proc pub:cmdunignore {nick host handle channel text} { if {$text == ""} {return 0}  set imask [lindex [split $text] 0]   if {![isignore $imask]} {putserv "PRIVMSG $channel :invalid ignore $imask."; return 0}    if {[killignore $imask]} {     putserv "PRIVMSG $channel :$nick, no longer ingoring $imask."      return 1    } else {     putserv "PRIVMSG $channel :failed, ignore $imask must be removed manually."      return 0    }}proc listignores {nick host hand chan text} { set ilist [ignorelist]    if {![llength $ilist]} {    putserv "NOTICE $nick :I am not currently ignoring anyone." return 0    } set inum 0    foreach i $ilist { set mask [join [lindex $i 0]] set reason [join [lindex $i 1]] set begin [join [clock format [lindex $i 3] -format %D-%T]] set end [join [clock format [lindex $i 2] -format %D-%T]]        puthelp "NOTICE $nick :[incr inum]: \"$mask\" - Set at: $begin by [lindex $i end] for reason \"$reason\" - Ends at: $end"    }}</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11101">Luminous</a> — Fri Aug 13, 2010 10:55 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[dani]]></name></author>
		<updated>2010-08-13T09:50:19-04:00</updated>

		<published>2010-08-13T09:50:19-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=93917#p93917</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=93917#p93917"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=93917#p93917"><![CDATA[
<strong class="text-strong">Luminous</strong> are u the best!! mate! 1 &amp; 2 is perfect<br><br>As for question 3.. is like this: amigo_<span style="color:brown">123</span> or amigo_<span style="color:brown">can</span> or amigo_<span style="color:brown">was</span><br><br>_*** = anything the user wants<br><br>4. can i get a list of ignores nicks? how? public o priv..<br><br>Thank u very much!  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_biggrin.gif" width="15" height="15" alt=":D" title="Very Happy"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11256">dani</a> — Fri Aug 13, 2010 9:50 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Luminous]]></name></author>
		<updated>2010-08-03T22:09:37-04:00</updated>

		<published>2010-08-03T22:09:37-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=93753#p93753</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=93753#p93753"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=93753#p93753"><![CDATA[
<blockquote class="uncited"><div>work fine!!! but i need a simple functions.. and i dont know how..<br><br>1. only ops use this command<br>2. ignore permanent, with out $time (third possibility)<br><br>3. can ignore a nick for a part? ex. amigo_***<br>where * is anything.<br><br>please help me and thanks mates.  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"></div></blockquote>1.) the lines where it says: <br><div class="codebox"><p>Code: </p><pre><code>bind pub - !ignore pub:cmdignorebind pub - !unignore pub:cmdunignore </code></pre></div>change that "-" to |o or o|o if you also want to allows those with global o flag to use the script.<br><br>2.) To make the ignore permanent, remove these lines:<br><div class="codebox"><p>Code: </p><pre><code>if {![string match {[0-9]*} $time]} {set it "15m"} else {set it "$time"}set time [lindex [split $text] 1] </code></pre></div> <br><br>and change: <div class="codebox"><p>Code: </p><pre><code>newignore $im $handle "$ir" $it</code></pre></div> to <div class="codebox"><p>Code: </p><pre><code>newignore $im $handle "$ir" 0</code></pre></div> and replace: <div class="codebox"><p>Code: </p><pre><code>set reason [join [lrange [split $text] 2 end]]</code></pre></div> with: <div class="codebox"><p>Code: </p><pre><code>set reason [join [lrange [split $text] 1 end]] </code></pre></div>As for question 3... I need a bit more info. it sounds to me like you want to turn nicks like amiigo_ into *amigo*!*. To do this, you'll need a string trim or regsub to trim away chars others than what you want, like: <div class="codebox"><p>Code: </p><pre><code>set inick [regsub -all -- {[^a-z0-9]} $target ""]</code></pre></div> This would remove all characters except for a-z and 0-9. <br><br>Then, you would need to change: <div class="codebox"><p>Code: </p><pre><code>if {[onchan $target]} {set im "$target!*@*"} else {"set im $target"}</code></pre></div> to <div class="codebox"><p>Code: </p><pre><code>if {[onchan $target]} {set im "*$inick*!*@*"} else {"set im $target"}</code></pre></div>.<br><br>I think that's what you want...<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11101">Luminous</a> — Tue Aug 03, 2010 10:09 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[SIrJoKer]]></name></author>
		<updated>2010-06-20T10:26:54-04:00</updated>

		<published>2010-06-20T10:26:54-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=93386#p93386</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=93386#p93386"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=93386#p93386"><![CDATA[
Nice work guys !<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10796">SIrJoKer</a> — Sun Jun 20, 2010 10:26 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[dani]]></name></author>
		<updated>2010-06-18T11:48:30-04:00</updated>

		<published>2010-06-18T11:48:30-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=93345#p93345</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=93345#p93345"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=93345#p93345"><![CDATA[
work fine!!! but i need a simple functions.. and i dont know how..<br><br>1. only ops use this command<br>2. ignore permanent, with out $time (third possibility)<br><br>3. can ignore a nick for a part? ex. amigo_***<br>where * is anything.<br><br>please help me and thanks mates.  <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=11256">dani</a> — Fri Jun 18, 2010 11:48 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[TCL_no_TK]]></name></author>
		<updated>2007-10-16T03:37:05-04:00</updated>

		<published>2007-10-16T03:37:05-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76784#p76784</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76784#p76784"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76784#p76784"><![CDATA[
Yep, its possible to i think. However, i think it might cause problems with the bot. not to mention theres alot of problems with binds not doing channel specific stuff, they do it on all the bots channel and use an enable channel setting or list. Maybe just skiping the unbind'ing of and stuff like that and using a channel option to do like +quiet and nothing can happen on the channel set +quiet. You could just add something like <div class="codebox"><p>Code: </p><pre><code>setudef flag quiet</code></pre></div> to eggdrop config file. And then in every script check that channel isn't set +quiet with <div class="codebox"><p>Code: </p><pre><code>if {[channel get $channel quiet] &gt; 0} {return 0}</code></pre></div> or if you use MC More Tools (which am more sure of with the working thing) you can use <div class="codebox"><p>Code: </p><pre><code>if {[chanflag $channel quiet]} {return 0}</code></pre></div> <blockquote class="uncited"><div># chanflag &lt;channel&gt; &lt;flag&gt;<br>#     version:<br>#       v3.1<br>#     information (mc.moretools command):<br>#       Check to see if &lt;flag&gt; is enabled or disabled for &lt;channel&gt;.  The 'get'<br>#       option for the 'channel' command, provided by eggdrop in version 1.6.11,<br>#       does the same as this command.  Because of that, this command will try<br>#       and query 'channel' command first (is faster); if it receives an error<br>#       then it will proceed with my code.  &lt;flag&gt; includes custom setudef flags<br>#       as well as the standard ones provided by eggdrop.<br>#     dependencies (other than eggdrop provided commands):<br>#       The 'badargs' command from mc.moretools.<br>#       The 'unlist' command from mc.moretools.<br>#     examples:<br>#       chanflag #abc123 protectops =&gt; 0<br>#       chanflag #abc123 mc.spamcheck =&gt; 1<br>#     credit:<br>#     returns:<br>#       - 0 if disabled or invalid &lt;flag&gt;.<br>#       - 1 if enabled.</div></blockquote> Something along that lines would be alot easyer i think, and it would probably prevent problems with unbind'ing of things done via a script.<br> <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"> hope it helps.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8130">TCL_no_TK</a> — Tue Oct 16, 2007 3:37 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[John_Maclain]]></name></author>
		<updated>2007-10-15T11:29:58-04:00</updated>

		<published>2007-10-15T11:29:58-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76757#p76757</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76757#p76757"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76757#p76757"><![CDATA[
Could tis be adapted to be like a "quiet" script..<br><br>Lets say different tcl's are being generaly abused or are not needed at the moment.<br><br>Have a !silence #chan to make the bot ignore all channel commands for all scripts in that room - automatically removed after say 30 mins, or if a room op types !unsilence #chan <br><br>I should really learn some tcl <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=7587">John_Maclain</a> — Mon Oct 15, 2007 11:29 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[iNFERNiS]]></name></author>
		<updated>2007-10-12T13:05:17-04:00</updated>

		<published>2007-10-12T13:05:17-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76663#p76663</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76663#p76663"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76663#p76663"><![CDATA[
Works great, thanks again <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=9246">iNFERNiS</a> — Fri Oct 12, 2007 1:05 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[TCL_no_TK]]></name></author>
		<updated>2007-10-11T13:46:23-04:00</updated>

		<published>2007-10-11T13:46:23-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76628#p76628</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76628#p76628"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76628#p76628"><![CDATA[
Find where is says <blockquote class="uncited"><div>if {[onchan $target]} {set im "$target!*@*"} else {"set im $target"}</div></blockquote> and change it to <div class="codebox"><p>Code: </p><pre><code>if {[onchan $target]} {set im "$target!*@*"} else {set im "$target"}</code></pre></div>. Should work now <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=8130">TCL_no_TK</a> — Thu Oct 11, 2007 1:46 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[iNFERNiS]]></name></author>
		<updated>2007-10-11T11:12:57-04:00</updated>

		<published>2007-10-11T11:12:57-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76622#p76622</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76622#p76622"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76622#p76622"><![CDATA[
sweet, thanks guys  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_biggrin.gif" width="15" height="15" alt=":D" title="Very Happy"><br><br>edit: works pretty good so far. Would it be possible to ignore ident + hostmask? ignoring nick alone is kind of useless since the person can just change their nick. I tried defining adresses to ignore but doesn't seem to take it.<br><br><br>[17:32:44] [@iNFERNiS] !ignore TheVirus!<a href="mailto:thevirus@thevir.us">thevirus@thevir.us</a> 5 test<br>[17:31] Tcl error [pub:cmdignore]: invalid command name "set im TheVirus!<a href="mailto:thevirus@thevir.us">thevirus@thevir.us</a>"<br><br>[17:32:57] [@iNFERNiS] !ignore <a href="mailto:thevirus@thevir.us">thevirus@thevir.us</a> 5 test<br>[17:32:58] [@ef'LSGIRL] invalid target; no such nickname/hostmask.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=9246">iNFERNiS</a> — Thu Oct 11, 2007 11:12 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[ultralord]]></name></author>
		<updated>2007-10-11T08:37:36-04:00</updated>

		<published>2007-10-11T08:37:36-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76611#p76611</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76611#p76611"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76611#p76611"><![CDATA[
its ok ty<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8360">ultralord</a> — Thu Oct 11, 2007 8:37 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[iamdeath]]></name></author>
		<updated>2007-10-11T08:17:26-04:00</updated>

		<published>2007-10-11T08:17:26-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76609#p76609</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76609#p76609"/>
		<title type="html"><![CDATA[!ignore &lt;nick&gt; script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76609#p76609"><![CDATA[
Well from my point of view it should work fine, what the best you can do is, take a list of .ignores from DCC and then try to !unignore *!*@host here see if it removes or not.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5982">iamdeath</a> — Thu Oct 11, 2007 8:17 am</p><hr />
]]></content>
	</entry>
	</feed>
