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

	<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-03-09T09:05:56-04:00</updated>

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

		<entry>
		<author><name><![CDATA[Gwar]]></name></author>
		<updated>2011-03-09T09:05:56-04:00</updated>

		<published>2011-03-09T09:05:56-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96417#p96417</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96417#p96417"/>
		<title type="html"><![CDATA[Simple anti-flood code help wanted!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96417#p96417"><![CDATA[
Got ya. Tried it and it works perfectly now. Thank you so much!<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11591">Gwar</a> — Wed Mar 09, 2011 9:05 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2011-03-09T01:35:50-04:00</updated>

		<published>2011-03-09T01:35:50-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96413#p96413</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96413#p96413"/>
		<title type="html"><![CDATA[Simple anti-flood code help wanted!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96413#p96413"><![CDATA[
<blockquote class="uncited"><div>bind pub n !test pub:test </div></blockquote>user's example code has the pub trigger bound to work only for owners (n), so replace the 'n' with '*' to allow anyone use the command.<br><br>Edit: you should replace:<div class="codebox"><p>Code: </p><pre><code>if {[throttled $u,$c 30]} {</code></pre></div>too to:<div class="codebox"><p>Code: </p><pre><code>if {[throttled $c 30]} {</code></pre></div>to make the throttle count all the users in a single variable rather than counting separately for each user on the channel.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Wed Mar 09, 2011 1:35 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Gwar]]></name></author>
		<updated>2011-03-08T16:22:24-04:00</updated>

		<published>2011-03-08T16:22:24-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96408#p96408</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96408#p96408"/>
		<title type="html"><![CDATA[Simple anti-flood code help wanted!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96408#p96408"><![CDATA[
Both! <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_biggrin.gif" width="15" height="15" alt=":D" title="Very Happy"> <br><br>Is there a way I can "see" how the code is running? Nothing shows up in the eggdrop DCC chat.<br><br>Edit, Ok, I feel like a total moron now. I had not done it right. Now that I have, the example posted works.<br><br>I'll try and mesh in my own code and see if I can get it working. Sorry for being so bloody stupid D:<br><br>One further question, It seems other people in my channel can't use the example script there. How do I set it so they can?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11591">Gwar</a> — Tue Mar 08, 2011 4:22 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2011-03-08T16:19:00-04:00</updated>

		<published>2011-03-08T16:19:00-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96407#p96407</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96407#p96407"/>
		<title type="html"><![CDATA[Simple anti-flood code help wanted!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96407#p96407"><![CDATA[
have you used user's example posted in there or mixed your code with that hoping something good will result? <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=187">caesar</a> — Tue Mar 08, 2011 4:19 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Gwar]]></name></author>
		<updated>2011-03-08T14:53:33-04:00</updated>

		<published>2011-03-08T14:53:33-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96405#p96405</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96405#p96405"/>
		<title type="html"><![CDATA[Simple anti-flood code help wanted!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96405#p96405"><![CDATA[
Hey there caesar!<br>I tried out the suggestion there, but it didn't work! D: Now the command simply does nothing, and I don't know where it's going wrong!<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11591">Gwar</a> — Tue Mar 08, 2011 2:53 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2011-03-08T01:42:25-04:00</updated>

		<published>2011-03-08T01:42:25-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96386#p96386</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96386#p96386"/>
		<title type="html"><![CDATA[Simple anti-flood code help wanted!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96386#p96386"><![CDATA[
If you want to throttle a command then have a look <a href="http://forum.egghelp.org/viewtopic.php?t=9009#45537" class="postlink">here</a>.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Tue Mar 08, 2011 1:42 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Gwar]]></name></author>
		<updated>2011-03-08T00:09:40-04:00</updated>

		<published>2011-03-08T00:09:40-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=96384#p96384</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=96384#p96384"/>
		<title type="html"><![CDATA[Simple anti-flood code help wanted!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=96384#p96384"><![CDATA[
Hey all. I am trying to add a very rudimentary anti flood if/else statement to a very simple !command &gt; spits out a text string code.<br><br>here is what I have so far:<div class="codebox"><p>Code: </p><pre><code>bind pub - "!irc" ircset spam "0"proc delay {} {}proc nospam {nick text} {putserv "privmsg $nick : Do *NOT* Spam the bot. Thank you."}proc irc {nick uhost handle chan text} {global spamincr $spamif {$spam == "1"} {putserv "privmsg $chan : Get the irc info here:"incr $spamutimer 15 delayset spam 0} else {nospam $nick $text}}</code></pre></div>What (I think) I am doing here is setting a global variable to 0, then when I run the irc proc, it ups it to 1. The if then checks if its 1. If it is, it increases it to 2, sets up a 15 second delay before running a null proc, then it sets it back to 0. If someone runs the command before the 15 seconds are up, it gets upped to 3 (or whatever) and the else part is triggered.<br><br>However, I am doing something wrong, because it just spits out the else trigger (I tried swapping the bits inside, same result), so It's probably to do with my lack of understanding how the variables work. I am totally new to tcl, and have read through several websites, but I must have missed something.<br><br>Thank you for your help in advance.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11591">Gwar</a> — Tue Mar 08, 2011 12:09 am</p><hr />
]]></content>
	</entry>
	</feed>
