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

	<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>2011-01-08T15:43:44-04:00</updated>

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

		<entry>
		<author><name><![CDATA[karolin]]></name></author>
		<updated>2011-01-08T15:43:44-04:00</updated>

		<published>2011-01-08T15:43:44-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=95591#p95591</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=95591#p95591"/>
		<title type="html"><![CDATA[thank you very much friend]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=95591#p95591"><![CDATA[
thank you very much friend<br>I am happy thanks again<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11452">karolin</a> — Sat Jan 08, 2011 3:43 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[tomekk]]></name></author>
		<updated>2011-01-08T06:15:05-04:00</updated>

		<published>2011-01-08T06:15:05-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=95582#p95582</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=95582#p95582"/>
		<title type="html"><![CDATA[I need someone to help me please]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=95582#p95582"><![CDATA[
scared 'admin', anyway....<br><div class="codebox"><p>Code: </p><pre><code># Author: tomekk# e-mail:  tomekk/@/oswiecim/./eu/./org# home page: http://tomekk.oswiecim.eu.org/## Version 0.1## This file is Copyrighted under the GNU Public License.# http://www.gnu.org/copyleft/gpl.html# if you want to use this script on your chan, type in eggdrop console (via telnet or DCC chat)                 # .chanset #channel_name +voobly# and later .save   # voobly keyset voobly_key "your_key"# !rm command reuse interval (seconds)set rm_reuse_interval 15# !cs command reuse interval (seconds)set cs_reuse_interval 15# HTTP connection timeout intervalset http_conn_timeout 10###############################################################################################bind pub -|- !rm proc_rmbind pub -|- !cs proc_cspackage require httpsetudef flag vooblyset rm_reuse_time 1set cs_reuse_time 1# borrowed from ncgi.tclproc encode { string } {for {set i 1} {$i &lt;= 256} {incr i} {                                                              set c [format %c $i]                                                            if {![string match \[a-zA-Z0-9\] $c]} {                                                      set map($c) %[format %.2X $i]}# These are handled specially array set map {                     " " +   \n %0D%0A}}# 1 leave alphanumerics characters alone# 2 Convert every other character to an array lookup                                        # 3 Escape constructs that are "special" to the tcl parser                               # 4 "subst" the result, doing all the array substitutionsregsub -all -- \[^a-zA-Z0-9\] $string {$map(&amp;)} string# This quotes cases like $map([) or $map($) =&gt; $map(\[) ...regsub -all -- {[][{})\\]\)} $string {\\&amp;} string                                          return [subst -nocommand $string]}#######################proc net_data { link channel } {global http_conn_timeoutset the_data ""set the_error ""set http_handle [http::config -useragent "simple-voobly.tcl &lt;eggdrop script&gt;"]if {![catch {set http_handle [http::geturl $link -timeout [expr {$http_conn_timeout * 1000}]]}]} {switch -- [http::status $http_handle] {"timeout" {set the_error "connection timeout"}                        "error" {set the_error [http::error $http_handle]}                        "ok" {switch -glob [http::ncode $http_handle] {200 {set the_data [http::data $http_handle]}default {set the_error [http::ncode $http_handle]}}}}http::cleanup $http_handle} {set the_error "connection failed"}if {$the_error != ""} {putquick "PRIVMSG $channel :$the_error"}return $the_data}proc show_stats { player_chan player_nick player_scenario player_info } {global voobly_key rm_reuse_time cs_reuse_timeset url_player_nick [encode $player_nick]set user_id_data [net_data "http://www.voobly.com/api/finduser/$url_player_nick?key=$voobly_key" $player_chan]if {[string trim $user_id_data] != ""} {set user_id [lindex [split [lindex [split $user_id_data "\n"] 1] ","] 0]if {[regexp {^([0-9]+)$} $user_id]} {set user_stats_data [net_data "http://www.voobly.com/api/ladder/$player_scenario?key=$voobly_key&amp;uid=$user_id" $player_chan]if {[string trim $user_stats_data] != ""} {set user_stats [split [lindex [split $user_stats_data "\n"] 1] ","]set user_rating [lindex $user_stats 3]set user_wins [lindex $user_stats 4]set user_loss [lindex $user_stats 5]set user_streak [lindex $user_stats 6]putquick "PRIVMSG $player_chan :â&amp;#128;&amp;#148;=\[ Voobly $player_info \]=â&amp;#128;&amp;#148;â&amp;#128;˘ player: $player_nick rating: $user_rating wins: $user_wins loss: $user_loss streak: $user_streak"if {$player_scenario == "8"} {set rm_reuse_time [clock seconds]} elseif {$player_scenario == "10"} {set cs_reuse_time [clock seconds]}} { putquick "PRIVMSG $player_chan :â&amp;#128;&amp;#148;=\[ Voobly $player_info \]=â&amp;#128;&amp;#148;â&amp;#128;˘ nick $player_nick not found"}} {putquick "PRIVMSG $player_chan :â&amp;#128;&amp;#148;=\[ Voobly \]=â&amp;#128;&amp;#148;â&amp;#128;˘ nick $player_nick is not registered"}}}proc proc_rm { nick uhost hand chan arg } {global rm_reuse_time rm_reuse_intervalif {![channel get $chan voobly]} {return}if {[expr [clock seconds] - $rm_reuse_time] &gt;= $rm_reuse_interval} {set user_nick [string trim $arg]if {$user_nick != ""} {show_stats $chan $user_nick "8" "RM"} {putquick "PRIVMSG $chan :use: !rm &lt;nick&gt;"}} {putquick "PRIVMSG $chan :to fast dude - try again later..."}}proc proc_cs { nick uhost hand chan arg } {global cs_reuse_time cs_reuse_intervalif {![channel get $chan voobly]} {return}if {[expr [clock seconds] - $cs_reuse_time] &gt;= $cs_reuse_interval} {set user_nick [string trim $arg]if {$user_nick != ""} {show_stats $chan $user_nick "10" "CS"} {putquick "PRIVMSG $chan :use: !cs &lt;nick&gt;"}} {putquick "PRIVMSG $chan :to fast dude - try again later..."}}putlog "simple-voobly.tcl ver 0.1 by tomekk loaded"</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10332">tomekk</a> — Sat Jan 08, 2011 6:15 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[karolin]]></name></author>
		<updated>2011-01-07T11:53:57-04:00</updated>

		<published>2011-01-07T11:53:57-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=95569#p95569</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=95569#p95569"/>
		<title type="html"><![CDATA[I had happy]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=95569#p95569"><![CDATA[
I had happy.<br>I was happy until I received this message<br><br>friends no other way without installing tcllib please<br><br>      <blockquote class="uncited"><div>Re: install tcllib please‏<br><br>Para karolin<br>Enviado:viernes, 07 de enero de 2011 10:37:01 a.m.<br>Para: karolin <br><strong class="text-strong">Not allowed, sorry.</strong><br><br>-- <br>Regards, shells Admin</div></blockquote><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11452">karolin</a> — Fri Jan 07, 2011 11:53 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[karolin]]></name></author>
		<updated>2011-01-07T10:18:07-04:00</updated>

		<published>2011-01-07T10:18:07-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=95567#p95567</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=95567#p95567"/>
		<title type="html"><![CDATA[thanks]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=95567#p95567"><![CDATA[
Thanks tomekk for creating this wonderful script thanks again.<br><br>I have not tested yet, due to not knowing how to install if there is a manual to install in a shell linux<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11452">karolin</a> — Fri Jan 07, 2011 10:18 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[tomekk]]></name></author>
		<updated>2011-01-07T06:36:25-04:00</updated>

		<published>2011-01-07T06:36:25-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=95566#p95566</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=95566#p95566"/>
		<title type="html"><![CDATA[I need someone to help me please]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=95566#p95566"><![CDATA[
ncgi is a TCL module which is a part of TCLLIB, <br>install just TCLLIB on your system<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10332">tomekk</a> — Fri Jan 07, 2011 6:36 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[karolin]]></name></author>
		<updated>2011-01-06T22:30:32-04:00</updated>

		<published>2011-01-06T22:30:32-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=95564#p95564</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=95564#p95564"/>
		<title type="html"><![CDATA[as installed ncgi in one shell?]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=95564#p95564"><![CDATA[
as installed ncgi in one shell?<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11452">karolin</a> — Thu Jan 06, 2011 10:30 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[tomekk]]></name></author>
		<updated>2011-01-08T12:51:51-04:00</updated>

		<published>2011-01-06T19:07:45-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=95562#p95562</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=95562#p95562"/>
		<title type="html"><![CDATA[I need someone to help me please]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=95562#p95562"><![CDATA[
I have some old voobly script, I've made some fixes and it should work.<br><br>Script is kinda stupid and not flexible, there is no chance to add some extra scenarios without tweaking the source code, but for your purpose it should be enough.<br><br>In order to use this script you have to install 'tcllib' because this script is using 'ncgi::encode' to encode url string, and second thing - read the header info about '.chanset'<br><br>test it tiger:<div class="codebox"><p>Code: </p><pre><code># Author: tomekk# e-mail:  tomekk/@/oswiecim/./eu/./org# home page: http://tomekk.oswiecim.eu.org/## Version 0.1## This file is Copyrighted under the GNU Public License.# http://www.gnu.org/copyleft/gpl.html# if you want to use this script on your chan, type in eggdrop console (via telnet or DCC chat)                 # .chanset #channel_name +voobly# and later .save   # voobly keyset voobly_key "&lt;key_in_here"# !rm command reuse interval (seconds)set rm_reuse_interval 15# !cs command reuse interval (seconds)set cs_reuse_interval 15# HTTP connection timeout intervalset http_conn_timeout 10###############################################################################################bind pub -|- !rm proc_rmbind pub -|- !cs proc_cspackage require httppackage require ncgisetudef flag vooblyset rm_reuse_time 1set cs_reuse_time 1proc net_data { link channel } {global http_conn_timeoutset the_data ""set the_error ""set http_handle [http::config -useragent "simple-voobly.tcl &lt;eggdrop script&gt;"]if {![catch {set http_handle [http::geturl $link -timeout [expr {$http_conn_timeout * 1000}]]}]} {switch -- [http::status $http_handle] {"timeout" {set the_error "connection timeout"}                        "error" {set the_error [http::error $http_handle]}                        "ok" {switch -glob [http::ncode $http_handle] {200 {set the_data [http::data $http_handle]}default {set the_error [http::ncode $http_handle]}}}}http::cleanup $http_handle} {set the_error "connection failed"}if {$the_error != ""} {putquick "PRIVMSG $channel :$the_error"}return $the_data}proc show_stats { player_chan player_nick player_scenario player_info } {global voobly_key rm_reuse_time cs_reuse_timeset url_player_nick [::ncgi::encode $player_nick]set user_id_data [net_data "http://www.voobly.com/api/finduser/$url_player_nick?key=$voobly_key" $player_chan]if {[string trim $user_id_data] != ""} {set user_id [lindex [split [lindex [split $user_id_data "\n"] 1] ","] 0]if {[regexp {^([0-9]+)$} $user_id]} {set user_stats_data [net_data "http://www.voobly.com/api/ladder/$player_scenario?key=$voobly_key&amp;uid=$user_id" $player_chan]if {[string trim $user_stats_data] != ""} {set user_stats [split [lindex [split $user_stats_data "\n"] 1] ","]set user_rating [lindex $user_stats 3]set user_wins [lindex $user_stats 4]set user_loss [lindex $user_stats 5]set user_streak [lindex $user_stats 6]putquick "PRIVMSG $player_chan :â€”=\[ Voobly $player_info \]=â€”â€˘ player: $player_nick rating: $user_rating wins: $user_wins loss: $user_loss streak: $user_streak"if {$player_scenario == "8"} {set rm_reuse_time [clock seconds]} elseif {$player_scenario == "10"} {set cs_reuse_time [clock seconds]}} { putquick "PRIVMSG $player_chan :â€”=\[ Voobly $player_info \]=â€”â€˘ nick $player_nick not found"}} {putquick "PRIVMSG $player_chan :â€”=\[ Voobly \]=â€”â€˘ nick $player_nick is not registered"}}}proc proc_rm { nick uhost hand chan arg } {global rm_reuse_time rm_reuse_intervalif {![channel get $chan voobly]} {return}if {[expr [clock seconds] - $rm_reuse_time] &gt;= $rm_reuse_interval} {set user_nick [string trim $arg]if {$user_nick != ""} {show_stats $chan $user_nick "8" "RM"} {putquick "PRIVMSG $chan :use: !rm &lt;nick&gt;"}} {putquick "PRIVMSG $chan :to fast dude - try again later..."}}proc proc_cs { nick uhost hand chan arg } {global cs_reuse_time cs_reuse_intervalif {![channel get $chan voobly]} {return}if {[expr [clock seconds] - $cs_reuse_time] &gt;= $cs_reuse_interval} {set user_nick [string trim $arg]if {$user_nick != ""} {show_stats $chan $user_nick "10" "CS"} {putquick "PRIVMSG $chan :use: !cs &lt;nick&gt;"}} {putquick "PRIVMSG $chan :to fast dude - try again later..."}}putlog "simple-voobly.tcl ver 0.1 by tomekk loaded"</code></pre></div><blockquote class="uncited"><div>00:04 &lt;@tomekk&gt; !rm _Daut_<br>00:04 &lt; botty&gt; —=[ Voobly RM ]=—• player: _Daut_ rating: 2565 wins: 218 loss: 116 streak: 2<br>00:04 &lt;@tomekk&gt; !cs [Eot_]Zanchy<br>00:04 &lt; botty&gt; —=[ Voobly CS ]=—• player: [Eot_]Zanchy rating: 1649 wins: 232 loss: 258 streak: 2<br>00:04 &lt;@tomekk&gt; !rm _Daut_asd<br>00:05 &lt; botty&gt; —=[ Voobly ]=—• nick _Daut_asd is not registered<br>00:05 &lt;@tomekk&gt; !cs _Daut_<br>00:05 &lt; botty&gt; —=[ Voobly CS ]=—• nick _Daut_ not found</div></blockquote><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=10332">tomekk</a> — Thu Jan 06, 2011 7:07 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[karolin]]></name></author>
		<updated>2011-01-03T20:33:42-04:00</updated>

		<published>2011-01-03T20:33:42-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=95547#p95547</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=95547#p95547"/>
		<title type="html"><![CDATA[Lo siento]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=95547#p95547"><![CDATA[
Sorry someone could help me<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11452">karolin</a> — Mon Jan 03, 2011 8:33 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[nml375]]></name></author>
		<updated>2011-01-03T16:26:55-04:00</updated>

		<published>2011-01-03T16:26:55-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=95545#p95545</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=95545#p95545"/>
		<title type="html"><![CDATA[I need someone to help me please]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=95545#p95545"><![CDATA[
Karolin,<br>Please refrain from sending PM's solely to gain attention to your threads.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=8052">nml375</a> — Mon Jan 03, 2011 4:26 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[caesar]]></name></author>
		<updated>2010-12-27T05:17:22-04:00</updated>

		<published>2010-12-27T05:17:22-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=95499#p95499</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=95499#p95499"/>
		<title type="html"><![CDATA[I need someone to help me please]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=95499#p95499"><![CDATA[
Next time when you post some code on a public forum take a minute and remove any private information you may have, in this case your unique ID for accessing the API of that page. This time I've replaced it with &lt;my unique key&gt;.<br><br>In this community we don't translate from mIRC to TCL much, so you would have slim chances to get that translated. On the other hand, having that API and saying what exactly you want to pull from there your chances will grow. <img class="smilies" src="https://forum.eggheads.org/images/smilies/icon_smile.gif" width="15" height="15" alt=":)" title="Smile"><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=187">caesar</a> — Mon Dec 27, 2010 5:17 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[karolin]]></name></author>
		<updated>2010-12-27T21:28:15-04:00</updated>

		<published>2010-12-27T02:22:54-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=95495#p95495</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=95495#p95495"/>
		<title type="html"><![CDATA[I need someone to help me please]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=95495#p95495"><![CDATA[
Hi I would get this information through by API CALLS<br>API Documentation for vooly: <a href="http://www.voobly.com/pages/view/147/External-API-Documentation" class="postlink">http://www.voobly.com/pages/view/147/Ex ... umentation</a><br><br>There are two types of category:<br>Ladder: Random Map     web: <a href="http://www.voobly.com/ladder/index/8" class="postlink">http://www.voobly.com/ladder/index/8</a><br>Ladder: Custom Scenario web: <a href="http://www.voobly.com/ladder/index/10" class="postlink">http://www.voobly.com/ladder/index/10</a><br><br>each category obtain the following information:<br><strong class="text-strong">Rarting - Wins - Loss - Streak </strong><br><br>in category: <strong class="text-strong">Ladder: Random Map</strong>    command: <strong class="text-strong">!rm</strong><br>For example:<br>player: _Daut_<br>image info capture: <a href="http://www.ircaoc.info/daut.jpg" class="postlink">http://www.ircaoc.info/daut.jpg</a><br><br>in irc chan #voobly<br><blockquote class="uncited"><div>karolin: !rm _daut_<br>bot: —=[ Voobly RM ]=—• player:  _DauT_  rating:  2565  wins:  218  Loss:  116  Streak:  2<br>karolin: !rm asdasfshad<br>bot:  —=[ Voobly RM ]=—•  nick not registered</div></blockquote>in categoy: <strong class="text-strong">Custom Scenario</strong>       command: !cs<br>For example:<br>player: 13r1anx<br>image info capture: <a href="http://www.ircaoc.info/13r1anx.jpg" class="postlink">http://www.ircaoc.info/13r1anx.jpg</a><br><blockquote class="uncited"><div>in irc chan #voobly<br><br>&lt;karolin&gt;: !cs 13r1anx<br>&lt;bot&gt; : —=[ Voobly CS ]=—• player:  [b0x]13r1anx  rating:  2760  wins:  1154  loss:  505  Streak:  8</div></blockquote>I have a key by forum rules I can not publish<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11452">karolin</a> — Mon Dec 27, 2010 2:22 am</p><hr />
]]></content>
	</entry>
	</feed>
