<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://script.quakenet.org/wiki/index.php?action=history&amp;feed=atom&amp;title=Modifying_mIRCs_own_Away_system</id>
	<title>Modifying mIRCs own Away system - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://script.quakenet.org/wiki/index.php?action=history&amp;feed=atom&amp;title=Modifying_mIRCs_own_Away_system"/>
	<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Modifying_mIRCs_own_Away_system&amp;action=history"/>
	<updated>2026-06-04T01:36:08Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.44.0</generator>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Modifying_mIRCs_own_Away_system&amp;diff=3795&amp;oldid=prev</id>
		<title>Cail: also a tutorial?</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Modifying_mIRCs_own_Away_system&amp;diff=3795&amp;oldid=prev"/>
		<updated>2007-07-03T12:43:32Z</updated>

		<summary type="html">&lt;p&gt;also a tutorial?&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 12:43, 3 July 2007&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l135&quot;&gt;Line 135:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 135:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  alias -l marked_back return $+($chr(22),$b($str($chr(155),2))) You are no longer marked as being away. You was gone for $b([) $+  $duration($calc($ctime - %awaytime)) $+ $b(]) - Since $b([) $+ %since_away $+ $b(]) - Reason - $b([) $+ %away.reason $+ $b(]) $+ chr(22)&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  alias -l marked_back return $+($chr(22),$b($str($chr(155),2))) You are no longer marked as being away. You was gone for $b([) $+  $duration($calc($ctime - %awaytime)) $+ $b(]) - Since $b([) $+ %since_away $+ $b(]) - Reason - $b([) $+ %away.reason $+ $b(]) $+ chr(22)&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Script Archive&lt;/del&gt;]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Tutorials&lt;/ins&gt;]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Cail</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Modifying_mIRCs_own_Away_system&amp;diff=2280&amp;oldid=prev</id>
		<title>Tovrleaf at 07:53, 24 August 2005</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Modifying_mIRCs_own_Away_system&amp;diff=2280&amp;oldid=prev"/>
		<updated>2005-08-24T07:53:12Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 07:53, 24 August 2005&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l7&quot;&gt;Line 7:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 7:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  ; we also get familar with our own made functions.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  ; we also get familar with our own made functions.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   &lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;   &lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  ; halt default [[&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Gategory&lt;/del&gt;:Raws|raws] to that shows whenever you back/away in status window&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  ; halt default [[&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;:Category&lt;/ins&gt;:Raws|raws&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;]&lt;/ins&gt;] to that shows whenever you back/away in status window&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  [[Raw_305|raw 305]]:*:{ [[halt]] }&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  [[Raw_305|raw 305]]:*:{ [[halt]] }&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  [[Raw_306|raw 306]]:*:{ [[halt]] }&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  [[Raw_306|raw 306]]:*:{ [[halt]] }&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Tovrleaf</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Modifying_mIRCs_own_Away_system&amp;diff=104&amp;oldid=prev</id>
		<title>Tovrleaf at 07:49, 24 August 2005</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Modifying_mIRCs_own_Away_system&amp;diff=104&amp;oldid=prev"/>
		<updated>2005-08-24T07:49:49Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;This is an example of silent but a modified away script, including autoaway, away timer in titlebar and channel menus ([[$iif]]).&lt;br /&gt;
Script checks if you away or not and sets you away/back. Applys to multiple networks you in ([[scid]], [[$scon]]).&lt;br /&gt;
We also get familar with our own made functions.&lt;br /&gt;
&lt;br /&gt;
 ; this is an example of a silent but modified away script, including autoaway, away timer in titlebar and channel menus.&lt;br /&gt;
 ; script checks if you away or not and sets you away/back. Applys to multiple networks you in.&lt;br /&gt;
 ; we also get familar with our own made functions.&lt;br /&gt;
 &lt;br /&gt;
 ; halt default [[Gategory:Raws|raws] to that shows whenever you back/away in status window&lt;br /&gt;
 [[Raw_305|raw 305]]:*:{ [[halt]] }&lt;br /&gt;
 [[Raw_306|raw 306]]:*:{ [[halt]] }&lt;br /&gt;
 &lt;br /&gt;
 ; $iif(this is true,do this,else do this)&lt;br /&gt;
 ; [[$away]] returns $true whetner you&amp;#039;ve set away or $false&lt;br /&gt;
 menu channel {&lt;br /&gt;
  $iif($away,Set Back,Set Away):{ $iif($away,away,away $?=&amp;quot;Away Reason&amp;quot;) }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 alias away {&lt;br /&gt;
  ; if $away is $false (we are not away)&lt;br /&gt;
  [[If-Then-Else|if]] (!$away) {&lt;br /&gt;
    ;if $1 (word after function exists) we set [[Variables|variable]] %away.reason to value [[$1-]] (all words after alias)&lt;br /&gt;
    if ($1) { [[set]] %away.reason $1- }&lt;br /&gt;
    ; else if there&amp;#039;s no words after [[Aliases|alias]], se default reason to &amp;quot;Away&amp;quot;&lt;br /&gt;
    [[If-Then-Else|else]] { set %away.reason Away }&lt;br /&gt;
    ; we need this variable later on in this alias in our self made function&lt;br /&gt;
    set %since_away $date $time&lt;br /&gt;
    ; [[$scon]](0) returns total number of open server windows.&lt;br /&gt;
    [[var]] %x = $scon(0)&lt;br /&gt;
    ; [[While_loops|while-loop]] to go through every open connections&lt;br /&gt;
    while (%x) {&lt;br /&gt;
      ; this changes the active connection for a script to connection id %x&lt;br /&gt;
      ; so we can perform commands to other networks you&amp;#039;re in too&lt;br /&gt;
      scid $scon(%x)&lt;br /&gt;
      ; we need this variable later to calculate how long we were away&lt;br /&gt;
      set %awaytime [[$ctime]]&lt;br /&gt;
      ; this is where happens the actual happening, setting us away&lt;br /&gt;
      [[away]] %away.reason $since&lt;br /&gt;
      ; $chan(0) returns to total number of channels open in active network&lt;br /&gt;
      %awaychan = [[$chan]](0)&lt;br /&gt;
      ; we use while-loop to go though every channel&lt;br /&gt;
      while (%awaychan) {&lt;br /&gt;
        ; [[echo]] means that only you can see the text we &amp;quot;echo&amp;quot;&lt;br /&gt;
        ; option -t includes timestamp, $chan(%awaychan) returns to channel id %awaychan&lt;br /&gt;
        ; $marked_away is our own made function.&lt;br /&gt;
        echo -t $chan(%awaychan) $marked_away&lt;br /&gt;
        [[dec]] %awaychan&lt;br /&gt;
      }&lt;br /&gt;
      ; start timer what calls alias to create away timer in titlebar display it every second&lt;br /&gt;
      .timerawaytime 0 1 titleawaytime&lt;br /&gt;
      ; echo -s echoes our awaymsg to statuswindow&lt;br /&gt;
      echo -st $marked_away&lt;br /&gt;
      dec %x&lt;br /&gt;
    }&lt;br /&gt;
  }&lt;br /&gt;
  ; else, if we are in away mode&lt;br /&gt;
  [[If-Then-Else|elseif]] ($away) {&lt;br /&gt;
    ; %x - again, is number of open status windows&lt;br /&gt;
    var %x = $scon(0)&lt;br /&gt;
    ; loop through every status open connection with while-loop&lt;br /&gt;
    while (%x) {&lt;br /&gt;
      scid $scon(%x)&lt;br /&gt;
      ; now because we are set away, we just use command &amp;quot;away&amp;quot; to set us back&lt;br /&gt;
      away&lt;br /&gt;
      %awaychan = $chan(0)&lt;br /&gt;
      while (%awaychan) {&lt;br /&gt;
        echo -t $chan(%awaychan) $marked_back&lt;br /&gt;
        dec %awaychan&lt;br /&gt;
      }&lt;br /&gt;
      ; close [[timer]] we set to refresh away timer in titlebar every second&lt;br /&gt;
      .timerawaytime off&lt;br /&gt;
      scid $scon(%x)&lt;br /&gt;
      echo -st $marked_back&lt;br /&gt;
      ; resets text in titlebar&lt;br /&gt;
      [[titlebar]]&lt;br /&gt;
      dec %x&lt;br /&gt;
    }&lt;br /&gt;
  }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; when we connect to any irc network, we start timer what does the trick with alias auto_away every 45&amp;#039;s second&lt;br /&gt;
 on *:connect:{&lt;br /&gt;
  .timer 0 45 auto_away&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; switch -l in alias means that alias can only be called via another alias&lt;br /&gt;
 alias -l auto_away {&lt;br /&gt;
  ; set %t how many secs we have to idle before setting away&lt;br /&gt;
  var %t = 2700&lt;br /&gt;
  ; we check if have have idled %t seconds in every networks we are in&lt;br /&gt;
  var %c = $scon(0)&lt;br /&gt;
  while (%c) {&lt;br /&gt;
    scid $scon(%c)&lt;br /&gt;
    ; if we are not set away and we have idled over %t secs&lt;br /&gt;
    if (!$away) &amp;amp;&amp;amp; ([[$idle]] &amp;gt; %t) {&lt;br /&gt;
      ; if variable %i doesnt exist, create one with value 1&lt;br /&gt;
      if (!%i) { var %i = 1 }&lt;br /&gt;
      ; else just increase it with one&lt;br /&gt;
      else { inc %i }&lt;br /&gt;
    }&lt;br /&gt;
    dec %c&lt;br /&gt;
  }&lt;br /&gt;
  ; if %i has same valua as $scon(0) (number of networks)&lt;br /&gt;
  if (%i == $scon(0)) {&lt;br /&gt;
    set %since_away $date $time&lt;br /&gt;
    var %x = $scon(0)&lt;br /&gt;
    while (%x) {&lt;br /&gt;
      scid $scon(%x)&lt;br /&gt;
      set %awaytime $calc($ctime)&lt;br /&gt;
      set %away.reason Away after $duration(%t)&lt;br /&gt;
      !away %away.reason $since&lt;br /&gt;
      %awaychan = $chan(0)&lt;br /&gt;
      while (%awaychan) {&lt;br /&gt;
        echo -t $chan(%awaychan) $marked_away&lt;br /&gt;
        dec %awaychan&lt;br /&gt;
      }&lt;br /&gt;
      .timerawaytime 0 1 titleawaytime&lt;br /&gt;
      scid $scon(%x)&lt;br /&gt;
      echo -st $marked_away&lt;br /&gt;
      dec %x&lt;br /&gt;
    }&lt;br /&gt;
  }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; our own functions&lt;br /&gt;
 ; $b(some text here) returns to bold text inside of function&lt;br /&gt;
 alias -l b [[return]] $+([[$chr]](2),$$1-,$chr(2))&lt;br /&gt;
 ; calculates how many secs we have been away, called in titlebar included in /away -command&lt;br /&gt;
 alias -l titleawaytime titlebar AwayTime[ $+ [[$duration]]([[$calc]]($ctime - %awaytime)) $+ ]&lt;br /&gt;
 ; sets time when we set away, gettok get only 2 first parametres from time, chr(58) is &amp;quot;:&amp;quot;&lt;br /&gt;
 ; $remove get only day and month from [[$date]] and leaves year behind;)&lt;br /&gt;
 alias -l since return $+($b([),[[$gettok]]($time,1-2,58),´,$[[remove]]($date,$right($date,5)),$b(]))&lt;br /&gt;
 ; next two aliases are lines what tells us how long we were away etc..&lt;br /&gt;
 alias -l marked_away return $+($chr(22),$b([[$str]]($chr(155),2))) You have been marked as being away. Reason $b([) $+ %away.reason $since $+ $b(]) $+ $chr(22)&lt;br /&gt;
 alias -l marked_back return $+($chr(22),$b($str($chr(155),2))) You are no longer marked as being away. You was gone for $b([) $+  $duration($calc($ctime - %awaytime)) $+ $b(]) - Since $b([) $+ %since_away $+ $b(]) - Reason - $b([) $+ %away.reason $+ $b(]) $+ chr(22)&lt;br /&gt;
&lt;br /&gt;
[[Category:Script Archive]]&lt;/div&gt;</summary>
		<author><name>Tovrleaf</name></author>
	</entry>
</feed>