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

	<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>2003-10-14T02:31:23-04:00</updated>

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

		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-10-14T02:31:23-04:00</updated>

		<published>2003-10-14T02:31:23-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=28454#p28454</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=28454#p28454"/>
		<title type="html"><![CDATA[ban someone who types ???? or !!!!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=28454#p28454"><![CDATA[
Duno whty I've added the split there.. <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"> Your sugestion is good also.. <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=187">caesar</a> — Tue Oct 14, 2003 2:31 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[strikelight]]></name></author>
		<updated>2003-10-13T21:19:34-04:00</updated>

		<published>2003-10-13T21:19:34-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=28447#p28447</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=28447#p28447"/>
		<title type="html"><![CDATA[ban someone who types ???? or !!!!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=28447#p28447"><![CDATA[
<blockquote class="uncited"><div>and with<div class="codebox"><p>Code: </p><pre><code>bind pubm - * my:blaproc my:bla {nick uhost hand chan text} {if {[string match -nocase "*\\\?\\\?\\\?\\\?*" [split $text]]} {putserv "PRIVMSG $chan :match!"}}</code></pre></div></div></blockquote>ok... first off.... <br>string match (as the name suggests) performs an operation on a <strong class="text-strong">string</strong>.<br>the variable <strong class="text-strong">text</strong> is a <em class="text-italics">string</em>.<br>split converts a <strong class="text-strong">string</strong> into a <strong class="text-strong">list</strong>.<br><br>Thus... we nix the split altogether, as 'string match' is a string function, not a list function. which gives us...<br><div class="codebox"><p>Code: </p><pre><code>if {[string match -nocase "*\\\?\\\?\\\?\\\?*" $text]} {</code></pre></div>Secondly, you can save on keystrokes by using {}'s instead of "'s and removing some of the back slashes:<br><div class="codebox"><p>Code: </p><pre><code>if {[string match -nocase {*\?\?\?\?*} $text]} {</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=2005">strikelight</a> — Mon Oct 13, 2003 9:19 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Sir_Fz]]></name></author>
		<updated>2003-10-13T16:45:28-04:00</updated>

		<published>2003-10-13T16:45:28-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=28432#p28432</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=28432#p28432"/>
		<title type="html"><![CDATA[ban someone who types ???? or !!!!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=28432#p28432"><![CDATA[
using \\ would work right I guess too?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3085">Sir_Fz</a> — Mon Oct 13, 2003 4:45 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2003-10-13T12:08:23-04:00</updated>

		<published>2003-10-13T12:08:23-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=28406#p28406</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=28406#p28406"/>
		<title type="html"><![CDATA[ban someone who types ???? or !!!!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=28406#p28406"><![CDATA[
The [string match [split $arg] "*\?\?\?\?*"] should actualy be [string match "*\?\?\?\?*" [split $arg]] because is a match of a string against something, not something against a string like you did. Anyway, is not good. Demonstration:<div class="codebox"><p>Code: </p><pre><code>bind pubm - * my:blaproc my:bla {nick uhost hand chan text} {if {[string match -nocase "*\?\?\?\?*" [split $text]]} {putserv "PRIVMSG $chan :match!"}}</code></pre></div><blockquote class="uncited"><div>(07:05) (caesar) ????<br>(07:05) (@bot) match!<br>(07:05) (caesar) ?aaaaa<br>(07:05) (@bot) match!</div></blockquote>and with<div class="codebox"><p>Code: </p><pre><code>bind pubm - * my:blaproc my:bla {nick uhost hand chan text} {if {[string match -nocase "*\\\?\\\?\\\?\\\?*" [split $text]]} {putserv "PRIVMSG $chan :match!"}}</code></pre></div>do you notice any difference? <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_wink.gif" width="15" height="15" alt=";)" title="Wink"><blockquote class="uncited"><div>(07:07) (caesar) ?aaaaa<br>(07:07) (caesar) ????<br>(07:07) (@bot) match!</div></blockquote><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Mon Oct 13, 2003 12:08 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Sir_Fz]]></name></author>
		<updated>2003-10-13T09:16:06-04:00</updated>

		<published>2003-10-13T09:16:06-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=28392#p28392</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=28392#p28392"/>
		<title type="html"><![CDATA[ban someone who types ???? or !!!!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=28392#p28392"><![CDATA[
well my bad, I thought ! is a wildcard like ? * % ~ . but no<br><br>then try:<div class="codebox"><p>Code: </p><pre><code>bind pubm - * kickassproc kickass {nick uhost hand chan arg} {if {[string match [split $arg] "*!!!!*"] || [string match [split $arg] "*\?\?\?\?*"]} {putserv "KICK $chan $nick :kicked for using 4 consecutive !!!!/????" }}</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3085">Sir_Fz</a> — Mon Oct 13, 2003 9:16 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Ofloo]]></name></author>
		<updated>2003-10-13T09:09:58-04:00</updated>

		<published>2003-10-13T09:09:58-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=28391#p28391</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=28391#p28391"/>
		<title type="html"><![CDATA[ban someone who types ???? or !!!!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=28391#p28391"><![CDATA[
and what would that do ?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3151">Ofloo</a> — Mon Oct 13, 2003 9:09 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Sir_Fz]]></name></author>
		<updated>2003-10-13T09:06:49-04:00</updated>

		<published>2003-10-13T09:06:49-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=28389#p28389</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=28389#p28389"/>
		<title type="html"><![CDATA[ban someone who types ???? or !!!!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=28389#p28389"><![CDATA[
I think the bind should be:<br><br><strong class="text-strong">bind pubm - *\!\!\!\!* kickass</strong><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3085">Sir_Fz</a> — Mon Oct 13, 2003 9:06 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Ofloo]]></name></author>
		<updated>2003-10-13T08:24:37-04:00</updated>

		<published>2003-10-13T08:24:37-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=28379#p28379</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=28379#p28379"/>
		<title type="html"><![CDATA[ban someone who types ???? or !!!!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=28379#p28379"><![CDATA[
could you rephrase your question ?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3151">Ofloo</a> — Mon Oct 13, 2003 8:24 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Bytez]]></name></author>
		<updated>2003-10-12T16:32:50-04:00</updated>

		<published>2003-10-12T16:32:50-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=28351#p28351</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=28351#p28351"/>
		<title type="html"><![CDATA[ban someone who types ???? or !!!!]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=28351#p28351"><![CDATA[
Hi, I want my bot to ban people who type 4 or more consecutive ???? or !!!! after a sentence, or just by itself.  How can I do this?  <div class="codebox"><p>Code: </p><pre><code>bind pubm - *!!!!* kickassproc kickass { nick host hand chan text } {if {[matchattr $hand o|o $chan]} returnputserv "KICK $chan $nick :kicked for using 4 consecutive !!!!"}</code></pre></div>This didn't work, it kicked when people used 2 consecutive ?? and when they type <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"> and <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_wink.gif" width="15" height="15" alt=";-)" title="Wink"><br><br>Thanks!<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3647">Bytez</a> — Sun Oct 12, 2003 4:32 pm</p><hr />
]]></content>
	</entry>
	</feed>
