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

	<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>2013-08-06T07:18:44-04:00</updated>

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

		<entry>
		<author><name><![CDATA[Madalin]]></name></author>
		<updated>2013-08-06T07:18:44-04:00</updated>

		<published>2013-08-06T07:18:44-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=101959#p101959</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=101959#p101959"/>
		<title type="html"><![CDATA[Op time counter]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=101959#p101959"><![CDATA[
Modifyed this version of mine to look only on channels where +timespent is set and the users have +C channel flag<br><div class="codebox"><p>Code: </p><pre><code>#### ++++ Author: MadaliN &lt;madalinmen28@yahoo.com&gt;### +++ Website: www.Ascenture.ro## +++ TCL Name: TimeSpent# +++ Version: 2.0## Commands:#   /msg BOTNICK timespent activate &lt;$chan&gt;       (local or global owner)#   /msg BOTNICK timespent deactivate &lt;$chan&gt;(local or global owner)#   /msg BOTNICK timespent &lt;$nickname&gt; &lt;$chan&gt;(local or global owner)###### +++ Created: 6/8/2013####bind MSGM - * timespent:msgsetudef flag timespentproc egghelp:timespent {min hour day month year} {global timespent announce noaset list ""foreach chan [channels] {if {[channel get $chan timespent]} {foreach u [chanlist $chan] {if {[matchattr $u -|C $chan] &amp;&amp; [isop $u $chan]} {putlog "Found \002$u"set host [lindex [split [getchanhost $u $chan] @] 1]if {![info exists timespent($chan,$host)]} {set timespent($chan,$host) "60 $u"timespent:save} else {set timespent($chan,$host) "[expr [lindex [split $timespent($chan,$host)] 0] + 60] $u"timespent:save}}}}}}proc timespent:msg {nick uhost hand arg} {global timespentif {[lindex [split $arg] 2] != ""} {set chan [lindex [split $arg] 2]set host [lindex [split [getchanhost [lindex [split $arg] 1] $chan] @] 1]}switch -exact -- [lindex [split $arg] 0] {timespent {switch -exact -- [lindex [split $arg] 1] {activate {if {[matchattr $hand n]} {channel set $chan +timespentputserv "PRIVMSG $chan :\002$nick\002 - TIMESPENT script \00312activated\003 succesfully"}}deactivate {if {[matchattr $hand n]} {channel set $chan -timespentputserv "PRIVMSG $chan :\002$nick\002 - TIMESPENT script \00304deactivated\003 succesfully"}}reset {if {[matchattr $hand n]} {unset -nocomplain timespentputserv "PRIVMSG $nick :\002$nick\002 - Timespent with @ was RESET for everyone"}}default {if {[matchattr $hand n]} {if {[string match -nocase "#*" [lindex [split $arg] 2]]} {if {![info exists timespent([lindex [split $arg] 2],$host)]} {putserv "PRIVMSG $nick :\002$nick\002 - Nickname \00303[lindex [split $arg] 1]\003 has no info on \00312[lindex [split $arg] 2]"} else {putserv "PRIVMSG $nick :\002$nick\002 - Nickname \00303[lindex [split $arg] 1]\003 idled with @ on \00312[lindex [split $arg] 2]\003 for \00303[duration [lindex [split $timespent([lindex [split $arg] 2],$host)] 0]]"}}}}}}}}proc timespent:save {} {global timespentset ofile [open timespent w]puts $ofile "array set timespent [list [array get timespent]]"close $ofile}catch {source timespent}putlog "+++ Succesfully loaded: \00312Timpespent TCL Script"</code></pre></div>Original script can be found at <a href="http://forum.egghelp.org/viewtopic.php?t=19314" class="postlink">http://forum.egghelp.org/viewtopic.php?t=19314</a><p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=6396">Madalin</a> — Tue Aug 06, 2013 7:18 am</p><hr />
]]></content>
	</entry>
		<entry>
		<author><name><![CDATA[Cr0ntab]]></name></author>
		<updated>2013-08-06T06:06:54-04:00</updated>

		<published>2013-08-06T06:06:54-04:00</published>
		<id>https://forum.eggheads.org/viewtopic.php?p=101957#p101957</id>
		<link href="https://forum.eggheads.org/viewtopic.php?p=101957#p101957"/>
		<title type="html"><![CDATA[Op time counter]]></title>

		
		<content type="html" xml:base="https://forum.eggheads.org/viewtopic.php?p=101957#p101957"><![CDATA[
Hello. I would like to request a script but i dont know how easy it is to make.<br><br>The script i need is one that counts how many hours per day/week each of the users that match the +C flag ops in a channel. To make it more clear:<br><br>All the ops in my channel let's say #channel have the global +C flag on the bot. I want the script to count how many hours each person has opped in one day and in the week. As for how the bot will give me the hours can it create a webpage or let me know on request by a command i send in pvt?<br><br>For example if the report is given by command i type in pvt: !optimes and the bot will respond:<br><br>Oper1: Opped today: 1hr 23mins Opped this week: 14hrs 23mins.<br>Oper2: Opped today: 1hr 23mins Opped this week: 14hrs 23mins.<br><br>But please make it look ONLY #channel!!! cause bot sits in many chans irrelevant to #channel or perhaps the ops channel.<br><br>I appreciate if anyone takes the time to deal with this request<p>Statistics: Posted by <a href="https://forum.eggheads.org/memberlist.php?mode=viewprofile&amp;u=11149">Cr0ntab</a> — Tue Aug 06, 2013 6:06 am</p><hr />
]]></content>
	</entry>
	</feed>
