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

	<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>2024-11-27T09:59:51-04:00</updated>

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

		<entry>
		<author><name><![CDATA[abah]]></name></author>
		<updated>2024-11-27T09:59:51-04:00</updated>

		<published>2024-11-27T09:59:51-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=113161#p113161</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=113161#p113161"/>
		<title type="html"><![CDATA[meby this help you]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=113161#p113161"><![CDATA[
<blockquote class="uncited"><div><blockquote class="uncited"><div>What is the trouble ? You just want to make the script run automatically on join ?<br>Add a bind join.</div></blockquote>yes automatically on join whois<br><br>channel1 "#channel"<br>channelreport "#channelbotinfowhois"<br><br>example bot report #channelbotinfowhois  join user #channel<br><br>bot: (Join) nick ident@vhost ingresa a #chan<br>bot: Modos: CHaN aplica +v nick en #chan<br>bot: (Realname) realnamenick<br>bot: (channels) #chan1 #chan2 chan3<br>bot: (IP) vhost.aqui de nick<br>bot: (Nodo) server.connect<br>bot: (ID) nick ident Chat<br>bot: (Conectado) 8secs (Inactividad) 5secs de nick<br>bot: (Quit) nick Deja el canal #chan</div></blockquote><div class="codebox"><p>Code: </p><pre><code>############################################################################### CheckNick.tcl 1.1  (17/01/2022)                             ####                                                                         ####                              Copyright 2008 - 2022 @ WwW.TCLScripts.NET ####         _   _   _   _   _   _   _   _   _   _   _   _   _   _           ####        / \ / \ / \ / \ / \ / \ / \ / \ / \ / \ / \ / \ / \ / \          ####       ( T | C | L | S | C | R | I | P | T | S | . | N | E | T )         ####        \_/ \_/ \_/ \_/ \_/ \_/ \_/ \_/ \_/ \_/ \_/ \_/ \_/ \_/          ####                                                                         ####                       ® BLaCkShaDoW Production ®                        ####                                                                         ####                                PRESENTS                                 ####                                     ® #############################   CHECK NICK TCL   ################################DESCRIPTION:    #### This script offers the posibility foreach user to save a list of nicks  #### that the eggdrop will check if there are OFFLine or ONLine and message  #### the user if the status foreach nick changed.   ####   #################################################################################   ####  COMMANDS:     ####   #### !cnick add &lt;nickname&gt; - to add a nickname   #### !cnick list - to list nicks   #### !cnick del &lt;nickname&gt; - to remove a nickname   #### !cnick help   ####   #################################################################################                                           ####  PERSONAL AND NON-COMMERCIAL USE LIMITATION.                            ####                                                                         ####  This program is provided on an "as is" and "as available" basis,       ####  with ABSOLUTELY NO WARRANTY. Use it at your own risk.                  ####                                                                         ####  Use this code for personal and NON-COMMERCIAL purposes ONLY.           ####                                                                         ####  Unless otherwise specified, YOU SHALL NOT copy, reproduce, sublicense, ####  distribute, disclose, create derivatives, in any way ANY PART OF       ####  THIS CONTENT, nor sell or offer it for sale.                           ####                                                                         ####  You will NOT take and/or use any screenshots of this source code for   ####  any purpose without the express written consent or knowledge of author.####                                                                         ####  You may NOT alter or remove any trademark, copyright or other notice   ####  from this source code.                                                 ####                                                                         ####              Copyright 2008 - 2022 @ WwW.TCLScripts.NET                 ####                                                                         ##############################################################################################################################################################                              CONFIGURATIONS                             ##################################################################################Set here what flags can add nicks for check (owner mn|- for all -|-)set cnick(flags) "-|-"###Set here the time for checking (minutes)set cnick(check_time) "1"###Filenameset cnick_file "cnick_nicks"#################################################################################        DO NOT MODIFY HERE UNLESS YOU KNOW WHAT YOU'RE DOING            #################################################################################if {![file exists $cnick_file]} {set file [open $cnick_file w]close $file}if {![info exists cnick(timer_start)]} {timer $cnick(check_time) cnick:timerset cnick(timer_start) 1}bind pub $cnick(flags) !cnick proc:cnick###proc proc:cnick {nick host hand chan arg} {global cnick cnick_fileset who [lindex [split $arg] 0]if {$who == ""} {putserv "PRIVMSG $chan :Use !cnick help for more help"return}switch $who {add {set nick_2add [lindex [split $arg] 1]if {$nick_2add == ""} {putserv "PRIVMSG $chan :Use !cnick add &lt;nickname&gt;"return}set exists [cnick:exists $hand $nick_2add]if {$exists == "1"} {putserv "PRIVMSG $chan :\002$nick_2add\002 sudah berada dalam databases."return}set file [open $cnick_file a]puts $file "$hand $nick_2add"close $fileputserv "PRIVMSG $chan :\002$nick_2add\002 berhasil ditambahkan...!!!"}list {set list [cnick:list $hand]if {$list == 0} {putserv "PRIVMSG $chan :There is nothing in your list."return}foreach n [cnick:wordwrap $list 400] {putserv "PRIVMSG $chan :Nicks :$n"}}del {set nick_2del [lindex [split $arg] 1]if {$nick_2del == ""} {putserv "PRIVMSG $chan :Use !cnick del &lt;nickname&gt;"return}set exists [cnick:exists $hand $nick_2del]if {$exists == "0"} {putserv "PRIVMSG $chan :\002$nick_2del\002 tidak ada dalam database."return}cnick:remove $hand $nick_2delif {[info exists cnick(status:$nick_2del)]} {unset cnick(status:$nick_2del)}putserv "PRIVMSG $chan :\002$nick_2del\002 berhasil dihapus...!!!"}help {putserv "PRIVMSG $chan :Use !cnick add &lt;nickname&gt; - to add ; !cnick list - to list ; !cnick del &lt;nickname&gt; - to remove"}default  {putserv "PRIVMSG $chan :Use !cnick help for more help"}}}###proc cnick:wordwrap {str {len 100} {splitChr { }}} {    set out [set cur {}]; set i 0    foreach word [split [set str][unset str] $splitChr] {      if {[incr i [string len $word]]&gt;$len} {          lappend out [join $cur $splitChr]          set cur [list $word]          set i [string len $word]       } {          lappend cur $word       }       incr i    }    lappend out [join $cur $splitChr] }###proc cnick:list {hand} {global cnick cnick_fileset file [open $cnick_file r]set read [read -nonewline $file]close $fileforeach line [split $read "\n"] {set read_hand [lindex [split $line] 0]set read_nick [lindex [split $line] 1]if {[string equal -nocase $read_hand $hand]} {lappend nicks $read_nick}}if {![info exists nicks]} {return 0}return [join $nicks ", "]}###proc cnick:remove {hand nick} {global cnick cnick_fileset timestamp [clock format [clock seconds] -format {%Y%m%d%H%M%S}]set temp "$cnick_file.new.$timestamp"set tempwrite [open $temp w]set file [open $cnick_file r]set read [read -nonewline $file]close $fileforeach line [split $read "\n"] {set read_hand [lindex [split $line] 0]set read_nick [lindex [split $line] 1]if {[string equal -nocase $read_hand $hand] &amp;&amp; [string equal -nocase $nick $read_nick]} {continue} else {puts $tempwrite $line}}close $tempwritefile rename -force $temp $cnick_file}###proc cnick:exists {hand nick} {global cnick cnick_fileset found 0set file [open $cnick_file r]set read [read -nonewline $file]close $fileif {$read == ""} { return 0 }foreach line [split $read "\n"] {set read_hand [lindex [split $line] 0]set read_nick [lindex [split $line] 1]if {[string equal -nocase $read_hand $hand] &amp;&amp; [string equal -nocase $nick $read_nick]} {set found 1break}}return $found}###proc cnick:timer {} {global cnick cnick_fileset verify_list ""set file [open $cnick_file r]set read [read -nonewline $file]close $fileif {$read == ""} {timer $cnick(check_time) cnick:timerreturn}array set thelist [list]foreach line [split $read "\n"] {set hand [lindex [split $line] 0]set nick [lindex [split $line] 1]lappend thelist($hand) $nick}if {[array size thelist] == "0"} {timer $cnick(check_time) cnick:timerreturn}foreach h [array names thelist] {lappend verify_list [list $h $thelist($h)]}cnick:verify $verify_list 0}proc cnick:verify {verify_list num} {global cnickset entry [lindex $verify_list $num]set handle [lindex $entry 0]set nicks [lindex $entry 1]set hand [hand2nick $handle]if {$hand != ""} {cnick:verify:nicks $hand $verify_list $num $nicks 0} else {set inc [expr $num + 1]if {[lindex $verify_list $inc] != ""} {cnick:verify $verify_list $inc} else {timer $cnick(check_time) cnick:timer}}}###proc cnick:verify:nicks {handle verify_list num_line nicks num_nicks} {global cnickset first_nick [lindex $nicks $num_nicks]putserv "USERHOST :$first_nick"set ::cnick_handle $handleset ::cnick_verify_list $verify_listset ::cnick_num_line $num_lineset ::cnick_nicks $nicksset ::cnick_num_nicks $num_nicksset ::cnick_nick $first_nickset ::cnick_hand $handlebind RAW - 302 cnick:check}#### Creditsset infodomain(projectName) "CheckNick"set infodomain(author) "BLaCkShaDoW"set infodomain(website) "wWw.TCLScriptS.NeT"set infodomain(email) "blackshadow\[at\]tclscripts.net"set infodomain(version) "v1.1"###proc cnick:check {from keyword arguments} {global cnickset hosts [lindex [split $arguments] 1]set nick $::cnick_nickset hand $::cnick_handset hostname [lindex [split $hosts "="] 1]regsub {^[-+]} $hostname "" hostnameif {$hosts == ":"} {if {![info exists cnick(status:$nick)]} {set cnick(status:$nick) "0:[unixtime]"putserv "PRIVMSG #roomput :$nick $hostname 4OFFLine."} else {set split_it [split $cnick(status:$nick) ":"]if {[lindex $split_it 0] == "1"} {set cnick(status:$nick) "0:[unixtime]"putserv "PRIVMSG #roomput :$nick $hostname 4OFFLine (ONLine [ctime [lindex $split_it 1]])."}}} else { if {![info exists cnick(status:$nick)]} {set cnick(status:$nick) "1:[unixtime]"putserv "PRIVMSG #roomput :$nick $hostname 3ONLine."} else {set split_it [split $cnick(status:$nick) ":"]if {[lindex $split_it 0] == "0"} {set cnick(status:$nick) "1:[unixtime]"putserv "PRIVMSG #roomput :$nick $hostname 3ONLine (4OFFLine [ctime [lindex $split_it 1]])."}}}set nick_num [expr $::cnick_num_nicks + 1]if {[lindex $::cnick_nicks $nick_num] != ""} {utimer 5 [list cnick:verify:nicks $::cnick_handle $::cnick_verify_list $::cnick_num_line $::cnick_nicks $nick_num]} else {set line_num [expr $::cnick_num_line + 1]if {[lindex $::cnick_verify_list $line_num] != ""} {cnick:verify $::cnick_verify_list $line_numunbind RAW - 302 cnick:checkunset ::cnick_handleunset ::cnick_verify_listunset ::cnick_num_lineunset ::cnick_nicksunset ::cnick_num_nicks} else {timer $cnick(check_time) cnick:timerunbind RAW - 302 cnick:checkunset ::cnick_handleunset ::cnick_verify_listunset ::cnick_num_lineunset ::cnick_nicksunset ::cnick_num_nicks}}}putlog "\002$infodomain(projectName) $infodomain(version)\002 coded by\002 $infodomain(author)\002 ($infodomain(website)): Loaded &amp; initialised.."</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12299">abah</a> — Wed Nov 27, 2024 9:59 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[kn1ghtt]]></name></author>
		<updated>2022-08-01T13:01:55-04:00</updated>

		<published>2022-08-01T13:01:55-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111220#p111220</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111220#p111220"/>
		<title type="html"><![CDATA[help me on join chan auto whois code pls]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111220#p111220"><![CDATA[
<blockquote class="uncited"><div>What is the trouble ? You just want to make the script run automatically on join ?<br>Add a bind join.</div></blockquote>yes automatically on join whois<br><br>channel1 "#channel"<br>channelreport "#channelbotinfowhois"<br><br>example bot report #channelbotinfowhois  join user #channel<br><br>bot: (Join) nick ident@vhost ingresa a #chan<br>bot: Modos: CHaN aplica +v nick en #chan<br>bot: (Realname) realnamenick<br>bot: (channels) #chan1 #chan2 chan3<br>bot: (IP) vhost.aqui de nick<br>bot: (Nodo) server.connect<br>bot: (ID) nick ident Chat<br>bot: (Conectado) 8secs (Inactividad) 5secs de nick<br>bot: (Quit) nick Deja el canal #chan<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12978">kn1ghtt</a> — Mon Aug 01, 2022 1:01 pm</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[kn1ghtt]]></name></author>
		<updated>2022-08-01T09:15:04-04:00</updated>

		<published>2022-08-01T09:15:04-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111219#p111219</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111219#p111219"/>
		<title type="html"><![CDATA[help me on join chan auto whois code pls]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111219#p111219"><![CDATA[
example :<br><div class="codebox"><p>Code: </p><pre><code>set whois_debugchan "#canal_ops"set whois_mainchan "#canal"bind join -|- * whois_cmdbind raw -|- "319" whois_channelsproc whois_cmd {n u h c} {global whois_mainchanif {[string tolower $c] == [string tolower $whois_mainchan]} {putserv "WHOIS $n"}}proc whois_channels {f k t} {global whois_debugchan whois_mainchan botnickset whois_nick [lindex [split $t " "] 1]set whois_chan [string range [lindex [lrange [split $t " "] 2 end-1]] 1 end]if {$whois_nick != $botnick } {putserv "PRIVMSG $whois_debugchan :Canales de \002$whois_nick\002 -&gt; $whois_chan"}}putlog "Script autowhois cargado"</code></pre></div><br><br>bot: (Join) nick ident@vhost ingresa a #chan<br>bot: Modos: CHaN aplica +v nick en #chan<br>bot: (Realname) realnamenick<br>bot: (channels) #chan1 #chan2 chan3<br>bot: (IP) vhost.aqui de nick<br>bot: (Nodo) server.connect<br>bot: (ID) nick ident Chat<br>bot: (Conectado) 8secs (Inactividad) 5secs de nick<br>bot: (Quit) nick Deja el canal #chan<br><br><br>please help me and code<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12978">kn1ghtt</a> — Mon Aug 01, 2022 9:15 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[simo]]></name></author>
		<updated>2022-08-01T03:58:28-04:00</updated>

		<published>2022-08-01T03:58:28-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111217#p111217</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111217#p111217"/>
		<title type="html"><![CDATA[help me on join chan auto whois code pls]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111217#p111217"><![CDATA[
That's gonna be extremely spammy tho and possibly have your bot disconnect due to excess flood (excessive command use )<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12505">simo</a> — Mon Aug 01, 2022 3:58 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[CrazyCat]]></name></author>
		<updated>2022-08-01T01:32:28-04:00</updated>

		<published>2022-08-01T01:32:28-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111215#p111215</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111215#p111215"/>
		<title type="html"><![CDATA[help me on join chan auto whois code pls]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111215#p111215"><![CDATA[
What is the trouble ? You just want to make the script run automatically on join ?<br>Add a bind join.<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=691">CrazyCat</a> — Mon Aug 01, 2022 1:32 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[kn1ghtt]]></name></author>
		<updated>2022-08-01T01:00:09-04:00</updated>

		<published>2022-08-01T01:00:09-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=111214#p111214</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=111214#p111214"/>
		<title type="html"><![CDATA[help me on join chan auto whois code pls]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=111214#p111214"><![CDATA[
hello all <br><br>help me on join chan auto whois code pls code ..<br><br><div class="codebox"><p>Code: </p><pre><code>################################################################################################  ##     whois.tcl for eggdrop by Ford_Lawnmower irc.geekshed.net #Script-Help        ##  ################################################################################################## To use this script you must set channel flag +whois (ie .chanset #chan +whois)           ##################################################################################################      ____                __                 ###########################################  ####     / __/___ _ ___ _ ___/ /____ ___   ___   ###########################################  ####    / _/ / _ `// _ `// _  // __// _ \ / _ \  ###########################################  ####   /___/ \_, / \_, / \_,_//_/   \___// .__/  ###########################################  ####        /___/ /___/                 /_/      ###########################################  ####                                             ###########################################  ##################################################################################################  ##                             Start Setup.                                         ##  ################################################################################################namespace eval whois {## change cmdchar to the trigger you want to use                                        ##  ##  variable cmdchar "!"## change command to the word trigger you would like to use.                            ##  #### Keep in mind, This will also change the .chanset +/-command                          ##  ##  variable command "whois"## change textf to the colors you want for the text.                                    ##  ##  variable textf "\017\00302"## change tagf to the colors you want for tags:                                         ##  ##  variable tagf "\017\002"## Change logo to the logo you want at the start of the line.                           ##  ##  variable logo "\017\00304\002\[\00306W\003hois\00304\]\017"## Change lineout to the results you want. Valid results are channel users modes topic  ##  ##  variable lineout "channel users modes topic"################################################################################################  ##                           End Setup.                                              ## ################################################################################################  variable channel ""  setudef flag $whois::command  bind pub -|- [string trimleft $whois::cmdchar]${whois::command} whois::lst  bind raw -|- "311" whois::311  bind raw -|- "312" whois::312  bind raw -|- "319" whois::319  bind raw -|- "317" whois::317  bind raw -|- "313" whois::multi  bind raw -|- "310" whois::multi  bind raw -|- "335" whois::multi  bind raw -|- "301" whois::301  bind raw -|- "671" whois::multi  bind raw -|- "320" whois::multi  bind raw -|- "401" whois::multi  bind raw -|- "318" whois::318  bind raw -|- "307" whois::307}proc whois::311 {from key text} {  if {[regexp -- {^[^\s]+\s(.+?)\s(.+?)\s(.+?)\s\*\s\:(.+)$} $text wholematch nick ident host realname]} {    putserv "PRIVMSG $whois::channel :${whois::logo} ${whois::tagf}Nick e IP virtual:${whois::textf} \        $nick \(${ident}@${host}\)"   putserv "PRIVMSG $whois::channel :${whois::logo} ${whois::tagf}Nombre:${whois::textf} $realname"  }}proc whois::multi {from key text} {  if {[regexp {\:(.*)$} $text match $key]} {  set keys [subst $$key]  set keys [lrange $keys 4 8]  if {"$keys" == "Nick no presente en IRC"} { set keys [encoding convertfrom utf-8 "El nick que buscas, no está conectado al IRC."];      putserv "PRIVMSG $whois::channel :${whois::logo} ${whois::tagf}Info:${whois::textf} $keys";         return 1       }     }}proc whois::312 {from key text} {  regexp {([^\s]+)\s\:} $text match server  putserv "PRIVMSG $whois::channel :${whois::logo} ${whois::tagf}Servidor:${whois::textf} $server"}proc whois::319 {from key text} {  if {[regexp {.+\:(.+)$} $text match channels]} {    putserv "PRIVMSG $whois::channel :${whois::logo} ${whois::tagf}Canales:${whois::textf} $channels"  }}proc whois::317 {from key text} {  if {[regexp -- {.*\s(\d+)\s(\d+)\s\:} $text wholematch idle signon]} {  set signonsp [duration [expr [unixtime] - $::uptime]]  set signonsp [string map [list "year" "años" "years" "años" "month" "mes" "months" "meses" "week" "semana" "weeks" "semanas" "day" "día" "days" "días" "hour" "hora" "hours" "horas" "minute" "minuto" "minutes" "minutos" "second" "segundo" "seconds" "segundos"] $signonsp]  set idlesp [duration $idle]  set idlesp [string map [list "year" "años" "years" "años" "month" "mes" "months" "meses" "week" "semana" "weeks" "semanas" "day" "día" "days" "días" "hour" "hora" "hours" "horas" "minute" "minuto" "minutes" "minutos" "second" "segundo" "seconds" "segundos"] $idlesp]    putserv "PRIVMSG $whois::channel :${whois::logo} ${whois::tagf}Conectado :${whois::textf} \        $signonsp ${whois::tagf}Inactivo:${whois::textf} $idlesp"  }}proc whois::301 {from key text} {  if {[regexp {^.+\s[^\s]+\s\:(.*)$} $text match awaymsg]} {    putserv "PRIVMSG $whois::channel :${whois::logo} ${whois::tagf}Away:${whois::textf} $awaymsg"  }}proc whois::318 {from key text} {  namespace eval whois {        variable channel ""  }  variable whois::channel ""}proc whois::307 {from key text} {  putserv "PRIVMSG $whois::channel :${whois::logo} ${whois::tagf}Estado:${whois::textf} Nick Registrado"}proc whois::lst {nick host hand chan text} {  if {[lsearch -exact [channel info $chan] "+${whois::command}"] != -1} {    namespace eval whois {          variable channel ""        }    variable whois::channel $chan##In the chathispano network the correct command is '/whois nick nick', if you put only '/whois nick' the network hidden  'uptime' and 'idle'  information of nick.##    putserv "WHOIS $text $text"  }}</code></pre></div><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=12978">kn1ghtt</a> — Mon Aug 01, 2022 1:00 am</p><hr />
]]></content>
	</entry>
	</feed>
