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

	<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>2010-09-18T20:26:57-04:00</updated>

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

		<entry>
		<author><name><![CDATA[devilsoulblack]]></name></author>
		<updated>2010-09-18T20:26:57-04:00</updated>

		<published>2010-09-18T20:26:57-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=94442#p94442</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=94442#p94442"/>
		<title type="html"><![CDATA[caps kicker]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=94442#p94442"><![CDATA[
@arfer : thanks for sharing<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4165">devilsoulblack</a> — Sat Sep 18, 2010 8:26 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[WisH-GR]]></name></author>
		<updated>2009-09-13T19:46:49-04:00</updated>

		<published>2009-09-13T19:46:49-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=90243#p90243</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=90243#p90243"/>
		<title type="html"><![CDATA[caps kicker]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=90243#p90243"><![CDATA[
thank you very much arfer.<br>much appreciated<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10817">WisH-GR</a> — Sun Sep 13, 2009 7:46 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[arfer]]></name></author>
		<updated>2009-09-13T18:06:36-04:00</updated>

		<published>2009-09-13T18:06:36-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=90241#p90241</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=90241#p90241"/>
		<title type="html"><![CDATA[caps kicker]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=90241#p90241"><![CDATA[
As it stands, the script will work fine without modification because you can set the length of text to ignore. As it is currently configured it will completely ignore any text (including nicks) that is less than or equal to 8 characters (excluding spaces).<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5705">arfer</a> — Sun Sep 13, 2009 6:06 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[WisH-GR]]></name></author>
		<updated>2009-09-13T17:51:39-04:00</updated>

		<published>2009-09-13T17:51:39-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=90240#p90240</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=90240#p90240"/>
		<title type="html"><![CDATA[caps kicker]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=90240#p90240"><![CDATA[
i want it to check for example this text <br>&lt;@GiOrGoS[A]&gt; ERRIKOS<br>ERRIKOS is the nick of an oper i have,i want it to ignore if the text is a single word and is a nickname in the nicklist currently<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10817">WisH-GR</a> — Sun Sep 13, 2009 5:51 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[arfer]]></name></author>
		<updated>2009-09-13T17:28:03-04:00</updated>

		<published>2009-09-13T17:28:03-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=90239#p90239</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=90239#p90239"/>
		<title type="html"><![CDATA[caps kicker]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=90239#p90239"><![CDATA[
Not sure what you mean by caps in the nick or in the nicklist. The following script checks for caps in the channel text. It does not react to caps in a nick. Is this what you require?<br><div class="codebox"><p>Code: </p><pre><code># caps.tcl# set bot user flags to ignore textset vCapsFlagsAllow fo# set text length (excluding spaces) to allow without checkingset vCapsLengthAllow 8# set maximum percentage caps allowed (calculation excludes spaces in text)# greater than 0, less than or equal to 100set vCapsPercentAllow 90# set number of warnings before punishing# integer value equal to or greater than 1set vCapsWarnings 3# set here the mode of punishment# 1 == kick only (after warnings)# 2 == kickban (after warnings)set vCapsPunishMode 1# time in minutes within which a warning remains valid # even after the user is punished, passed offences remain valid for this time period# hence a user could be punished twice for two consecutive offencesset vCapsSinTime 20# if punishment mode 2, set here the time in minutes the ban lastsset vCapsBanTime 10bind PUBM - * pCapsDetectproc pCapsDetect {nick uhost hand chan text} {    global vCapsBanTime vCapsFlagsAllow vCapsLengthAllow vCapsPercentAllow    global vCapsPunishMode vCapsSinBin vCapsSinTime vCapsWarnings    if {[botisop $chan]} {        if {![matchattr [nick2hand $nick] $vCapsFlagsAllow $chan]} {            set caps [regexp -all -- {[A-Z]} $text]            set total [string length [regsub -all -- {[\s]} $text {}]]            if {$total &gt; $vCapsLengthAllow} {                set percent [expr {$caps * 100.0 / $total}]                if {$percent &gt; $vCapsPercentAllow} {                    set now [unixtime]                    set max [expr {$now - ($vCapsSinTime * 60)}]                    lappend vCapsSinBin(${nick},$chan) $now                    foreach sin $vCapsSinBin(${nick},$chan) {                        if {$sin &gt;= $max} {lappend newlist $sin}                    }                    set vCapsSinBin(${nick},$chan) $newlist                    if {[llength $vCapsSinBin(${nick},$chan)] &gt; $vCapsWarnings} {                        switch -- $vCapsPunishMode {                            1 {}                            2 {                                pushmode $chan +b ${nick}!$uhost                                flushmode $chan                                timer $vCapsBanTime [list pushmode $chan -b ${nick}!$uhost]                            }                            default {return 0}                        }                        putkick $chan $nick "excess caps, you were warned"                    } else {                        set output "*** [llength $vCapsSinBin(${nick},$chan)] WARNING(S) *** within the last $vCapsSinTime minutes for excess caps"                        putserv "PRIVMSG $chan :$nick $output"                    }                }            }        }    }    return 0}# eof</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5705">arfer</a> — Sun Sep 13, 2009 5:28 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[WisH-GR]]></name></author>
		<updated>2009-09-13T11:46:15-04:00</updated>

		<published>2009-09-13T11:46:15-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=90237#p90237</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=90237#p90237"/>
		<title type="html"><![CDATA[caps kicker]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=90237#p90237"><![CDATA[
hello i would like to request a help with a script.<br>I need a script that detectes a text in caps percentage more than 90% and after 3 warns it kicks.but the difficult part i think is what limitations i need.<br>1)i have many ops with nicks with CAPS(for example a nick can be like this: GEORGE) so i want it to detect if the text is on the nicklist <br>2)i want also to be able to except +f or +o users.<br><br>thank you in advance.i have recieved help whenever i needed so i am sure someone can help<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10817">WisH-GR</a> — Sun Sep 13, 2009 11:46 am</p><hr />
]]></content>
	</entry>
	</feed>
