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

	<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>2016-07-14T01:12:14-04:00</updated>

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

		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2016-07-14T01:12:14-04:00</updated>

		<published>2016-07-14T01:12:14-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105250#p105250</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105250#p105250"/>
		<title type="html"><![CDATA[mrc to tcl]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105250#p105250"><![CDATA[
The <em class="text-italics">string match</em> wasn't getting the proper result due to the elements order. Now it's fixed and should work as expected.<div class="codebox"><p>Code: </p><pre><code>* Rejoined channel #help&lt;@bot&gt; bot banned *!*@*.users.undernet.org on #mainchan 2 minutes 12 seconds ago&lt;@bot&gt; bot banned caesar!*@* on #mainchan 4 seconds ago</code></pre></div>where the #mainchan had two bans: *!*@*.users.undernet.org and caesar!*@*<br><br>Apart the order I also added:<div class="codebox"><p>Code: </p><pre><code>set bywho [lindex [split $bywho "!"] 0]</code></pre></div>cos as it previously was, the result would have been the entire address and not just the nick of the person setting the ban, for example:<div class="codebox"><p>Code: </p><pre><code>&lt;@bot&gt; bot!bot@hidden.host banned *!*@*.users.undernet.org on #mainchan 4 minutes 24 seconds ago</code></pre></div>if you wish to have this rather than the nick then remove the above mentioned line from the code.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Thu Jul 14, 2016 1:12 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[albozz]]></name></author>
		<updated>2016-07-13T15:49:59-04:00</updated>

		<published>2016-07-13T15:49:59-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105249#p105249</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105249#p105249"/>
		<title type="html"><![CDATA[..]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105249#p105249"><![CDATA[
The tcl script doesnt work and the bot doesnt give any messages in the irc server/channel , either in telnet<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12640">albozz</a> — Wed Jul 13, 2016 3:49 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2016-07-14T01:09:35-04:00</updated>

		<published>2016-07-13T11:36:18-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105248#p105248</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105248#p105248"/>
		<title type="html"><![CDATA[mrc to tcl]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105248#p105248"><![CDATA[
<div class="codebox"><p>Code: </p><pre><code>namespace eval banCheck {set setup(help) "#help"set setup(main) "#mainchan"set setup(message) "%bywho banned %ban on %channel %when ago"   set setup(duration) {604800 {" week" " weeks"}86400 {" day" " days"}3600 {" hour" " hours"}60 {" minute" " minutes"}1 {" second" " seconds"}}   # don't edit past this line unless you know what you are doingbind join * * [namespace current]::checkproc check {nick uhost hand chan} {variable setupif {[isbotnick $nick] || ![string equal -nocase $setup(help) $chan]} returnif {![validchan $setup(main)] || ![botonchan $setup(main)]} returnset chanbans [chanbans $setup(main)]set mask "$nick!$uhost"foreach {ban bywho age} [join $chanbans] {if {[string match -nocase $ban $mask]} {set when [elapsedTime $age]set bywho [lindex [split $bywho "!"] 0]set message [string map [list "%bywho" $bywho "%ban" $ban "%channel" $setup(main) "%when" $when] $setup(message)]puthelp "PRIVMSG $chan :$message"}}}   # user's awesome duration http://forum.egghelp.org/viewtopic.php?p=79046#79046proc elapsedTime {time} {variable setupforeach {secs names} $setup(duration) {if {$time&lt;$secs} continueset val [expr {$time/$secs}]lappend out $val[lindex $names [expr {$val!=1}]]if {![incr time [expr {-$val*$secs}]]} break}join $out}}</code></pre></div>If i got this right with my limited knowledge of mIRC's scripting language then give this a try cos i haven't done any testing what so ever so let me know if dose/doesn't do what you asked for. <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><br><br>Feel free to change the message or the order of the words as you please as long as you keep the <em class="text-italics">%variable</em> as is and it will be replaced with the actual value.<br><br>Edit: Fixed.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Wed Jul 13, 2016 11:36 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[albozz]]></name></author>
		<updated>2016-07-13T06:39:34-04:00</updated>

		<published>2016-07-13T06:39:34-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=105247#p105247</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=105247#p105247"/>
		<title type="html"><![CDATA[mrc to tcl]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=105247#p105247"><![CDATA[
hello, anyone can help me with 1 tcl: on mIRC is this addons:<div class="codebox"><p>Code: </p><pre><code>on *!:join:#help:{  var %n = 1, %chan = #mainchan  while ($ibl(%chan,%n)) {    var %b = $ifmatch    if (%b iswm $fulladdress) msg #help  $nick  has banned on #mainchan  from $gettok($ibl(%chan,%n).by,1,33) For $duration($calc($ctime - $ibl(%chan,%n).ctime)) Adress: ( %b )    inc %n  }}</code></pre></div>Anyone can help me to make it tcl for egg?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12640">albozz</a> — Wed Jul 13, 2016 6:39 am</p><hr />
]]></content>
	</entry>
	</feed>
