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

	<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>2007-09-22T18:34:07-04:00</updated>

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

		<entry>
		<author><name><![CDATA[slennox]]></name></author>
		<updated>2007-09-22T18:34:07-04:00</updated>

		<published>2007-09-22T18:34:07-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76146#p76146</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76146#p76146"/>
		<title type="html"><![CDATA[adding whois feature in this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76146#p76146"><![CDATA[
Moved to Script Requests.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=13034">slennox</a> — Sat Sep 22, 2007 6:34 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[iamdeath]]></name></author>
		<updated>2007-09-20T23:52:48-04:00</updated>

		<published>2007-09-20T23:52:48-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76084#p76084</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76084#p76084"/>
		<title type="html"><![CDATA[adding whois feature in this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76084#p76084"><![CDATA[
<blockquote class="uncited"><div><div class="codebox"><p>Code: </p><pre><code>#------------------------------------------------------------------------# relay.tcl v1.0.0 - Send channel text from one network to another       #   By: cl00bie &lt;cl00bie@sorcery.net&gt; </code></pre></div>Contacting the author first about modifications would be the proper thing to do (<em class="text-italics">if</em> they are available).</div></blockquote>I have already emailed him and went to the network he comes but he is missing since february. That was my first priority anyway, I think we can now modify since the author is missing. Yes credits will and should not be changed at all.<br><br>Thanks<br>iamdeath<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5982">iamdeath</a> — Thu Sep 20, 2007 11:52 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Alchera]]></name></author>
		<updated>2007-09-20T19:46:13-04:00</updated>

		<published>2007-09-20T19:46:13-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76076#p76076</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76076#p76076"/>
		<title type="html"><![CDATA[adding whois feature in this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76076#p76076"><![CDATA[
<div class="codebox"><p>Code: </p><pre><code>#------------------------------------------------------------------------# relay.tcl v1.0.0 - Send channel text from one network to another       #   By: cl00bie &lt;cl00bie@sorcery.net&gt; </code></pre></div>Contacting the author first about modifications would be the proper thing to do (<em class="text-italics">if</em> they are available).<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=3646">Alchera</a> — Thu Sep 20, 2007 7:46 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[awyeah]]></name></author>
		<updated>2007-09-20T12:58:37-04:00</updated>

		<published>2007-09-20T12:58:37-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76071#p76071</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76071#p76071"/>
		<title type="html"><![CDATA[adding whois feature in this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76071#p76071"><![CDATA[
For this both of your bots should be linked, else you cannot accomplish this. You can do something like this. Msg the other bot on the botnet with $text say "WHOIS $nick" and when the other bot receives it:<br><br>ON THE BOTNET from the receiving bot:<br>(1) Check for the sending botnick (use string equal or string match)<br>(2) Split $text into a list<br>(3) Check if [llength $text] == 2<br>(3) Then check string equal [lindex $text 1] with WHOIS<br>(4) Then go ahead and putserv "WHOIS [lindex $text 2]"<br>(5) Get the raw WHOIS data and store it in an array<br>(6) Then use the botnet to send the data back to the first bot<br>(7) Use a trigger while sending back so the receiving bot can identify it and display it into the channel or to the user who requested the WHOIS<br><br>There are many ways in which you can relay it to the other bot and this is one of the simplest methods.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4875">awyeah</a> — Thu Sep 20, 2007 12:58 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[iamdeath]]></name></author>
		<updated>2007-09-20T06:10:15-04:00</updated>

		<published>2007-09-20T06:10:15-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76067#p76067</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76067#p76067"/>
		<title type="html"><![CDATA[adding whois feature in this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76067#p76067"><![CDATA[
Thanks for your reply, actually the problem is not creating publci trigger or using any raw the problem is how will I send $text to the other bot on the different network and that bot will perfom whois on the given text. This is a relay script so I want users could check whois info of other users who are on differnet network.<br><br>Thanks<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5982">iamdeath</a> — Thu Sep 20, 2007 6:10 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[awyeah]]></name></author>
		<updated>2007-09-20T05:04:11-04:00</updated>

		<published>2007-09-20T05:04:11-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76066#p76066</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76066#p76066"/>
		<title type="html"><![CDATA[adding whois feature in this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76066#p76066"><![CDATA[
Well what don't you understand over here from my reply?? ask.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4875">awyeah</a> — Thu Sep 20, 2007 5:04 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[awyeah]]></name></author>
		<updated>2007-09-18T20:58:59-04:00</updated>

		<published>2007-09-18T20:58:59-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76029#p76029</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76029#p76029"/>
		<title type="html"><![CDATA[adding whois feature in this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76029#p76029"><![CDATA[
For whois you just need to <em class="text-italics">bind to the raw keywords</em> and <em class="text-italics">display the output</em>, should be nothing difficult.. and you will <em class="text-italics">execute it through a public trigger.</em><br><blockquote class="uncited"><div><strong class="text-strong">301nick :away<br>310nick :looks very helpful<br>311nick username address * :info<br>312nick server :info<br>313nick :is an IRC Operator<br>317nick seconds signon :info<br>318request :End of /WHOIS list.<br>319nick :channels<br>431:No nickname given</strong></div></blockquote><em class="text-italics"><span style="color:red">*** Taken from: <a href="http://www.mirc.net/raws/" class="postlink">http://www.mirc.net/raws/</a></span></em><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=4875">awyeah</a> — Tue Sep 18, 2007 8:58 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[iamdeath]]></name></author>
		<updated>2007-09-18T12:29:34-04:00</updated>

		<published>2007-09-18T12:29:34-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=76017#p76017</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=76017#p76017"/>
		<title type="html"><![CDATA[adding whois feature in this code]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=76017#p76017"><![CDATA[
<div class="codebox"><p>Code: </p><pre><code>#------------------------------------------------------------------------# relay.tcl v1.0.0 - Send channel text from one network to another       #   By: cl00bie &lt;cl00bie@sorcery.net&gt;## This script takes text, joins, parts, etc.  From a channel on one network, # sends it to the other network on the same channel and visa versa.  This # script requires two bots which are botnetted (Instructions on how to link# bots is beyond the scope of this document.  See BOTNET in the $eggdrop/doc# directory.)## Once your bots are netted, simply add the channels you'd like to relay# to the channelList variable, fill in the server?List variables (as per# (the instructions) and load this script on both bots.## Proposed Enhancements:#  o xkick - kick someone off the remote bot channel#  o xwhois - do a /whois on the remote bot channel#  o xmsg - send a private message to someone on the remote bot channel#  o Synchronize topics#------------------------------------------------------------------------  # List of channels to relay between (lower case only!)set channelList "#ouwet"# This identifies the server information of the two networks you wish to#  relay to each other.  There are three entries in each and they are as#  follows:#  0 - A unique pattern in each of the servers you use on a particular #      network.  (ex. all SorceryNet servers contain the word "sorcery"#      in them, but none of the DALnet servers use this.)#  1 - The name of the network as you'd like it to appear on the *other*#      network (ex. &lt;Dal-Bot&gt; [SorceryNet] &lt;Nickname&gt; hi there everyone on#      DALnet :))#  2 - The name of the bot which sits on the *other* network.  (The bot you#      want the informaiton sent *to*)set server1List "dal \00303DALnet\003 Beirut"set server2List "Beirut \00304Beirut\003 Dalnet"# Procedure: send_across - sends the information from one network to #   the other.proc send_across {cmd chan nick text} {  global server channelList server1List server2List  if {[lsearch $channelList [string tolower $chan]] != -1} {    if  {[string first [lindex $server1List 0] $server] != -1} {      set fromServer "[lindex $server1List 1]"      set toBot "[lindex $server1List 2]"     } else {      set fromServer "[lindex $server2List 1]"      set toBot "[lindex $server2List 2]"     }    set botMsg [concat $cmd $chan $fromServer $nick $text]    putbot $toBot $botMsg  }}# Find out who's on the other network channelproc send_xnames {nick uhost hand arg} {global botnick  if {$arg == "" || [string first "#" $arg] != 0} {    putserv "NOTICE $nick :Usage\: /msg $botnick xnames #channel"  } else {    if {[onchan $nick $arg]} {      send_across "names" $arg $nick "dummy"    } else {      putserv "NOTICE $nick :I'm sorry, you must be in channel $arg to do a remote names (xnames) command"    }  }}bind msg - xnames send_xnamesproc relay_xnames {frm_bot command arg} {  set startingChanlist "[chanlist [lindex $arg 0]]"   foreach mem $startingChanlist {    if {[isop $mem [lindex $arg 0]]} {      lappend finalChanlist \@$mem    } elseif {[isvoice $mem [lindex $arg 0]]} {      lappend finalChanlist \+$mem    } else {      lappend finalChanlist $mem    }  }  send_across "rnames" [lindex $arg 0] [lindex $arg 2] $finalChanlist}bind bot - names relay_xnamesproc recv_xnames {frm_bot command arg} {  putserv "NOTICE [lindex $arg 2] :The following people are on channel [lindex $arg 0] on net [lindex $arg 1] : [lrange $arg 3 end]"}bind bot - rnames recv_xnamesproc send_nick {nick uhost hand chan newnick} {  send_across "nick" $chan $nick $newnick}bind nick - * send_nickproc recv_nick {frm_bot command arg} {  putserv "PRIVMSG [lindex $arg 0] :\[[lindex $arg 1]\] \00306*** [lindex $arg 2] is now known as [lrange $arg 3 end]\003"}bind bot - nick recv_nickproc send_mode {nick uhost hand chan mchg victim} {  if {[string first "b" [lindex $mchg 0]] != -1} {    send_across "ban" $chan $nick $mchg   }}bind mode - * send_mode# Multiple recv's from one sendproc recv_ban {frm_bot command arg} {  putserv "MODE [lindex $arg 0] [lrange $arg 3 end]"}bind bot - ban recv_banproc send_sign {nick uhost hand chan reason} {  send_across "sign" $chan $nick $reason}bind sign - * send_signproc recv_sign {frm_bot command arg} {  putserv "PRIVMSG [lindex $arg 0] :\[[lindex $arg 1]\] \00302*** [lindex $arg 2] Quit \([lrange $arg 3 end]\)\003"}bind bot - sign recv_signproc send_pubm {nick uhost hand chan text} {  set cmd "pubm"  send_across $cmd $chan $nick $text}bind pubm - * send_pubmproc recv_pubm {frm_bot command arg} {  putserv "PRIVMSG [lindex $arg 0] :\[[lindex $arg 1]\] \&lt;[lindex $arg 2]\&gt; [lrange $arg 3 end]"}bind bot - pubm recv_pubmproc send_action {nick uhost hand chan keyw text} {  send_across "act" $chan $nick $text}bind ctcp - "ACTION" send_actionproc recv_action {frm_bot command arg} {  putserv "PRIVMSG [lindex $arg 0] :\[[lindex $arg 1]\] \00306\* [lindex $arg 2] [lrange $arg 3 end]\003"}bind bot - act recv_actionproc send_join {nick uhost hand chan} {  send_across "join" $chan $nick\($uhost\) "dummy"  send_across "names" $chan $nick "dummy"}bind join - * send_joinproc recv_join {frm_bot command arg} {  putserv "PRIVMSG [lindex $arg 0] :\[[lindex $arg 1]\] \00307\*** Joins [lindex $arg 2]\003"# putserv "PRIVMSG [lindex $arg 0] :\[[lindex $arg 1]\] \00307\*** [lindex $arg 2] has joined channel [lindex $arg 0]\003"}bind bot - join recv_joinproc send_part {nick uhost hand chan arg} {  send_across "part" $chan $nick ""}bind part - * send_partproc recv_part {frm_bot command arg} {  putserv "PRIVMSG [lindex $arg 0] :\[[lindex $arg 1]\] \00310\*** [lindex $arg 2] has left channel [lindex $arg 0]\003"}bind bot - part recv_partputlog "relay 1.0.0 by: cl00bie &lt;cl00bie@sorcery.net&gt;"</code></pre></div>I am currently using this code for relaying 2 channels on 2 networks, all I want to ask for favor is if it's possible to add .whois command so that users can whois other users on different network and the results should be shown in their private query not channel. Here i have whois script but i dont know how to adjust it in this code. Your help will be really appreciated Thanks alot.<br><div class="codebox"><p>Code: </p><pre><code>set mychannel "#Channel" bind pub -|- !whois script:whois proc script:whois { nick host handle chan text } { global user set text [split $text] set user [lindex $text 0] if {$user == ""} {puthelp "NOTICE $nick :You need to supply a nickname."; return} putquick "WHOIS $user" } bind raw - "311" script:whois1 bind raw - "312" script:whois1 bind raw - "318" script:whois1 bind raw - "319" script:whois1 bind raw - "401" script:whois1 bind raw - "301" script:whois1 bind raw - "313" script:whois1 bind raw - "330" script:whois1 bind raw - "317" script:whois1 proc script:whois1 {from key text} { global mychannel user set text [split $text " "] set topaste [join [lrange $text 1 end] " "] set nickname [lindex $text 1] if {![info exists user] || [string compare -nocase $nickname $user]} {return 0} putserv "PRIVMSG $mychannel :$topaste" } putlog "!whois script loaded by iamdeath."</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=5982">iamdeath</a> — Tue Sep 18, 2007 12:29 pm</p><hr />
]]></content>
	</entry>
	</feed>
