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

	<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>2002-08-22T04:34:30-04:00</updated>

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

		<entry>
		<author><name><![CDATA[z_one]]></name></author>
		<updated>2002-08-22T04:34:30-04:00</updated>

		<published>2002-08-22T04:34:30-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=9959#p9959</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=9959#p9959"/>
		<title type="html"><![CDATA[Notice Flood Protection for Channel and Users]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=9959#p9959"><![CDATA[
The only logical targets for a notice from the Bot's point of view can be the channel it's monitoring or the bot itself.<br>If I am not mistaken, you can simply remove the "IF condition" that checks if the notice target is a channel ... thus allowing the code to be processed always. And you should make sure that the $dest is not an empty string.<br><div class="codebox"><p>Code: </p><pre><code>set channels "#chan1 #chan2" bind notc - "*" notice proc notice {nick host hand text dest} {  global channels botnick  if {$dest == ""} {set dest $botnick} set x [split $host @] foreach chan $channels {    newchanban $chan *!*@[lindex $x 1] $botnick "Another noticing dickhead bites the dust.." 60  } } </code></pre></div>Here's the explanation found in the Eggdrop helpfile (for further references)<br><blockquote class="uncited"><div>    (7)  NOTC (stackable)<br>         bind notc &lt;flags&gt; &lt;mask&gt; &lt;proc&gt;<br>         procname &lt;nick&gt; &lt;user@host&gt; &lt;handle&gt; &lt;text&gt; &lt;dest&gt;<br><br>         Description: dest will be a nickname (the bot's nickname,<br>           obviously) or a channel name. mask is matched against the entire<br>           notice and can contain wildcards. It is considered a breach of<br>           protocol to respond to a /notice on IRC, so this is intended for<br>           internal use (logging, etc.) only. Note that server notices do not<br>           trigger the NOTC bind.<br><br>           New Tcl procs should be declared as<br>             proc notcproc {nick uhost hand text {dest ""}} {<br>               global botnick; if {$dest == ""} {set dest $botnick}<br>               ...<br>             }<br>           for compatibility.</div></blockquote><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=698">z_one</a> — Thu Aug 22, 2002 4:34 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2002-08-07T04:21:56-04:00</updated>

		<published>2002-08-07T04:21:56-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=9487#p9487</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=9487#p9487"/>
		<title type="html"><![CDATA[Notice Flood Protection for Channel and Users]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=9487#p9487"><![CDATA[
Hi Guys,<br><br>can anyone help me change or modify Modreds script to include individual users too. I think it currently bans for notice floods to the channel only. Would really appreciate it as my channel is under attack by these notice nutz.<br><br>thanks<br><br><br><br>set channels "#chan1 #chan2" <br><br>bind notc - "*" notice <br><br>proc notice {nick host hand text dest} { <br>global channels botnick <br>foreach chan $channels { <br>if {$chan == $dest} { <br>set x [split $host @] <br>newchanban $chan *!*@[lindex $x 1] $botnick "Another noticing dickhead bites the dust.." 60 <br>} <br>} <br>} <br><br>[ This Message was edited by: Mordred on 2002-04-12 03:35 ]<p>Statistics: Posted by Guest — Wed Aug 07, 2002 4:21 am</p><hr />
]]></content>
	</entry>
	</feed>
