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

	<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>2004-08-20T13:37:09-04:00</updated>

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

		<entry>
		<author><name><![CDATA[awyeah]]></name></author>
		<updated>2004-08-20T13:37:09-04:00</updated>

		<published>2004-08-20T13:37:09-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=39941#p39941</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=39941#p39941"/>
		<title type="html"><![CDATA[Need help with a script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=39941#p39941"><![CDATA[
Good thing it worked!  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_mrgreen.gif" width="15" height="15" alt=":mrgreen:" title="Mr. Green"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4875">awyeah</a> — Fri Aug 20, 2004 1:37 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2004-08-20T13:09:30-04:00</updated>

		<published>2004-08-20T13:09:30-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=39938#p39938</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=39938#p39938"/>
		<title type="html"><![CDATA[JUMP]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=39938#p39938"><![CDATA[
Hello again,<br><br>the script is running! i wish to thank awyeah and ceasar for the tips <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br><br>Here´s the code:<br><div class="codebox"><p>Code: </p><pre><code>#badawayban 1.0#Which away messages should be banned?set awaywordlist {"sex""free"}#Which channels to monitor?set awaybanchans "#germany"#How long lasts the ban (in minutes)set awaybantime 5#Which ban message should be set?set awaybanreason "To the hilt!"bind join - "*" away:joinbind raw - 311 get:hostbind raw - 301 away:checkproc away:join {nick uhost hand chan} { global botnick awaybanchans  if {(![isbotnick $nick]) &amp;&amp; (![matchattr $hand fo|fo $chan]) &amp;&amp; ([lsearch -exact [split [string tolower $awaybanchans]] [string tolower $chan]] != -1)} {  putserv "WHOIS $nick"; return 0  }}proc get:host {from key arg} {global hostset nick [lindex $arg 1]set uhost [getchanhost $nick]set host "*!*@[lindex [split $uhost "@"] 1]"}      proc away:check {from key arg} { global botnick awaywordlist awaybanchans awaybantime awaybanreason host  set awaymsg [string tolower [ctrl:filter [lrange $arg 3 end]]]  putlog "Testing AWAY Message: $awaymsg"  putlog "Testing Banmask: $host"  putlog "Testing Ban at itself: $::awaybanchans $::host $::botnick $::awaybantime $::awaybanreason"  foreach awayword $awaywordlist {   if {([string match -nocase $awayword $awaymsg])} {   continue   }    newchanban $::awaybanchans $::host $::botnick $::awaybanreason $::awaybantime     return 0      }}proc ctrl:filter {str} {  regsub -all -- {\003[0-9]{0,2}(,[0-9]{0,2})?|\017|\037|\002|\026|\006|\007} $str "" str  return $str} putlog "badaway3.tcl by elgringo loaded."</code></pre></div>The only thing i´ve to modify is that the script doesn´t get the awaywords proper, so it bans ALL users that are joining with AWAY. if an user sets away AFTER joining channel the script wont ban em, thats ok and as it should be.<br><br>Anyone have a clue what i´ve to modify to get the awaywords working?<br> <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_rolleyes.gif" width="15" height="15" alt=":roll:" title="Rolling Eyes"> <br><br>greets<br><br>mesqal<p>Statistics: Posted by Guest — Fri Aug 20, 2004 1:09 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[awyeah]]></name></author>
		<updated>2004-08-18T21:42:55-04:00</updated>

		<published>2004-08-18T21:42:55-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=39905#p39905</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=39905#p39905"/>
		<title type="html"><![CDATA[Need help with a script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=39905#p39905"><![CDATA[
<blockquote class="uncited"><div>[22:19] [@] Geneva.CH.EU.Undernet.org 311 blechi elotroyo_ ohdannyboy 213.252.228.110 * :slma</div></blockquote>Which is the nick here? I don't know.<br>I know the host is in numbers which is 213.252.228.110<br><br>Just to get it use list index.<br><br>The first 'Geneva.xxxxxx' is index 0<br>The second '311' is index 1<br>The third 'blechi' is index 2.<br><br>And so on, so to get 311 out from that output<br>you can use [lindex $arg 1]. Remember the list index<br>starts from 0.<br><br>Logicially the banmask catching thing seems fine and I use the same method for finding user@hosts from raws and it works fine for me. Try unloading some scripts, maybe they are clashing or something.  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_razz.gif" width="15" height="15" alt=":P" title="Razz"> <br><br>I think it depends upon the raw. The raw only shows the away message. Try binding to another raw, for badrealname. Then output of that raw 311 shows the users nick, user@host, and realname in that kinda format.  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_mrgreen.gif" width="15" height="15" alt=":mrgreen:" title="Mr. Green"> <br><br>Try using, this within the code to check:<div class="codebox"><p>Code: </p><pre><code>#Use this after you have declared the variables.putlog "Nick of user: $nick"putlog "User@host of user: $uhost"putlog "Banmask of user: $host"</code></pre></div>If the bot gets the nick correctly, getchanhost should work! getchanhost $nick should definately work if the user is found on any channels matching with the bot is on.  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_rolleyes.gif" width="15" height="15" alt=":roll:" title="Rolling Eyes"> <br><br>As caesar said, screw it. I don't have time to test this though as I am not IRC'ing these days, maybe I will sometime!<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4875">awyeah</a> — Wed Aug 18, 2004 9:42 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2004-08-18T16:44:23-04:00</updated>

		<published>2004-08-18T16:44:23-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=39901#p39901</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=39901#p39901"/>
		<title type="html"><![CDATA[Improvement]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=39901#p39901"><![CDATA[
Hi awyeah,<br><br>i think there is an improvement  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_razz.gif" width="15" height="15" alt=":P" title="Razz"> <br><br>Heres the hole script:<br><div class="codebox"><p>Code: </p><pre><code>#badawayban 0.2#Which away messages should be banned?set awaywordlist {"*sex*""*free*"}#Which channels to monitor?set awaybanchans "#germany"#How long lasts the ban (in minutes)set awaybantime "5"#Which ban message should be set?set awaybanreason "To the hilt!"bind join - "*" away:joinbind raw - 301 away:checkproc away:join {nick uhost hand chan} { global botnick awaybanchans  if {(![isbotnick $nick]) &amp;&amp; (![matchattr $hand fo|fo $chan]) &amp;&amp; ([lsearch -exact [split [string tolower $awaybanchans]] [string tolower $chan]] != -1)} {  putserv "WHOIS $nick"; return 0  }}proc away:check {from key arg} { global botnick awaywordlist awaybanchans awaybantime awaybanreason  set nick [lindex [split $from "!"] 0]  set uhost [getchanhost $nick]  set host "*!*@[lindex [split $uhost "@"] 1]"  set awaymsg [string tolower [ctrl:filter [lrange $arg 3 end]]]  putlog "Testing AWAY Message: $awaymsg"  putlog "Testing Banmask: $host"  foreach awayword $awaywordlist {   if {([string match -nocase *$awayword* $awaymsg])} {    newchanban $awaybanchans "*!*@[lindex [split $arg] 3]" away:msg $awaybanreason $awaybantime    return 0    }  }}proc ctrl:filter {str} {  regsub -all -- {\003[0-9]{0,2}(,[0-9]{0,2})?|\017|\037|\002|\026|\006|\007} $str "" str  return $str} putlog "badaway0.2.tcl loaded"</code></pre></div>It provides the following infos on partyline:<br><blockquote class="uncited"><div>[22:19] [s-&gt;] WHOIS elotroyo_<br>[22:19] [@] Geneva.CH.EU.Undernet.org 311 blechi elotroyo_ ohdannyboy 213.252.228.110 * :slma<br>[22:19] [@] Geneva.CH.EU.Undernet.org 319 blechi elotroyo_ :#germany #france<br>[22:19] [@] Geneva.CH.EU.Undernet.org 312 blechi elotroyo_ *.undernet.org :The Undernet Underworld<br>[22:19] [@] Geneva.CH.EU.Undernet.org 301 blechi elotroyo_ :FREE SEX &amp; PORNO &amp; PICS &amp; OVIES <a href="http://teenssex.gen.ms" class="postlink">http://teenssex.gen.ms</a><br>[22:19] Testing AWAY Message: sex &amp; porno &amp; pics &amp; ovies <a href="http://teenssex.gen.ms" class="postlink">http://teenssex.gen.ms</a><br>[22:19] Testing Banmask: *!*@<br>[22:19] [@] Geneva.CH.EU.Undernet.org 318 blechi elotroyo_ :End of /WHOIS list.</div></blockquote>I think he gets the awaymessage at the right way, but nevertheless he don´t get the mask properly so a ban won´t be set.<br><br>how do u split the line <div class="codebox"><p>Code: </p><pre><code>[22:19] [@] Geneva.CH.EU.Undernet.org 311 blechi elotroyo_ ohdannyboy 213.252.228.110 * :slma</code></pre></div> so u can get the nickname out of the string? I suggest it´s the fault that the script wont get the nick properly and therefore it wont get the host/uhost at the right way. Am i totaly wrong?<br><br>Thanks for reading and helping.<br><br>Hey caesar, thank u also, we´re using your badrealname script, and it works great!<br><br>Greets<br><br>mesqal<br><br>P.S.: The ircd (Undernet) is using RFC1459 compatible raw events, so 301 IS away.<p>Statistics: Posted by Guest — Wed Aug 18, 2004 4:44 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2004-08-18T15:51:35-04:00</updated>

		<published>2004-08-18T15:51:35-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=39900#p39900</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=39900#p39900"/>
		<title type="html"><![CDATA[Need help with a script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=39900#p39900"><![CDATA[
That's funny cos I've tested it myself and is working.. anyway, screw it! <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_mad.gif" width="15" height="15" alt=":x" title="Mad"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Wed Aug 18, 2004 3:51 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[awyeah]]></name></author>
		<updated>2004-08-17T21:29:30-04:00</updated>

		<published>2004-08-17T21:29:30-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=39887#p39887</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=39887#p39887"/>
		<title type="html"><![CDATA[Need help with a script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=39887#p39887"><![CDATA[
caesar:<br>I think the list index/range number might be incorrect. Other than that I think the script is working fine because the list index/range is not giving any result for the variable and the output is null.  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_rolleyes.gif" width="15" height="15" alt=":roll:" title="Rolling Eyes"> <br><br>mesqal:<br>This is wrong *!*@[lindex [split $arg] 3]. It will never return the host of the user.  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_wink.gif" width="15" height="15" alt=":wink:" title="Wink"> <br><br>You need to use it as I have defined in my earlier post. First find out $nick from the variable $from in the procedure binded on raw. Then from $nick you can get the uhost of the person, by using getchanhost.  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_mrgreen.gif" width="15" height="15" alt=":mrgreen:" title="Mr. Green"><br><br>For the banmask try this:<div class="codebox"><p>Code: </p><pre><code>#This is it.  set nick [lindex [split $from "!"] 0]   set uhost [getchanhost $nick]   set host "*!*@[lindex [split $uhost "@"] 1]" </code></pre></div>For the away message try this:<div class="codebox"><p>Code: </p><pre><code>set awaymsg [string tolower [ctrl:filter [lrange $arg 3 end]]]orset awaymsg [string tolower [ctrl:filter [lrange $arg 4 end]]]#We can strip the ":" later. While matching you can use wildcards#on both sides such as *$word* so they will be matched as well.</code></pre></div>Have you binded on the correct raw number even?<br>Check the raw number with your IRCd type as well!<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4875">awyeah</a> — Tue Aug 17, 2004 9:29 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2004-08-17T16:02:42-04:00</updated>

		<published>2004-08-17T16:02:42-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=39872#p39872</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=39872#p39872"/>
		<title type="html"><![CDATA[Need help with a script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=39872#p39872"><![CDATA[
sorry, nope, it doesn´t work. I´ve tested it to replace both lines, then i replaced only the firts, then only the second, but it don´t do it <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_sad.gif" width="15" height="15" alt=":(" title="Sad"><br><br>I hope i didn´t bother u to much, thanx again.<br><br>greets<br><br>mesqal<p>Statistics: Posted by Guest — Tue Aug 17, 2004 4:02 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2004-08-17T15:50:13-04:00</updated>

		<published>2004-08-17T15:50:13-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=39871#p39871</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=39871#p39871"/>
		<title type="html"><![CDATA[Need help with a script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=39871#p39871"><![CDATA[
Have you tried what I've sugested? I'm talking about the "0" not "9" at the "set awy" line.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Tue Aug 17, 2004 3:50 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2004-08-17T12:42:15-04:00</updated>

		<published>2004-08-17T12:42:15-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=39867#p39867</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=39867#p39867"/>
		<title type="html"><![CDATA[doesn´t work :(]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=39867#p39867"><![CDATA[
Hi awyeah,<br><br>thank u for your reply <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br><br>The Script doesn´t work neither. On Partyline the bot is writing this:<br><blockquote class="uncited"><div>[18:11] [s-&gt;] WHOIS senaaa<br>[18:11] [@] Geneva.CH.EU.Undernet.org 311 blechi senaaa ~BIGGIRL^^ adsl-81-7-123-4.takas.lt * :shkwmenos<br>[18:11] [@] Geneva.CH.EU.Undernet.org 319 blechi senaaa :#germany #france<br>[18:11] [@] Geneva.CH.EU.Undernet.org 312 blechi senaaa *.undernet.org :The Undernet Underworld<br>[18:11] [@] Geneva.CH.EU.Undernet.org 301 blechi senaaa :FREE SEX &amp; PORNO &amp; PICS &amp; OVIES <a href="http://teenssex.gen.ms" class="postlink">http://teenssex.gen.ms</a><br>[18:11] Testing AWAY Message:<br>[18:11] Testing Banmask: *!*@SEX</div></blockquote>i´m not familiar enough to get the error, i don´t know whats wrong. <br><br>The point why we need this script is the awaymessage as shown above. This awaymessage is used by a trojan/backdoor/worm that infects computers that visit the URL given in the awaymessage. the whole thing is like an avalanche, the more infected pc´s, the more spreading the worm/trojan/virus. Could u please help us to get a script to get rid of this infected drones?<br><br>Thank u beforehand<br><br>Regards<br><br>mesqal<p>Statistics: Posted by Guest — Tue Aug 17, 2004 12:42 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[awyeah]]></name></author>
		<updated>2004-08-16T21:41:30-04:00</updated>

		<published>2004-08-16T21:41:30-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=39856#p39856</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=39856#p39856"/>
		<title type="html"><![CDATA[Need help with a script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=39856#p39856"><![CDATA[
First check to see what output are you getting for $awy.<br><div class="codebox"><p>Code: </p><pre><code>putlog "AWAY MESSAGE: $awy"</code></pre></div>If it is the text in the away message, using a string match function with a foreach loop you can match the text, or I think you have a list here right, so you can also use lsearch -exact to match out the words and then go ahead and ban that user.<br><br>For that use the bind raw, set uhost [getchanhost $nick]. First you have to get $nick from $from to use that or you can directly get the uhost from $arg too by splitting. Then go ahead and split it in the way you like to ban to be placed.<br><div class="codebox"><p>Code: </p><pre><code>  set nick [lindex [split $from "!"] 0]  set uhost [getchanhost $nick]  set host "*!*@[lindex [split $uhost "@"] 1]"OR  set nick [lindex [split $from "!"] 0]  set uhost [getchanhost $nick]  set temp [expr [string first @ $uhost] + 1]  set host "*!*@[string range $uhost $temp end]"Although I am not sure about the output for $arg.Maybe $nick can be: (have to test it!)set nick [lindex [split $from "!"] 0]ORset nick [lindex $arg 1] (#I use this for my badrealname script)</code></pre></div>Something like this, should do it:<br><div class="codebox"><p>Code: </p><pre><code>#Which away messages should be banned? set awaywordlist { "sex" "free" } #Which channels to monitor? set awaybanchans "#germany" #How long lasts the ban (in minutes) set awaybantime "5" #Which ban message should be set? set awaybanreason "No Drones!" bind join - "*" away:join bind raw - 301 away:check proc away:join {nick uhost hand chan} { global botnick awaybanchans  if {(![isbotnick $nick]) &amp;&amp; (![matchattr $hand fo|fo $chan]) &amp;&amp; ([lsearch -exact [split [string tolower $awaybanchans]] [string tolower $chan]] != -1)} {   putserv "WHOIS $nick"; return 0  }} proc away:check {from key arg} {  global botnick awaywordlist awaybanchans awaybantime awaybanreason  set awaymsg [string tolower [ctrl:filter [lindex [lrange [split $arg ":"] 1 end] 9]]]  putlog "Testing AWAY Message: $awaymsg"  putlog "Testing Banmask: *!*@[lindex [split $arg] 3]"  foreach awayword $awaywordlist {    if {([string match -nocase *$awayword* $awaymsg])} {    newchanban $awaybanchans "*!*@[lindex [split $arg] 3]" away:msg $awaybanreason $awaybantime    return 0     }  } }proc ctrl:filter {str} {   regsub -all -- {\003[0-9]{0,2}(,[0-9]{0,2})?|\017|\037|\002|\026|\006|\007} $str "" str   return $str } </code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4875">awyeah</a> — Mon Aug 16, 2004 9:41 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2004-08-16T16:37:16-04:00</updated>

		<published>2004-08-16T16:37:16-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=39848#p39848</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=39848#p39848"/>
		<title type="html"><![CDATA[Need help with a script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=39848#p39848"><![CDATA[
first of all: thank u ceasar for ypur reply!<br><br>But it doesn´t work neither.<br><br>i don´t have a clue whats wrong, im new into tcl. i thought the line:<br><div class="codebox"><p>Code: </p><pre><code>set awy [strlwr [ctrl:filter [lindex [lrange [split $arg ":"] 1 end] 9]]]</code></pre></div>is setting the var awy stringlower, calling filter proc listindex listrange splitting the arguments at : from line one till end and the 9 is the line that should be intepreted? am i right?<br><br>the whois works proper, but the Bot wont set the ban on drones with away (raw 301) and the words sex or free in it....<br><br>could u please help me again?<br><br>Greets<br><br>mesqal<p>Statistics: Posted by Guest — Mon Aug 16, 2004 4:37 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2004-08-16T15:45:36-04:00</updated>

		<published>2004-08-16T15:45:36-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=39847#p39847</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=39847#p39847"/>
		<title type="html"><![CDATA[Need help with a script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=39847#p39847"><![CDATA[
replace<div class="codebox"><p>Code: </p><pre><code>set awy [strlwr [ctrl:filter [lindex [lrange [split $arg ":"] 1 end] 9]]] </code></pre></div>with<div class="codebox"><p>Code: </p><pre><code>set awy [strlwr [ctrl:filter [lindex [lrange [split $arg ":"] 1 end] 0]]]</code></pre></div>and<div class="codebox"><p>Code: </p><pre><code>if {[strlwr $nick] == [strlwr $::botnick] || [matchattr $hand of|fo $chan]} {</code></pre></div>with<div class="codebox"><p>Code: </p><pre><code>if {[isbotnick $nick] || [matchattr $hand of|fo $chan]} {</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Mon Aug 16, 2004 3:45 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Anonymous]]></name></author>
		<updated>2004-08-16T11:43:04-04:00</updated>

		<published>2004-08-16T11:43:04-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=39841#p39841</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=39841#p39841"/>
		<title type="html"><![CDATA[Need help with a script]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=39841#p39841"><![CDATA[
Hi,<br><br>i have modified a given script that checks for badrealnames on join, so that the script should check on away messages in whois.<br><br>the whois-proc works fine, but it doesn´t set the ban that shall be imposed if the whois-output triggering one of the search-terms.....<br><div class="codebox"><p>Code: </p><pre><code># awaycheckonjoin.tcl# original code by papillon &amp; caesar# modified by elgringo# version 0.1# Wich Awaymessages should be banned?set bada(list) {"*sex*""FREE"}# wich channels to monitor?set bada(chan) "#germany"# how long lasts the ban (in minutes)set bada(time) 5# wich banmessage should be set?set bada(reason) "No Drones!" ##No MODs under this line except u know what you´re doingbind join - "$bada(chan) *" away:joinbind raw - 301 away:check#joinproc away:join {nick host hand chan args} {   if {[strlwr $nick] == [strlwr $::botnick] || [matchattr $hand of|fo $chan]} {    return  }   putserv "WHOIS $nick" }#checkproc away:check {from key arg} {   set awy [strlwr [ctrl:filter [lindex [lrange [split $arg ":"] 1 end] 9]]]  foreach bla $::bada(list) {    if {![string match -nocase $bla $awy]} {      continue    }    newchanban $::bada(chan) "*!*@[lindex [split $arg] 3]" $::botnick $::bada(reason) $::bada(time)    break  }}## # ppslim's filterproc ctrl:filter {str} {  regsub -all -- {\003[0-9]{0,2}(,[0-9]{0,2})?|\017|\037|\002|\026|\006|\007} $str "" str  return $str}putlog "badaway.tcl by elgringo loaded."</code></pre></div>Anyone got a clue why the script doesn´t work properly? <br><br>thank u beforehand  <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_wink.gif" width="15" height="15" alt=":wink:" title="Wink"> <br><br>Regards<br><br>mesqal<p>Statistics: Posted by Guest — Mon Aug 16, 2004 11:43 am</p><hr />
]]></content>
	</entry>
	</feed>
