<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://script.quakenet.org/wiki/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Doomie</id>
	<title>Scriptwiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://script.quakenet.org/wiki/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Doomie"/>
	<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/Special:Contributions/Doomie"/>
	<updated>2026-05-14T13:16:40Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.44.0</generator>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Tips&amp;diff=4757</id>
		<title>Tips</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Tips&amp;diff=4757"/>
		<updated>2008-04-22T22:52:04Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Toggles tips on or off.&lt;br /&gt;
 /tips [on|off]&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; Using /tips with no parameters will return whether tips are currently on or off.&lt;br /&gt;
&lt;br /&gt;
[[Category:Tips]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Category:Tips&amp;diff=2482</id>
		<title>Category:Tips</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Category:Tips&amp;diff=2482"/>
		<updated>2008-04-22T22:51:31Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Tips&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Tip&amp;diff=4756</id>
		<title>Tip</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Tip&amp;diff=4756"/>
		<updated>2008-04-22T22:51:19Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Edits an open tip.&lt;br /&gt;
 /tip &amp;lt;-ct&amp;gt; &amp;lt;name&amp;gt; [text]&lt;br /&gt;
&amp;lt;name&amp;gt; refers to the name of the tip.&lt;br /&gt;
&lt;br /&gt;
=== Switches ===&lt;br /&gt;
&lt;br /&gt;
* -c - Closes the tip.&lt;br /&gt;
* -t - Changes the tip&#039;s text. [text] must be included.&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; At least one switch must be specified.&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[tips|/tips]] - Toggles tips on or off.&lt;br /&gt;
&lt;br /&gt;
[[Category:Tips]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Clear-Chanlev_Script_for_QuakeNet&amp;diff=2758</id>
		<title>Clear-Chanlev Script for QuakeNet</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Clear-Chanlev_Script_for_QuakeNet&amp;diff=2758"/>
		<updated>2008-04-12T14:02:45Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt; ; ClearChanlev script by doomie&lt;br /&gt;
 ;   #help.script @ QuakeNet&lt;br /&gt;
 ;&lt;br /&gt;
 ;&lt;br /&gt;
 ; You can use this script by typing:&lt;br /&gt;
 ;&lt;br /&gt;
 ;        /clearchanlev [-c|-r] #channel&lt;br /&gt;
 ; &lt;br /&gt;
 ;   Note, that you must be authed and owner of #channel. &lt;br /&gt;
 ;&lt;br /&gt;
 ;   Flags:&lt;br /&gt;
 ;           * -r ... Resets the script, i.e. cleans everything up. One usually doesn&#039;t need that flag, however, if something didn&#039;t work,&lt;br /&gt;
 ;                    one can use it.  &lt;br /&gt;
 ;           * -c ... If you use this flag, the script will remove you from the channel aswell. This means, that Q will leave the channel&lt;br /&gt;
 ;                    completly. Note that you can _NOT_ reverse it!&lt;br /&gt;
 ;&lt;br /&gt;
 ;&lt;br /&gt;
 ;   Example output:&lt;br /&gt;
 ;&lt;br /&gt;
 ;      ClearChanlev: -----------------------------&lt;br /&gt;
 ;      ClearChanlev: Now beginning to remove all chanlevs from channel #channel except yours!&lt;br /&gt;
 ;      ClearChanlev: Receiving own auth now!&lt;br /&gt;
 ;      ClearChanlev: ...done.&lt;br /&gt;
 ;      ClearChanlev: Saving chanlev now...&lt;br /&gt;
 ;      ClearChanlev: ...done.&lt;br /&gt;
 ;      ClearChanlev: There are 2 lines to send. This will take approximatly 4 seconds. Removing...&lt;br /&gt;
 ;      ClearChanlev: ...done.&lt;br /&gt;
 ;      ClearChanlev: Cleaned up!&lt;br /&gt;
 ;      ClearChanlev: -----------------------------&lt;br /&gt;
 ;&lt;br /&gt;
 &lt;br /&gt;
 ; Returns the milliseconds between every message sent to Q&lt;br /&gt;
 ; If you excess flood, you should increase this value to 4000 or even 5000.&lt;br /&gt;
 [[alias]] -l ClearChanlev.Delay { [[return]] 3000 } &lt;br /&gt;
 &lt;br /&gt;
 ; $1 = #channel&lt;br /&gt;
 ;&lt;br /&gt;
 ; flags:&lt;br /&gt;
 ;   -c --complete = deletes the complete chanlev, inclusive owner. This will&lt;br /&gt;
 ;                   result in Q parting.&lt;br /&gt;
 ;   -r --reset    = resets the scripts in case something didn&#039;t work the last time.&lt;br /&gt;
 alias ClearChanlev {&lt;br /&gt;
   [[echo]] -s ClearChanlev: -----------------------------&lt;br /&gt;
   [[var]] %i = 1, %c, %ClearChanlev.Complete = 0, %r, %ClearChanlev.Force = 0, %ClearChanlev.Channel&lt;br /&gt;
   [[While loops|while]] (%i [[If#.3C.3D|&amp;lt;=]] [[$0]]) {&lt;br /&gt;
     %c = $ [[Evaluation_brackets|[]] [[DollarPlus|$+]] [[Evaluation_brackets|[]] %i [[Evaluation_brackets|] ]]]&lt;br /&gt;
     [[if]] (%c [[If#.3D.3D|==]] -c) [[If#Combining_comparisons|||]] (%c == --complete) {&lt;br /&gt;
       %ClearChanlev.Complete = 1&lt;br /&gt;
     }&lt;br /&gt;
     elseif (%c == -r) || (%c == --reset) {&lt;br /&gt;
       %ClearChanlev.Force = 1&lt;br /&gt;
     }&lt;br /&gt;
     elseif ([[$left]](%c, 1) == [[$chr]](35)) {&lt;br /&gt;
       %ClearChanlev.Channel = %c&lt;br /&gt;
     }&lt;br /&gt;
     [[inc]] %i&lt;br /&gt;
   }&lt;br /&gt;
   if (%ClearChanlev.Global) {&lt;br /&gt;
     if (%ClearChanlev.Force == 0) {&lt;br /&gt;
       echo -s ClearChanlev: ClearChanlev is currently running. If this is not the case, please use the -r flag (i.e. /clearchanlev -r #channel)&lt;br /&gt;
       echo -s ClearChanlev: -----------------------------&lt;br /&gt;
       return&lt;br /&gt;
     }&lt;br /&gt;
     else {&lt;br /&gt;
       [[unset]] %ClearChanlev.Global&lt;br /&gt;
       echo -s ClearChanlev: ClearChanlev reseted.&lt;br /&gt;
     }&lt;br /&gt;
   }&lt;br /&gt;
   if (!%ClearChanlev.Channel) {&lt;br /&gt;
     echo -s ClearChanlev: No channel specified.&lt;br /&gt;
     return&lt;br /&gt;
   }&lt;br /&gt;
   %r = [[$rand]](1,1000)&lt;br /&gt;
   [[set]] %ClearChanlev.Global %ClearChanlev.Channel %ClearChanlev.Complete %r&lt;br /&gt;
   echo -s ClearChanlev: Now beginning to remove all chanlevs from channel %ClearChanlev.Channel [[$iif]](%ClearChanlev.Complete, inclusive, except) yours!&lt;br /&gt;
   echo -s ClearChanlev: Receiving own auth now!&lt;br /&gt;
   .[[timer]]ClearChanlevCleanUp 1 60 ClearChanlev.CleanUp&lt;br /&gt;
   .[[who]] [[$me]] n%nat, $+ %r&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 [[:Category:Raws|raw]] [[Raw_354|354]]:*: {&lt;br /&gt;
   if ([[$1-|$2]] == [[$gettok]](%ClearChanlev.Global, 3, 32)) &amp;amp;&amp;amp; ($3 == $me) {&lt;br /&gt;
     haltdef&lt;br /&gt;
     set %ClearChanlev.Global %ClearChanlev.Global $4&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 raw [[Raw_315|315]]:*: {&lt;br /&gt;
   if (%ClearChanlev.Global) &amp;amp;&amp;amp; ($2 == $me) {&lt;br /&gt;
     [[haltdef]]&lt;br /&gt;
     if ($gettok(%ClearChanlev.Global, 4, 32) == 0) {&lt;br /&gt;
       echo -s ClearChanlev: You are NOT authed.&lt;br /&gt;
       ClearChanlev.CleanUp&lt;br /&gt;
     } &lt;br /&gt;
     else {&lt;br /&gt;
       echo -s ClearChanlev: ...done.&lt;br /&gt;
       set %ClearChanlev.Global %ClearChanlev.Global 0&lt;br /&gt;
       .[[msg]] Q chanlev $gettok(%ClearChanlev.Global, 1, 32)&lt;br /&gt;
     }&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 alias -l ClearChanlev.GotMessages {&lt;br /&gt;
   if (![[$exists]](ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt)) {&lt;br /&gt;
     echo -s ClearChanlev: File does not exist!&lt;br /&gt;
     ClearChanlev.CleanUp&lt;br /&gt;
     return&lt;br /&gt;
   }&lt;br /&gt;
   if ([[$lines]](ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt) == 0) {&lt;br /&gt;
     echo -s ClearChanlev: No chanlev to remove!&lt;br /&gt;
     ClearChanlev.CleanUp&lt;br /&gt;
     return&lt;br /&gt;
   }&lt;br /&gt;
   if ($gettok(%ClearChanlev.Global, 5, 32) == 0) {&lt;br /&gt;
     echo -s ClearChanlev: You are NOT owner of this channel. Aborting!&lt;br /&gt;
     ClearChanlev.CleanUp&lt;br /&gt;
     return&lt;br /&gt;
   }&lt;br /&gt;
   echo -s ClearChanlev: There are $lines(ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt) lines to send. This will take [[$&amp;amp;]]&lt;br /&gt;
     approximatly $calc($lines(ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt) * $ClearChanlev.Delay / 1000) seconds. Removing... &lt;br /&gt;
   .[[play]] Q ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt $ClearChanlev.Delay&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 alias -l ClearChanlev.CleanUp {&lt;br /&gt;
   .[[remove]] ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt&lt;br /&gt;
   unset %ClearChanlev.*&lt;br /&gt;
   .timerClearChanlevCleanUp off&lt;br /&gt;
   echo -s ClearChanlev: Cleaned up!&lt;br /&gt;
   echo -s ClearChanlev: -----------------------------&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; $1- = message from Q&lt;br /&gt;
 alias -l ClearChanlev.Interpret {&lt;br /&gt;
   if (%ClearChanlev.Global) {&lt;br /&gt;
     if (Username*Flags*Last join*Last changed iswm $1-) {&lt;br /&gt;
       echo -s ClearChanlev: Saving chanlev now...&lt;br /&gt;
       set %ClearChanlev.Global %ClearChanlev.Global 1&lt;br /&gt;
     }&lt;br /&gt;
     elseif (You do not have sufficient access on* iswm $1-) {&lt;br /&gt;
       echo -s ClearChanlev: You do not have sufficied access on the specified channel!&lt;br /&gt;
       ClearChanlev.CleanUp&lt;br /&gt;
     }&lt;br /&gt;
     elseif (End of list. == $1-) { &lt;br /&gt;
       echo -s ClearChanlev: ...done.&lt;br /&gt;
       set %ClearChanlev.Global [[$puttok]](%ClearChanlev.Global, 0, 6, 32)&lt;br /&gt;
       if ([[$numtok]](%ClearChanLev.Users,32)) {&lt;br /&gt;
         [[write]] -il1 ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt REMOVEUSER $gettok(%ClearChanlev.Global, 1, 32) %ClearChanLev.Users&lt;br /&gt;
         unset %ClearChanlev.Users&lt;br /&gt;
       }&lt;br /&gt;
       ClearChanlev.GotMessages&lt;br /&gt;
     }&lt;br /&gt;
     elseif (Channel * is unknown or suspended. iswm $1-) {&lt;br /&gt;
       echo -s ClearChanlev: Channel is not known or suspended. Aborting.&lt;br /&gt;
       ClearChanlev.CleanUp&lt;br /&gt;
     }&lt;br /&gt;
     elseif ($gettok(%ClearChanlev.Global, 6, 32) == 1) {&lt;br /&gt;
       if ($1 == $gettok(%ClearChanlev.Global, 4, 32)) {&lt;br /&gt;
         if (n !isin $2) {&lt;br /&gt;
           set %ClearChanlev.Global $puttok(%ClearChanlev.Global, 0, 5, 32)&lt;br /&gt;
           return&lt;br /&gt;
         }&lt;br /&gt;
         else {&lt;br /&gt;
           set %ClearChanlev.Global $puttok(%ClearChanlev.Global, 1, 5, 32)&lt;br /&gt;
         }&lt;br /&gt;
 &lt;br /&gt;
         if ($gettok(%ClearChanlev.Global, 2, 32) == 0) {&lt;br /&gt;
           return&lt;br /&gt;
         }&lt;br /&gt;
         else {&lt;br /&gt;
           write ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt CHANLEV $gettok(%ClearChanlev.Global, 1, 32) $chr(35) $+ $1 [[$replace]]($2,+,-)&lt;br /&gt;
           return&lt;br /&gt;
         }&lt;br /&gt;
       }&lt;br /&gt;
       else {&lt;br /&gt;
         if (n isin $2) {&lt;br /&gt;
           write -il1 ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt CHANLEV $gettok(%ClearChanlev.Global, 1, 32) $chr(35) $+ $1 $replace($2,+,-)&lt;br /&gt;
         }&lt;br /&gt;
         else {&lt;br /&gt;
           set %ClearChanlev.Users $addtok(%ClearChanLev.users,$chr(35) $+ $1,32)&lt;br /&gt;
           if ($numtok(%ClearChanlev.Users,32) == 18) {&lt;br /&gt;
             write -il1 ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt REMOVEUSER $gettok(%ClearChanlev.Global, 1, 32) %ClearChanlev.Users&lt;br /&gt;
             unset %ClearChanlev.Users&lt;br /&gt;
           }&lt;br /&gt;
         }&lt;br /&gt;
       }&lt;br /&gt;
     }&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 on ^*:[[On_notice|Notice]]:*:?: {&lt;br /&gt;
   if ([[$nick]] == Q) &amp;amp;&amp;amp; (%ClearChanlev.Global) {&lt;br /&gt;
     haltdef&lt;br /&gt;
     ClearChanlev.Interpret $1-&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 on ^*:[[On_text|Text]]:*:?: {&lt;br /&gt;
   if ($nick == Q) &amp;amp;&amp;amp; (%ClearChanlev.Global) {&lt;br /&gt;
     haltdef&lt;br /&gt;
     ClearChanlev.Interpret $1-&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 on *:[[On_playend|PLAYEND]]:{&lt;br /&gt;
   if ([[$nopath]]([[$filename]]) == ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt) {&lt;br /&gt;
     echo -s ClearChanlev: ...done.&lt;br /&gt;
     ClearChanlev.Cleanup&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
[[Category:Script Archive]]&lt;br /&gt;
{{Author|Doomie}}&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Clear-Chanlev_Script_for_QuakeNet&amp;diff=2463</id>
		<title>Clear-Chanlev Script for QuakeNet</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Clear-Chanlev_Script_for_QuakeNet&amp;diff=2463"/>
		<updated>2008-04-12T13:27:11Z</updated>

		<summary type="html">&lt;p&gt;Doomie: added -il1 to fix the order of the commands to send&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt; ; ClearChanlev script by doomie&lt;br /&gt;
 ;   #help.script @ QuakeNet&lt;br /&gt;
 ;&lt;br /&gt;
 ;&lt;br /&gt;
 ; You can use this script by typing:&lt;br /&gt;
 ;&lt;br /&gt;
 ;        /clearchanlev [-c|-r] #channel&lt;br /&gt;
 ; &lt;br /&gt;
 ;   Note, that you must be authed and owner of #channel. &lt;br /&gt;
 ;&lt;br /&gt;
 ;   Flags:&lt;br /&gt;
 ;           * -r ... Resets the script, i.e. cleans everything up. One usually doesn&#039;t need that flag, however, if something didn&#039;t work,&lt;br /&gt;
 ;                    one can use it.  &lt;br /&gt;
 ;           * -c ... If you use this flag, the script will remove you from the channel aswell. This means, that Q will leave the channel&lt;br /&gt;
 ;                    completly. Note that you can _NOT_ reverse it!&lt;br /&gt;
 ;&lt;br /&gt;
 ;&lt;br /&gt;
 ;   Example output:&lt;br /&gt;
 ;&lt;br /&gt;
 ;      ClearChanlev: -----------------------------&lt;br /&gt;
 ;      ClearChanlev: Now beginning to remove all chanlevs from channel #channel except yours!&lt;br /&gt;
 ;      ClearChanlev: Receiving own auth now!&lt;br /&gt;
 ;      ClearChanlev: ...done.&lt;br /&gt;
 ;      ClearChanlev: Saving chanlev now...&lt;br /&gt;
 ;      ClearChanlev: ...done.&lt;br /&gt;
 ;      ClearChanlev: There are 2 lines to send. This will take approximatly 4 seconds. Removing...&lt;br /&gt;
 ;      ClearChanlev: ...done.&lt;br /&gt;
 ;      ClearChanlev: Cleaned up!&lt;br /&gt;
 ;      ClearChanlev: -----------------------------&lt;br /&gt;
 ;&lt;br /&gt;
 &lt;br /&gt;
 ; Returns the milliseconds between every message sent to Q&lt;br /&gt;
 ; If you excess flood, you should increase this value to 4000 or even 5000.&lt;br /&gt;
 [[alias]] -l ClearChanlev.Delay { [[return]] 3000 } &lt;br /&gt;
 &lt;br /&gt;
 ; $1 = #channel&lt;br /&gt;
 ;&lt;br /&gt;
 ; flags:&lt;br /&gt;
 ;   -c --complete = deletes the complete chanlev, inclusive owner. This will&lt;br /&gt;
 ;                   result in Q parting.&lt;br /&gt;
 ;   -r --reset    = resets the scripts in case something didn&#039;t work the last time.&lt;br /&gt;
 alias ClearChanlev {&lt;br /&gt;
   [[echo]] -s ClearChanlev: -----------------------------&lt;br /&gt;
   [[var]] %i = 1, %c, %ClearChanlev.Complete = 0, %r, %ClearChanlev.Force = 0, %ClearChanlev.Channel&lt;br /&gt;
   [[While loops|while]] (%i [[If#.3C.3D|&amp;lt;=]] [[$0]]) {&lt;br /&gt;
     %c = $ [[Evaluation_brackets|[]] [[DollarPlus|$+]] [[Evaluation_brackets|[]] %i [[Evaluation_brackets|] ]]]&lt;br /&gt;
     [[if]] (%c [[If#.3D.3D|==]] -c) [[If#Combining_comparisons|||]] (%c == --complete) {&lt;br /&gt;
       %ClearChanlev.Complete = 1&lt;br /&gt;
     }&lt;br /&gt;
     elseif (%c == -r) || (%c == --reset) {&lt;br /&gt;
       %ClearChanlev.Force = 1&lt;br /&gt;
     }&lt;br /&gt;
     elseif ([[$left]](%c, 1) == [[$chr]](35)) {&lt;br /&gt;
       %ClearChanlev.Channel = %c&lt;br /&gt;
     }&lt;br /&gt;
     [[inc]] %i&lt;br /&gt;
   }&lt;br /&gt;
   if (%ClearChanlev.Global) {&lt;br /&gt;
     if (%ClearChanlev.Force == 0) {&lt;br /&gt;
       echo -s ClearChanlev: ClearChanlev is currently running. If this is not the case, please use the -r flag (i.e. /clearchanlev -r #channel)&lt;br /&gt;
       echo -s ClearChanlev: -----------------------------&lt;br /&gt;
       return&lt;br /&gt;
     }&lt;br /&gt;
     else {&lt;br /&gt;
       [[unset]] %ClearChanlev.Global&lt;br /&gt;
       echo -s ClearChanlev: ClearChanlev reseted.&lt;br /&gt;
     }&lt;br /&gt;
   }&lt;br /&gt;
   if (!%ClearChanlev.Channel) {&lt;br /&gt;
     echo -s ClearChanlev: No channel specified.&lt;br /&gt;
     return&lt;br /&gt;
   }&lt;br /&gt;
   %r = [[$rand]](1,1000)&lt;br /&gt;
   [[set]] %ClearChanlev.Global %ClearChanlev.Channel %ClearChanlev.Complete %r&lt;br /&gt;
   echo -s ClearChanlev: Now beginning to remove all chanlevs from channel %ClearChanlev.Channel [[$iif]](%ClearChanlev.Complete, inclusive, except) yours!&lt;br /&gt;
   echo -s ClearChanlev: Receiving own auth now!&lt;br /&gt;
   .[[timer]]ClearChanlevCleanUp 1 60 ClearChanlev.CleanUp&lt;br /&gt;
   .[[who]] [[$me]] n%nat, $+ %r&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 [[:Category:Raws|raw]] [[Raw_354|354]]:*: {&lt;br /&gt;
   if ([[$1-|$2]] == [[$gettok]](%ClearChanlev.Global, 3, 32)) &amp;amp;&amp;amp; ($3 == $me) {&lt;br /&gt;
     haltdef&lt;br /&gt;
     set %ClearChanlev.Global %ClearChanlev.Global $4&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 raw [[Raw_315|315]]:*: {&lt;br /&gt;
   if (%ClearChanlev.Global) &amp;amp;&amp;amp; ($2 == $me) {&lt;br /&gt;
     [[haltdef]]&lt;br /&gt;
     if ($gettok(%ClearChanlev.Global, 4, 32) == 0) {&lt;br /&gt;
       echo -s ClearChanlev: You are NOT authed.&lt;br /&gt;
       ClearChanlev.CleanUp&lt;br /&gt;
     } &lt;br /&gt;
     else {&lt;br /&gt;
       echo -s ClearChanlev: ...done.&lt;br /&gt;
       set %ClearChanlev.Global %ClearChanlev.Global 0&lt;br /&gt;
       .[[msg]] Q chanlev $gettok(%ClearChanlev.Global, 1, 32)&lt;br /&gt;
     }&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 alias -l ClearChanlev.GotMessages {&lt;br /&gt;
   if (![[$exists]](ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt)) {&lt;br /&gt;
     echo -s ClearChanlev: File does not exist!&lt;br /&gt;
     ClearChanlev.CleanUp&lt;br /&gt;
     return&lt;br /&gt;
   }&lt;br /&gt;
   if ([[$lines]](ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt) == 0) {&lt;br /&gt;
     echo -s ClearChanlev: No chanlev to remove!&lt;br /&gt;
     ClearChanlev.CleanUp&lt;br /&gt;
     return&lt;br /&gt;
   }&lt;br /&gt;
   if ($gettok(%ClearChanlev.Global, 5, 32) == 0) {&lt;br /&gt;
     echo -s ClearChanlev: You are NOT owner of this channel. Aborting!&lt;br /&gt;
     ClearChanlev.CleanUp&lt;br /&gt;
     return&lt;br /&gt;
   }&lt;br /&gt;
   echo -s ClearChanlev: There are $lines(ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt) lines to send. This will take [[$&amp;amp;]]&lt;br /&gt;
     approximatly $calc($lines(ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt) * $ClearChanlev.Delay / 1000) seconds. Removing... &lt;br /&gt;
   .[[play]] Q ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt $ClearChanlev.Delay&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 alias -l ClearChanlev.CleanUp {&lt;br /&gt;
   .[[remove]] ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt&lt;br /&gt;
   unset %ClearChanlev.*&lt;br /&gt;
   .timerClearChanlevCleanUp off&lt;br /&gt;
   echo -s ClearChanlev: Cleaned up!&lt;br /&gt;
   echo -s ClearChanlev: -----------------------------&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; $1- = message from Q&lt;br /&gt;
 alias -l ClearChanlev.Interpret {&lt;br /&gt;
   if (%ClearChanlev.Global) {&lt;br /&gt;
     if (Username*Flags*Last join*Last changed iswm $1-) {&lt;br /&gt;
       echo -s ClearChanlev: Saving chanlev now...&lt;br /&gt;
       set %ClearChanlev.Global %ClearChanlev.Global 1&lt;br /&gt;
     }&lt;br /&gt;
     elseif (You do not have sufficient access on* iswm $1-) {&lt;br /&gt;
       echo -s ClearChanlev: You do not have sufficied access on the specified channel!&lt;br /&gt;
       ClearChanlev.CleanUp&lt;br /&gt;
     }&lt;br /&gt;
     elseif (End of list. == $1-) { &lt;br /&gt;
       echo -s ClearChanlev: ...done.&lt;br /&gt;
       set %ClearChanlev.Global [[$puttok]](%ClearChanlev.Global, 0, 6, 32)&lt;br /&gt;
       if ([[$numtok]](%ClearChanLev.Users,32)) {&lt;br /&gt;
         [[write]] ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt REMOVEUSER $gettok(%ClearChanlev.Global, 1, 32) %ClearChanLev.Users&lt;br /&gt;
         unset %ClearChanlev.Users&lt;br /&gt;
       }&lt;br /&gt;
       ClearChanlev.GotMessages&lt;br /&gt;
     }&lt;br /&gt;
     elseif (Channel * is unknown or suspended. iswm $1-) {&lt;br /&gt;
       echo -s ClearChanlev: Channel is not known or suspended. Aborting.&lt;br /&gt;
       ClearChanlev.CleanUp&lt;br /&gt;
     }&lt;br /&gt;
     elseif ($gettok(%ClearChanlev.Global, 6, 32) == 1) {&lt;br /&gt;
       if ($1 == $gettok(%ClearChanlev.Global, 4, 32)) {&lt;br /&gt;
         if (n !isin $2) {&lt;br /&gt;
           set %ClearChanlev.Global $puttok(%ClearChanlev.Global, 0, 5, 32)&lt;br /&gt;
           return&lt;br /&gt;
         }&lt;br /&gt;
         else {&lt;br /&gt;
           set %ClearChanlev.Global $puttok(%ClearChanlev.Global, 1, 5, 32)&lt;br /&gt;
         }&lt;br /&gt;
 &lt;br /&gt;
         if ($gettok(%ClearChanlev.Global, 2, 32) == 0) {&lt;br /&gt;
           return&lt;br /&gt;
         }&lt;br /&gt;
         else {&lt;br /&gt;
           write ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt CHANLEV $gettok(%ClearChanlev.Global, 1, 32) $chr(35) $+ $1 [[$replace]]($2,+,-)&lt;br /&gt;
           return&lt;br /&gt;
         }&lt;br /&gt;
       }&lt;br /&gt;
       else {&lt;br /&gt;
         if (n isin $2) {&lt;br /&gt;
           write -il1 ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt CHANLEV $gettok(%ClearChanlev.Global, 1, 32) $chr(35) $+ $1 $replace($2,+,-)&lt;br /&gt;
         }&lt;br /&gt;
         else {&lt;br /&gt;
           set %ClearChanlev.Users $addtok(%ClearChanLev.users,$chr(35) $+ $1,32)&lt;br /&gt;
           if ($numtok(%ClearChanlev.Users,32) == 18) {&lt;br /&gt;
             write -il1 ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt REMOVEUSER $gettok(%ClearChanlev.Global, 1, 32) %ClearChanlev.Users&lt;br /&gt;
             unset %ClearChanlev.Users&lt;br /&gt;
           }&lt;br /&gt;
         }&lt;br /&gt;
       }&lt;br /&gt;
     }&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 on ^*:[[On_notice|Notice]]:*:?: {&lt;br /&gt;
   if ([[$nick]] == Q) &amp;amp;&amp;amp; (%ClearChanlev.Global) {&lt;br /&gt;
     haltdef&lt;br /&gt;
     ClearChanlev.Interpret $1-&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 on ^*:[[On_text|Text]]:*:?: {&lt;br /&gt;
   if ($nick == Q) &amp;amp;&amp;amp; (%ClearChanlev.Global) {&lt;br /&gt;
     haltdef&lt;br /&gt;
     ClearChanlev.Interpret $1-&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 on *:[[On_playend|PLAYEND]]:{&lt;br /&gt;
   if ([[$nopath]]([[$filename]]) == ClearChanlev $+ $gettok(%ClearChanlev.Global, 3, 32) $+ .txt) {&lt;br /&gt;
     echo -s ClearChanlev: ...done.&lt;br /&gt;
     ClearChanlev.Cleanup&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
[[Category:Script Archive]]&lt;br /&gt;
{{Author|Doomie}}&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Challenge_auth&amp;diff=2505</id>
		<title>Challenge auth</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Challenge_auth&amp;diff=2505"/>
		<updated>2008-03-24T14:07:10Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt; ; by doomie @ QuakeNet&lt;br /&gt;
 ; channel: #help.script&lt;br /&gt;
 ; written and tested on mIRC 6.31&lt;br /&gt;
 ;&lt;br /&gt;
 ; What does this script do?&lt;br /&gt;
 ;  &lt;br /&gt;
 ;   auths with Q using the &#039;CHALLENGEAUTH&#039; command&lt;br /&gt;
 ;&lt;br /&gt;
 ; How to use this script?&lt;br /&gt;
 ;&lt;br /&gt;
 ;   if you want to auth, just type: /challengeauth&lt;br /&gt;
 ;   However, you need to have the SHA2.dll by slug, which can be downloaded here: &lt;br /&gt;
 ;      http://www.quakenet.org/development/challengeauth/SHA2.dll&lt;br /&gt;
 ;   A general explanation can be found here: &lt;br /&gt;
 ;      http://www.quakenet.org/development/challengeauth/&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 ; CONFIGURE&lt;br /&gt;
 &lt;br /&gt;
 ; $1 = dll function&lt;br /&gt;
 ; $2 = parameter for the dll function&lt;br /&gt;
 alias -l ChallengeAuth.PathToDll { return $mircdirSHA2.dll }&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 ; DONT CHANGE ANYTHING UNDER THIS LINE UNLESS YOU KNOW WHAT YOU ARE DOING&lt;br /&gt;
 alias -l ChallengeAuth.Q { return Q@CServe.quakenet.org }&lt;br /&gt;
 alias -l ChallengeAuth.DLL { return $dll($ChallengeAuth.PathToDll,$1,$2) }&lt;br /&gt;
 &lt;br /&gt;
 ; $1 = string to lower&lt;br /&gt;
 alias -l ChallengeAuth.IRCToLower {&lt;br /&gt;
  return $replacex($lower($1),$chr(91),$chr(123),$chr(93),$chr(125),$chr(92),$chr(124),$chr(94),$chr(126))&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; $1 = Challenge&lt;br /&gt;
 alias -l ChallengeAuth.Auth {&lt;br /&gt;
  var %ChallengeAuth.Username = $ChallengeAuth.IRCToLower($?=&amp;quot;Username&amp;quot;)&lt;br /&gt;
  if ($len(%ChallengeAuth.Username) == 0) {&lt;br /&gt;
    echo -s ChallengeAuth: No Username specified.&lt;br /&gt;
    return&lt;br /&gt;
  }&lt;br /&gt;
 &lt;br /&gt;
  var %ChallengeAuth.Password = $left($?*=&amp;quot;Password&amp;quot;,10)&lt;br /&gt;
  if ($len(%ChallengeAuth.Password) == 0) {&lt;br /&gt;
    echo -s ChallengeAuth: No Password specified.&lt;br /&gt;
    return&lt;br /&gt;
  } &lt;br /&gt;
 &lt;br /&gt;
  var %ChallengeAuth.PasswordHash = $ChallengeAuth.DLL(sha256_hex, %ChallengeAuth.Password)&lt;br /&gt;
  var %ChallengeAuth.Key = $ChallengeAuth.DLL(sha256_hex, %ChallengeAuth.Username $+ : $+ %ChallengeAuth.PasswordHash)&lt;br /&gt;
  var %ChallengeAuth.Response = $ChallengeAuth.DLL(hmac_sha256, %ChallengeAuth.Key $1)&lt;br /&gt;
  !.msg $ChallengeAuth.Q CHALLENGEAUTH %ChallengeAuth.Username %ChallengeAuth.Response HMAC-SHA-256&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 alias ChallengeAuth {&lt;br /&gt;
  if (!$isfile($ChallengeAuth.PathToDll)) {&lt;br /&gt;
    echo -s ChallengeAuth: The path to your SHA2.dll is wrong. Please configure the challengeauth script correctly and/or download the dll from&lt;br /&gt;
    echo -s ChallengeAuth: http://www.quakenet.org/development/challengeauth/SHA2.dll&lt;br /&gt;
    return&lt;br /&gt;
  }&lt;br /&gt;
  set %ChallengeAuth.Active $true&lt;br /&gt;
  echo -s ChallengeAuth: ChallengeAuth is beginning.&lt;br /&gt;
  !.msg $ChallengeAuth.Q challenge&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 on ^*:NOTICE:*:*: {&lt;br /&gt;
  if ($fulladdress === Q!TheQBot@CServe.quakenet.org) &amp;amp;&amp;amp; ($network === QuakeNet) &amp;amp;&amp;amp; ($right($server, 13) === .quakenet.org) {&lt;br /&gt;
    if ($1 === CHALLENGE) &amp;amp;&amp;amp; ($len($2) == 32) &amp;amp;&amp;amp; (%ChallengeAuth.Active) {&lt;br /&gt;
      if ($istok($3-, HMAC-SHA-256, 32)) {&lt;br /&gt;
        .timer 1 0 ChallengeAuth.Auth $2&lt;br /&gt;
      }&lt;br /&gt;
      else {&lt;br /&gt;
        echo -s ChallengeAuth: HMAC-SHA-256 is not supported. ChallengeAuth is NOT continuing.&lt;br /&gt;
      } &lt;br /&gt;
    }&lt;br /&gt;
    elseif ($1- == CHALLENGE is not available once you have authed.) &amp;amp;&amp;amp; (%ChallengeAuth.Active) {&lt;br /&gt;
      echo -s ChallengeAuth: You are already authed!&lt;br /&gt;
      unset %ChallengeAuth.Active&lt;br /&gt;
    }&lt;br /&gt;
    elseif ($1-6 == You are now logged in as) &amp;amp;&amp;amp; (%ChallengeAuth.Active) {&lt;br /&gt;
      echo -s ChallengeAuth: You are now authed!&lt;br /&gt;
      unset %ChallengeAuth.Active&lt;br /&gt;
    }&lt;br /&gt;
    elseif ($1- == Username or password incorrect.) &amp;amp;&amp;amp; (%ChallengeAuth.Active) {&lt;br /&gt;
      echo -s ChallengeAuth: Username or password incorrect.&lt;br /&gt;
      unset %ChallengeAuth.Active&lt;br /&gt;
    }&lt;br /&gt;
  } &lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 raw 401:*: {&lt;br /&gt;
  if ($1- == $me $ChallengeAuth.Q No such nick) &amp;amp;&amp;amp; (%ChallengeAuth.Active) {&lt;br /&gt;
    echo -s ChallengeAuth: Q is currently not reachable. Please try again later.&lt;br /&gt;
    unset %ChallengeAuth.Active&lt;br /&gt;
    haltdef&lt;br /&gt;
  }&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Challenge_auth&amp;diff=2366</id>
		<title>Challenge auth</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Challenge_auth&amp;diff=2366"/>
		<updated>2008-03-23T12:50:59Z</updated>

		<summary type="html">&lt;p&gt;Doomie: parts were missing.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt; ; by doomie @ QuakeNet&lt;br /&gt;
 ; channel: #help.script&lt;br /&gt;
 ; written and tested on mIRC 6.31&lt;br /&gt;
 ;&lt;br /&gt;
 ; What does this script do?&lt;br /&gt;
 ;  &lt;br /&gt;
 ;   auths with Q using the &#039;CHALLENGEAUTH&#039; command&lt;br /&gt;
 ;&lt;br /&gt;
 ; How to use this script?&lt;br /&gt;
 ;&lt;br /&gt;
 ;   if you want to auth, just type: /challengeauth&lt;br /&gt;
 ;   However, you need to have the SHA2.dll by slug, which can be downloaded here: &lt;br /&gt;
 ;      http://www.quakenet.org/development/challengeauth/SHA2.dll&lt;br /&gt;
 ;   A general explanation can be found here: &lt;br /&gt;
 ;      http://www.quakenet.org/development/challengeauth/&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 ; CONFIGURE&lt;br /&gt;
 &lt;br /&gt;
 ; $1 = dll function&lt;br /&gt;
 ; $2 = parameter for the dll function&lt;br /&gt;
 alias -l ChallengeAuth.PathToDll { return $mircdirSHA2.dll }&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 ; DONT CHANGE ANYTHING UNDER THIS LINE UNLESS YOU KNOW WHAT YOU ARE DOING&lt;br /&gt;
 alias -l ChallengeAuth.Q { return Q@CServe.quakenet.org }&lt;br /&gt;
 alias -l ChallengeAuth.DLL { return $dll($ChallengeAuth.PathToDll,$1,$2) }&lt;br /&gt;
 &lt;br /&gt;
 ; $1 = string to lower&lt;br /&gt;
 alias -l ChallengeAuth.IRCToLower {&lt;br /&gt;
  return $replacex($lower($1),$chr(91),$chr(123),$chr(93),$chr(125),$chr(92),$chr(124),$chr(94),$chr(126))&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; $1 = Challenge&lt;br /&gt;
 alias -l ChallengeAuth.Auth {&lt;br /&gt;
  var %ChallengeAuth.Username = $ChallengeAuth.IRCToLower($?=&amp;quot;Username&amp;quot;)&lt;br /&gt;
  if ($len(%ChallengeAuth.Username) == 0) {&lt;br /&gt;
    echo -s ChallengeAuth: No Username specified.&lt;br /&gt;
    return&lt;br /&gt;
  }&lt;br /&gt;
 &lt;br /&gt;
  var %ChallengeAuth.Password = $left($?=&amp;quot;Password&amp;quot;,10)&lt;br /&gt;
  if ($len(%ChallengeAuth.Password) == 0) {&lt;br /&gt;
    echo -s ChallengeAuth: No Password specified.&lt;br /&gt;
    return&lt;br /&gt;
  } &lt;br /&gt;
 &lt;br /&gt;
  var %ChallengeAuth.PasswordHash = $ChallengeAuth.DLL(sha256_hex, %ChallengeAuth.Password)&lt;br /&gt;
  var %ChallengeAuth.Key = $ChallengeAuth.DLL(sha256_hex, %ChallengeAuth.Username $+ : $+ %ChallengeAuth.PasswordHash)&lt;br /&gt;
  var %ChallengeAuth.Response = $ChallengeAuth.DLL(hmac_sha256, %ChallengeAuth.Key $1)&lt;br /&gt;
  !.msg $ChallengeAuth.Q CHALLENGEAUTH %ChallengeAuth.Username %ChallengeAuth.Response HMAC-SHA-256&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 alias ChallengeAuth {&lt;br /&gt;
  if (!$isfile($ChallengeAuth.PathToDll)) {&lt;br /&gt;
    echo -s ChallengeAuth: The path to your SHA2.dll is wrong. Please configure the challengeauth script correctly and/or download the dll from&lt;br /&gt;
    echo -s ChallengeAuth: http://www.quakenet.org/development/challengeauth/SHA2.dll&lt;br /&gt;
    return&lt;br /&gt;
  }&lt;br /&gt;
  set %ChallengeAuth.Active $true&lt;br /&gt;
  echo -s ChallengeAuth: ChallengeAuth is beginning.&lt;br /&gt;
  !.msg $ChallengeAuth.Q challenge&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 on ^*:NOTICE:*:*: {&lt;br /&gt;
  if ($fulladdress === Q!TheQBot@CServe.quakenet.org) &amp;amp;&amp;amp; ($network === QuakeNet) &amp;amp;&amp;amp; ($right($server, 13) === .quakenet.org) {&lt;br /&gt;
    if ($1 === CHALLENGE) &amp;amp;&amp;amp; ($len($2) == 32) &amp;amp;&amp;amp; (%ChallengeAuth.Active) {&lt;br /&gt;
      if ($istok($3-, HMAC-SHA-256, 32)) {&lt;br /&gt;
        .timer 1 0 ChallengeAuth.Auth $2&lt;br /&gt;
      }&lt;br /&gt;
      else {&lt;br /&gt;
        echo -s ChallengeAuth: HMAC-SHA-256 is not supported. ChallengeAuth is NOT continuing.&lt;br /&gt;
      } &lt;br /&gt;
    }&lt;br /&gt;
    elseif ($1- == CHALLENGE is not available once you have authed.) &amp;amp;&amp;amp; (%ChallengeAuth.Active) {&lt;br /&gt;
      echo -s ChallengeAuth: You are already authed!&lt;br /&gt;
      unset %ChallengeAuth.Active&lt;br /&gt;
    }&lt;br /&gt;
    elseif ($1-6 == You are now logged in as) &amp;amp;&amp;amp; (%ChallengeAuth.Active) {&lt;br /&gt;
      echo -s ChallengeAuth: You are now authed!&lt;br /&gt;
      unset %ChallengeAuth.Active&lt;br /&gt;
    }&lt;br /&gt;
    elseif ($1- == Username or password incorrect.) &amp;amp;&amp;amp; (%ChallengeAuth.Active) {&lt;br /&gt;
      echo -s ChallengeAuth: Username or password incorrect.&lt;br /&gt;
      unset %ChallengeAuth.Active&lt;br /&gt;
    }&lt;br /&gt;
  } &lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 raw 401:*: {&lt;br /&gt;
  if ($1- == $me $ChallengeAuth.Q No such nick) &amp;amp;&amp;amp; (%ChallengeAuth.Active) {&lt;br /&gt;
    echo -s ChallengeAuth: Q is currently not reachable. Please try again later.&lt;br /&gt;
    unset %ChallengeAuth.Active&lt;br /&gt;
    haltdef&lt;br /&gt;
  }&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Challenge_auth&amp;diff=2365</id>
		<title>Challenge auth</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Challenge_auth&amp;diff=2365"/>
		<updated>2008-03-23T12:49:00Z</updated>

		<summary type="html">&lt;p&gt;Doomie: updated to the new CHALLENGEAUTH command&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt; ; by doomie @ QuakeNet&lt;br /&gt;
 ; channel: #help.script&lt;br /&gt;
 ; written and tested on mIRC 6.31&lt;br /&gt;
 ;&lt;br /&gt;
 ; What does this script do?&lt;br /&gt;
 ;  &lt;br /&gt;
 ;   auths with Q using the &#039;CHALLENGEAUTH&#039; command&lt;br /&gt;
 ;&lt;br /&gt;
 ; How to use this script?&lt;br /&gt;
 ;&lt;br /&gt;
 ;   if you want to auth, just type: /challengeauth&lt;br /&gt;
 ;   However, you need to have the SHA2.dll by slug, which can be downloaded here: &lt;br /&gt;
 ;      http://www.quakenet.org/development/challengeauth/SHA2.dll&lt;br /&gt;
 ;   A general explanation can be found here: &lt;br /&gt;
 ;      http://www.quakenet.org/development/challengeauth/&lt;br /&gt;
   &lt;br /&gt;
 &lt;br /&gt;
 ; CONFIGURE&lt;br /&gt;
 &lt;br /&gt;
 ; $1 = dll function&lt;br /&gt;
 ; $2 = parameter for the dll function&lt;br /&gt;
 alias -l ChallengeAuth.PathToDll { return $mircdirSHA2.dll }&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 ; DONT CHANGE ANYTHING UNDER THIS LINE UNLESS YOU KNOW WHAT YOU ARE DOING&lt;br /&gt;
 alias -l ChallengeAuth.Q { return Q@CServe.quakenet.org }&lt;br /&gt;
 alias -l ChallengeAuth.DLL { return $dll($ChallengeAuth.PathToDll,$1,$2) }&lt;br /&gt;
 &lt;br /&gt;
 ; $1 = string to lower&lt;br /&gt;
 alias -l ChallengeAuth.IRCToLower {&lt;br /&gt;
  return $replacex($lower($1),$chr(91),$chr(123),$chr(93),$chr(125),$chr(92),$chr(124),$chr(94),$chr(126))&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; $1 = Challenge&lt;br /&gt;
 alias -l ChallengeAuth.Auth {&lt;br /&gt;
  var %ChallengeAuth.Username = $ChallengeAuth.IRCToLower($?=&amp;quot;Username&amp;quot;)&lt;br /&gt;
  if ($len(%ChallengeAuth.Username) == 0) {&lt;br /&gt;
    echo -s ChallengeAuth: No Username specified.&lt;br /&gt;
    return&lt;br /&gt;
  }&lt;br /&gt;
 &lt;br /&gt;
  var %ChallengeAuth.Password = $left($?=&amp;quot;Password&amp;quot;,10)&lt;br /&gt;
  if ($len(%ChallengeAuth.Password) == 0) {&lt;br /&gt;
    echo -s ChallengeAuth: No Password specified.&lt;br /&gt;
    return&lt;br /&gt;
  } &lt;br /&gt;
 &lt;br /&gt;
  var %ChallengeAuth.PasswordHash = $ChallengeAuth.DLL(sha256_hex, %ChallengeAuth.Password)&lt;br /&gt;
  var %ChallengeAuth.Key = $ChallengeAuth.DLL(sha256_hex, %ChallengeAuth.Username $+ : $+ %ChallengeAuth.PasswordHash)&lt;br /&gt;
  var %ChallengeAuth.Response = $ChallengeAuth.DLL(hmac_sha256, %ChallengeAuth.Key $1)&lt;br /&gt;
  !.msg $ChallengeAuth.Q CHALLENGEAUTH %ChallengeAuth.Username %ChallengeAuth.Response HMAC-SHA-256&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 alias ChallengeAuth {&lt;br /&gt;
  if (!$isfile($ChallengeAuth.PathToDll)) {&lt;br /&gt;
    echo -s ChallengeAuth: The path to your SHA2.dll is wrong. Please configure the challengeauth script correctly and/or download the dll from&lt;br /&gt;
    echo -s ChallengeAuth: http://www.quakenet.org/development/challengeauth/SHA2.dll&lt;br /&gt;
    return&lt;br /&gt;
  }&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=User:Doomie&amp;diff=3888</id>
		<title>User:Doomie</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=User:Doomie&amp;diff=3888"/>
		<updated>2008-02-15T11:10:52Z</updated>

		<summary type="html">&lt;p&gt;Doomie: age&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Babel-2|de|en-3}}&lt;br /&gt;
&amp;lt;table border=&amp;quot;0&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;!--&amp;lt;td&amp;gt;[[Image:Doomie.jpg]]&amp;lt;/td&amp;gt;--&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;&lt;br /&gt;
  &amp;lt;table border=&amp;quot;0&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;b&amp;gt;Name&amp;lt;/b&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;Philipp Krone&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;b&amp;gt;Age&amp;lt;/b&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;20&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr valign=&amp;quot;top&amp;quot; height=&amp;quot;40&amp;quot;&amp;gt;&amp;lt;td&amp;gt;&amp;lt;b&amp;gt;Country&amp;lt;/b&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;Chemnitz, Germany&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;b&amp;gt;Words of wisdom&amp;lt;/b&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;Mhh, moo!&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
[[Category:Members]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Silence&amp;diff=1735</id>
		<title>Silence</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Silence&amp;diff=1735"/>
		<updated>2007-01-17T21:59:36Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Adds or removes an address from your silence list.&lt;br /&gt;
 /silence [[+|-]&amp;lt;mask&amp;gt;|&amp;lt;nick&amp;gt;]&lt;br /&gt;
&lt;br /&gt;
This command silences/unsilences the specified nick/mask. The silence works server side, unlike [[ignore]] you won&#039;t receive the messages. The number of silences you can set is given on connect by [[Raw_005|raw 005]]. On Quakenet the silence list is normally limited to 15. &#039;&#039;&#039;Note&#039;&#039;&#039; that all entries of your silence list are deleted if you disconnect.&lt;br /&gt;
&lt;br /&gt;
Results are replied with a [[:Category:Raw_silence|raw]].&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
 silence&lt;br /&gt;
Shows your silence list.&lt;br /&gt;
 silence *!*@*moo &lt;br /&gt;
This would silence every user with a mask matching *!*@*moo.&lt;br /&gt;
 silence +fishbot &lt;br /&gt;
This would silence the nick fishbot.&lt;br /&gt;
 silence -fishbot &lt;br /&gt;
This removes silence of the nick fishbot if its in your silence list.&lt;br /&gt;
 silence -* &lt;br /&gt;
Removes all silences&lt;br /&gt;
&lt;br /&gt;
[[Category:Raw_silence]][[Category:Basic IRC commands]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Silence&amp;diff=1734</id>
		<title>Silence</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Silence&amp;diff=1734"/>
		<updated>2007-01-17T21:59:23Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Adds or removes an address from your silence list.&lt;br /&gt;
 /silence [[+|-]&amp;lt;mask&amp;gt;|&amp;lt;nick&amp;gt;]&lt;br /&gt;
&lt;br /&gt;
This command silences/unsilences the specified nick/mask. The silence works server side, unlike [[ignore]] you won&#039;t receive the messages. The number of silences you can set is given on connect by [[Raw_005|raw 005]]. On Quakenet the silence list is normally limited to 15. &#039;&#039;Note&#039;&#039; that all entries of your silence list are deleted if you disconnect.&lt;br /&gt;
&lt;br /&gt;
Results are replied with a [[:Category:Raw_silence|raw]].&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
 silence&lt;br /&gt;
Shows your silence list.&lt;br /&gt;
 silence *!*@*moo &lt;br /&gt;
This would silence every user with a mask matching *!*@*moo.&lt;br /&gt;
 silence +fishbot &lt;br /&gt;
This would silence the nick fishbot.&lt;br /&gt;
 silence -fishbot &lt;br /&gt;
This removes silence of the nick fishbot if its in your silence list.&lt;br /&gt;
 silence -* &lt;br /&gt;
Removes all silences&lt;br /&gt;
&lt;br /&gt;
[[Category:Raw_silence]][[Category:Basic IRC commands]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=News&amp;diff=1692</id>
		<title>News</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=News&amp;diff=1692"/>
		<updated>2006-08-27T12:43:52Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;!-- Use ~ four times to get signature with timestamp, also available at the toolbar, second button from right --&amp;gt;&lt;br /&gt;
&amp;lt;!-- Copy&amp;amp;Paste: {{newsWriter|~ four times}} --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== mIRC 6.2 is out ==&lt;br /&gt;
{{newsWriter|[[User:Cail|Cail]] 14:48, 27 Aug 2006 (CET)}}&lt;br /&gt;
&lt;br /&gt;
mIRC 6.2 was released July 28th 2006, get it at [http://www.mirc.com www.mirc.com]. Take a look at the [[MIRC 6.2|list of changes]] aswell.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Changes to Scriptwiki ==&lt;br /&gt;
{{newsWriter|[[User:Microbe|Microbe]] 00:39, 5 May 2006 (CEST)}}&lt;br /&gt;
&lt;br /&gt;
Scriptwiki has gone through some changes, again. It has been made an official QuakeNet wiki and recruiting new editors has been made easier - the process should now be far faster and more user-friendly. So if you&#039;re interested in contributing to this wiki, have a look at the front page&#039;s instructions.&lt;br /&gt;
&lt;br /&gt;
== mIRC 6.17 is out ==&lt;br /&gt;
{{newsWriter|[[User:Microbe|Microbe]] 00:31, 18 Feb 2006 (CET)}}&lt;br /&gt;
&lt;br /&gt;
mIRC version 6.17 has been released an hour ago. Read more about it and download it at [http://www.mirc.com www.mirc.com].&lt;br /&gt;
&lt;br /&gt;
== Scriptwiki has been globalized ==&lt;br /&gt;
{{newsWriter|[[User:Microbe|Microbe]] 04:03, 4 Feb 2006 (CET)}}&lt;br /&gt;
&lt;br /&gt;
Scriptwiki has gone through some changes. The project started as a small one-channel project, but it is now released &amp;quot;to the wild&amp;quot;. People interested to contribute to this wiki are encouraged to contact us, especially from other networks than QuakeNet. At the moment this wiki is dedicated more towards QuakeNet users, but we are hoping that this will change in the future. Users from every network should be able to get the information they need from here, especially network-specific raw events.&lt;br /&gt;
&lt;br /&gt;
So if you want to contribute to the only wiki dedicated to mIRC scripting (at least at the moment), see the main page for more information.&lt;br /&gt;
&lt;br /&gt;
== Welcome to Scriptwiki ==&lt;br /&gt;
{{newsWriter|[[User:Tovrleaf|Tovrleaf]] 22:53, 15 Sep 2005 (CEST)}}&lt;br /&gt;
&lt;br /&gt;
Hi, and welcome to our new published &#039;&#039;&#039;Scriptwiki&#039;&#039;&#039;. Scriptwiki (as we call it) is our new lifelong project which won&#039;t probably ever be finished. It shall be developed and expanded along with mIRC and new scripting skills.&lt;br /&gt;
&lt;br /&gt;
Special thanks to all users who have helped us to get this to shape and to create a more user friendly wiki and articles.&lt;br /&gt;
&lt;br /&gt;
If you think this wiki is missing some essential articles, there&#039;s a page to [[Special:Request|request]] new articles for it. And don&#039;t forget to give us [[:Special:SendComment|feedback]], comments, ideas or new suggestions.&lt;br /&gt;
&lt;br /&gt;
== Scriptwiki starting ==&lt;br /&gt;
{{newsWriter|[[User:Microbe|Microbe]] 12:53, 24 Aug 2005 (CEST)}}&lt;br /&gt;
&lt;br /&gt;
Scriptwiki starting to get in shape&lt;br /&gt;
&lt;br /&gt;
__NOTOC__&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Guidelines&amp;diff=1403</id>
		<title>Guidelines</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Guidelines&amp;diff=1403"/>
		<updated>2006-05-05T12:03:47Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;As this wiki is supposed to be very user-friendly, all articles should follow the guidelines listed in here. Please note that we will not accept any articles not following these rules and reserve the right to block your account in case you break these rules repeatedly.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The following syntax is to be used in ALL mIRC help pages. (Parts like &amp;quot;use italic in return values&amp;quot; are to be used in full tutorials &amp;amp; scripts aswell.)&lt;br /&gt;
&lt;br /&gt;
If you wish to add comments to your examples (to the same &#039;example box&#039;) in the article, you can do it either by adding two spaces and a ; (like: echo -a blah  ;this is an echo) OR adding the comment to the next line, starting it with a space and a ;. Comments outside the &#039;example box&#039; shouldn&#039;t include the ;. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Topic (the name of the page) examples&#039;&#039;&#039;&lt;br /&gt;
* $variable &lt;br /&gt;
* Command&lt;br /&gt;
* On_join&lt;br /&gt;
* If-Then-Else&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;First line of the text&#039;&#039;&#039;&lt;br /&gt;
* Short description what it does / what it&#039;s good for.&lt;br /&gt;
** Example: Returns the Nth token in text. A token is blah blah blah.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Second line of the text&#039;&#039;&#039;&lt;br /&gt;
* The syntax, starting with a space to get a box around it.&lt;br /&gt;
** Example: (space)$gettok(text,N,C)&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Next one/few line(s) of the text&#039;&#039;&#039;&lt;br /&gt;
* Explanation what the non-trivial parameters mean. The parameter(s) is/are to be inside &amp;lt;nowiki&amp;gt;&#039;&#039; &#039;&#039;&amp;lt;/nowiki&amp;gt; to make it italic.&lt;br /&gt;
** Example: &#039;&#039;C&#039;&#039; is the [[ascii]] number of the character that is set to separate the tokens blah blah.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Next one/few line(s) of the text&#039;&#039;&#039;&lt;br /&gt;
* Short example(s) how to use the command/identifier/whatever. The (possible) return value is to be inside &amp;lt;nowiki&amp;gt;&#039;&#039; &#039;&#039;&amp;lt;/nowiki&amp;gt; to make it italic.&lt;br /&gt;
** Example: //echo -a $gettok(this.is.text,2,46) returns &#039;&#039;is&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Sections&#039;&#039;&#039;&lt;br /&gt;
* If the command/identifier/whatever is complex enough to be needed to demonstrate further, use &amp;lt;nowiki&amp;gt;== Examples ==&amp;lt;/nowiki&amp;gt; to start a section with more examples. Remember to add links to other wiki items  such as &amp;lt;nowiki&amp;gt;[[var]]&amp;lt;/nowiki&amp;gt; for the first occurence in each article. All example lines are to be started with a space and all return values are to be put inside &amp;lt;nowiki&amp;gt;&#039;&#039; &#039;&#039;&amp;lt;/nowiki&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Add &amp;quot;See also&amp;quot; and Category&#039;&#039;&#039;&lt;br /&gt;
* It&#039;s good to add a &#039;see also&#039; section with &amp;lt;nowiki&amp;gt;== See also ==&amp;lt;/nowiki&amp;gt; at the end of the article that contains useful links to similar commands/identifiers/whatever. Remember also to add the article to the correct category/categories with adding &amp;lt;nowiki&amp;gt;[[Category:name_of_the_category]] at the end. Like [[Category:Text and Number Identifiers]]&amp;lt;/nowiki&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Stubs&#039;&#039;&#039;&lt;br /&gt;
* If you know your article is incomplete you can add &amp;lt;nowiki&amp;gt;{{Stub}}&amp;lt;/nowiki&amp;gt; marking it as incomplete and placing it in the [[:Category:Stubs]] for others/yourself to complete later on. It appears to look the best if you add it at the top of the page. To make sure whoever reads the article knows that it is incomplete.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Shared articles&#039;&#039;&#039;&lt;br /&gt;
* &amp;lt;nowiki&amp;gt;{{Disambling}}&amp;lt;/nowiki&amp;gt; is used to split articles into smaller pieces when article holds reference to more than one article and it&#039;s &#039;&#039;&#039;not&#039;&#039;&#039; unambiguous where it should belong.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Feel free to ask any editor if you are unsure about specific subjects. To get an example, just take a look at already added articles.&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Guidelines&amp;diff=1402</id>
		<title>Guidelines</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Guidelines&amp;diff=1402"/>
		<updated>2006-05-05T11:59:11Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;As this wiki is supposed to be very user-friendly, all articles should follow the guidelines listed in here. Please note that we will not accept any articles not following these rules and reserve the right to block your account in case you break these rules repeatedly.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Topic (the name of the page) examples&#039;&#039;&#039;&lt;br /&gt;
* $variable &lt;br /&gt;
* Command&lt;br /&gt;
* On_join&lt;br /&gt;
* If-Then-Else&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;First line of the text&#039;&#039;&#039;&lt;br /&gt;
* Short description what it does / what it&#039;s good for.&lt;br /&gt;
** Example: Returns the Nth token in text. A token is blah blah blah.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Second line of the text&#039;&#039;&#039;&lt;br /&gt;
* The syntax, starting with a space to get a box around it.&lt;br /&gt;
** Example: (space)$gettok(text,N,C)&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Next one/few line(s) of the text&#039;&#039;&#039;&lt;br /&gt;
* Explanation what the non-trivial parameters mean. The parameter(s) is/are to be inside &amp;lt;nowiki&amp;gt;&#039;&#039; &#039;&#039;&amp;lt;/nowiki&amp;gt; to make it italic.&lt;br /&gt;
** Example: &#039;&#039;C&#039;&#039; is the [[ascii]] number of the character that is set to separate the tokens blah blah.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Next one/few line(s) of the text&#039;&#039;&#039;&lt;br /&gt;
* Short example(s) how to use the command/identifier/whatever. The (possible) return value is to be inside &amp;lt;nowiki&amp;gt;&#039;&#039; &#039;&#039;&amp;lt;/nowiki&amp;gt; to make it italic.&lt;br /&gt;
** Example: //echo -a $gettok(this.is.text,2,46) returns &#039;&#039;is&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Sections&#039;&#039;&#039;&lt;br /&gt;
* If the command/identifier/whatever is complex enough to be needed to demonstrate further, use &amp;lt;nowiki&amp;gt;== Examples ==&amp;lt;/nowiki&amp;gt; to start a section with more examples. Remember to add links to other wiki items  such as &amp;lt;nowiki&amp;gt;[[var]]&amp;lt;/nowiki&amp;gt; for the first occurence in each article. All example lines are to be started with a space and all return values are to be put inside &amp;lt;nowiki&amp;gt;&#039;&#039; &#039;&#039;&amp;lt;/nowiki&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Add &amp;quot;See also&amp;quot; and Category&#039;&#039;&#039;&lt;br /&gt;
* It&#039;s good to add a &#039;see also&#039; section with &amp;lt;nowiki&amp;gt;== See also ==&amp;lt;/nowiki&amp;gt; at the end of the article that contains useful links to similar commands/identifiers/whatever. Remember also to add the article to the correct category/categories with adding &amp;lt;nowiki&amp;gt;[[Category:name_of_the_category]] at the end. Like [[Category:Text and Number Identifiers]]&amp;lt;/nowiki&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Stubs&#039;&#039;&#039;&lt;br /&gt;
* If you know your article is incomplete you can add &amp;lt;nowiki&amp;gt;{{Stub}}&amp;lt;/nowiki&amp;gt; marking it as incomplete and placing it in the [[:Category:Stubs]] for others/yourself to complete later on. It appears to look the best if you add it at the top of the page. To make sure whoever reads the article knows that it is incomplete.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Shared articles&#039;&#039;&#039;&lt;br /&gt;
* &amp;lt;nowiki&amp;gt;{{Disambling}}&amp;lt;/nowiki&amp;gt; is used to split articles into smaller pieces when article holds reference to more than one article and it&#039;s &#039;&#039;&#039;not&#039;&#039;&#039; unambiguous where it should belong.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Feel free to ask any editor if you are unsure about specific subjects. To get an example, just take a look at already added articles.&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Guidelines&amp;diff=1401</id>
		<title>Guidelines</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Guidelines&amp;diff=1401"/>
		<updated>2006-05-05T11:58:35Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;As this wiki is supposed to be very user-friendly, all articles should follow the guidelines listed in here. Please note that we will not accept any articles not following these rules and reserve the right to block your account in case you break these rules repeatedly.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Topic (the name of the page) examples&#039;&#039;&#039;&lt;br /&gt;
* $variable &lt;br /&gt;
* Command&lt;br /&gt;
* On_join&lt;br /&gt;
* If-Then-Else&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;First line of the text&#039;&#039;&#039;&lt;br /&gt;
* Short description what it does / what it&#039;s good for.&lt;br /&gt;
** Example: Returns the Nth token in text. A token is blah blah blah.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Second line of the text&#039;&#039;&#039;&lt;br /&gt;
* The syntax, starting with a space to get a box around it.&lt;br /&gt;
** Example: (space)$gettok(text,N,C)&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Next one/few line(s) of the text&#039;&#039;&#039;&lt;br /&gt;
* Explanation what the non-trivial parameters mean. The parameter(s) is/are to be inside &amp;lt;nowiki&amp;gt;&#039;&#039; &#039;&#039;&amp;lt;/nowiki&amp;gt; to make it italic.&lt;br /&gt;
** Example: &#039;&#039;C&#039;&#039; is the [[ascii]] number of the character that is set to separate the tokens blah blah.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Next one/few line(s) of the text&#039;&#039;&#039;&lt;br /&gt;
* Short example(s) how to use the command/identifier/whatever. The (possible) return value is to be inside &amp;lt;nowiki&amp;gt;&#039;&#039; &#039;&#039;&amp;lt;/nowiki&amp;gt; to make it italic.&lt;br /&gt;
** Example: //echo -a $gettok(this.is.text,2,46) returns &#039;&#039;is&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Sections&#039;&#039;&#039;&lt;br /&gt;
* If the command/identifier/whatever is complex enough to be needed to demonstrate further, use &amp;lt;nowiki&amp;gt;== Examples ==&amp;lt;/nowiki&amp;gt; to start a section with more examples. Remember to add links to other wiki items  such as &amp;lt;nowiki&amp;gt;[[var]]&amp;lt;/nowiki&amp;gt; for the first occurence in each article. All example lines are to be started with a space and all return values are to be put inside &amp;lt;nowiki&amp;gt;&#039;&#039; &#039;&#039;&amp;lt;/nowiki&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Add &amp;quot;See also&amp;quot; and Category&#039;&#039;&#039;&lt;br /&gt;
* It&#039;s good to add a &#039;see also&#039; section with &amp;lt;nowiki&amp;gt;== See also ==&amp;lt;/nowiki&amp;gt; at the end of the article that contains useful links to similar commands/identifiers/whatever. Remember also to add the article to the correct category/categories with adding &amp;lt;nowiki&amp;gt;[[Category:name_of_the_category]] at the end. Like [[Category:Text and Number Identifiers]]&amp;lt;/nowiki&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Stubs&#039;&#039;&#039;&lt;br /&gt;
* If you know your article is incomplete you can add &amp;lt;nowiki&amp;gt;{{Stub}}&amp;lt;/nowiki&amp;gt; marking it as incomplete and placing it in the [[:Category:Stubs]] for others/yourself to complete later on. It appears to look the best if you add it at the top of the page. To make sure whoever reads the article knows that it is incomplete.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Shared articles&#039;&#039;&#039;&lt;br /&gt;
* &amp;lt;nowiki&amp;gt;{{Disambling}}&amp;lt;/nowiki&amp;gt; is used to split articles into smaller pieces when article holds reference to more than one article and it&#039;s &#039;&#039;&#039;not&#039;&#039;&#039; unambiguous where it should belong.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Feel free to ask any editor if you are unsure about specific subjects. To get examples, just take a look at already added articles.&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Guidelines&amp;diff=1400</id>
		<title>Guidelines</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Guidelines&amp;diff=1400"/>
		<updated>2006-05-05T11:37:39Z</updated>

		<summary type="html">&lt;p&gt;Doomie: first one to save the sentences&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;As this wiki is supposed to be very user-friendly, all articles should follow the guidelines listed in here. Please note that we will not accept any articles not following these rules and reserve the right to block your account in case you break these rules repeatedly.&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Category:Aliases&amp;diff=2147</id>
		<title>Category:Aliases</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Category:Aliases&amp;diff=2147"/>
		<updated>2006-04-25T13:04:15Z</updated>

		<summary type="html">&lt;p&gt;Doomie: /* Naming aliases */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Basic ==&lt;br /&gt;
mIRC script allows you to create your own set of commands and identifiers, refered to as aliases. Aliases can be called from the command line, from other aliases, from popup and from remote scripts. An alias in mIRC can not be called recursively. They can be created by either putting them in the &amp;lt;nowiki&amp;gt;&amp;quot;Aliases&amp;quot;&amp;lt;/nowiki&amp;gt; section of the mIRC Scripts Editor, by using the /alias command from either the command line or in the &amp;lt;nowiki&amp;gt;&amp;quot;Remote&amp;quot;&amp;lt;/nowiki&amp;gt; section of the Scripts Editor. Creating an alias in the command line results in it being placed in the &amp;quot;Aliases&amp;quot; section of the Script Editor.&lt;br /&gt;
&lt;br /&gt;
=== Example ===&lt;br /&gt;
 ; These two work exactly the same way although they are stored in different places&lt;br /&gt;
 &lt;br /&gt;
 ; this is placed in the &amp;quot;Aliases&amp;quot; section&lt;br /&gt;
 moo { [[echo]] -ag moo }&lt;br /&gt;
 &lt;br /&gt;
 ; this is placed in the &amp;quot;Remote&amp;quot; section&lt;br /&gt;
 [[alias]] moo { [[echo]] -ag moo }&lt;br /&gt;
&lt;br /&gt;
== Naming aliases ==&lt;br /&gt;
You can give an alias virtually any name you want, but keep a few things in mind:&lt;br /&gt;
&lt;br /&gt;
* When you give an alias used as a command the same name as an existing mIRC command, your alias gets preference.&lt;br /&gt;
* Some inbuilt commands act differently than the rest, if you have an alias called [[timertest|Timer]], you will not be able to start a timer called test, like this: /timertest 0 1 MyTestFunction in this situation you can prefix the command with an exclamation mark (!) as shown below in the example.&lt;br /&gt;
* When you give an alias used as an identifier the same name as an existing mIRC identifier, mIRC&#039;s identifier gets preference, unless you prefix your alias with a period.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&lt;br /&gt;
 ; at first we add a new alias called &amp;quot;me&amp;quot;. If it is used as &amp;quot;$me&amp;quot;, it&#039;s supposed to return &amp;quot;AveIT!&amp;quot;, else it&#039;s the usual&lt;br /&gt;
 ; /me alias sending an action to the active channel&lt;br /&gt;
 /alias me { [[If-Then-Else|if]] ([[$isid]]) { [[return]] AveIT! } | else { [[describe]] [[$active]] [[$1-]] } }&lt;br /&gt;
  &lt;br /&gt;
 ; this alias will return the amount of milliseconds (ticks) pasted between two callings. &lt;br /&gt;
 ; When called the first time, it will set a variable %timerstart to the current value of $ticks.&lt;br /&gt;
 ; When called the second time, it echo&#039;s the difference between the set variable and the current value of ticks.&lt;br /&gt;
 ; This difference is obviously the elapsed time.&lt;br /&gt;
 /alias timertest { if (!%timerstart) [[set]] %timerstart [[$ticks]] | else { echo -ag [[$calc]]($ticks - %timerstart) ms | unset  %timerstart } }&lt;br /&gt;
 &lt;br /&gt;
In the following example, both the custom &#039;me&#039; and the &#039;timertest&#039; alias will be used:&lt;br /&gt;
&lt;br /&gt;
 ; call timertest the first time to set the variable %timertest&lt;br /&gt;
 timertest&lt;br /&gt;
  &lt;br /&gt;
 ; echo $me (that&#039;s the default $me alias as it can&#039;t be overwritten in the usual way)&lt;br /&gt;
 ; and $.me (that&#039;s our custom alias returning &#039;AveIT!&#039;)&lt;br /&gt;
 echo -ag I am $me but my custom identifer returns $.me&lt;br /&gt;
  &lt;br /&gt;
 ; call timertest a second time to echo the amount of elapsed milliseconds&lt;br /&gt;
 timertest&lt;br /&gt;
&lt;br /&gt;
Finally, the example above would return:&lt;br /&gt;
&lt;br /&gt;
 I am Dana but my custom identifer returns AveIT!&lt;br /&gt;
 16 ms&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Note:&#039;&#039;&#039;&#039;&#039; If you want to start a timer called test with the alias called timertest, you have to prefix the timer with the ! to use the inbuilt mIRC timer command:&lt;br /&gt;
!timertest 1 1 echo -ag This is my test.&lt;br /&gt;
It is not encouraged to call an alias starting with timer, or identifers with mircdir, getdir, mididir, or any other alias which can be used with a suffix.&lt;br /&gt;
&lt;br /&gt;
== Aliases: parameters and events ==&lt;br /&gt;
mIRC script allows you to pass parameters to your aliases, just like you pass parameters into built-in mIRC commands or identifiers. They can be referred to as [[$0]], $1, $2 ... $N.&lt;br /&gt;
&lt;br /&gt;
=== Parameters ===&lt;br /&gt;
 [[alias]] moo { echo -ag m $+ [[$str]](o,$$1) }&lt;br /&gt;
&lt;br /&gt;
Assuming you pass a number as parameter this would echo an &amp;lt;nowiki&amp;gt;&amp;quot;m&amp;quot;&amp;lt;/nowiki&amp;gt; folowed by a number of &amp;lt;nowiki&amp;gt;&amp;quot;o&#039;s&amp;quot;&amp;lt;/nowiki&amp;gt;, depending on the number you specified as parameter. This alias can be called in 2 different ways:&lt;br /&gt;
 /moo 12&lt;br /&gt;
 $moo(27)&lt;br /&gt;
Note that $moo doesn&#039;t return anything in this case, it will simply echo the message.&lt;br /&gt;
&lt;br /&gt;
=== Events ===&lt;br /&gt;
When calling an alias from an event, the identifiers related to that event will still be available in that alias.&lt;br /&gt;
 on *:[[On_text|TEXT]]:hi:#: { myAlias }&lt;br /&gt;
 &lt;br /&gt;
 [[alias]] myAlias { [[msg]] [[$chan]] [[$nick]] said hi! }&lt;br /&gt;
&lt;br /&gt;
This would be exactly the same as:&lt;br /&gt;
 on *:TEXT:hi:#: { msg $chan $nick said hi! }&lt;br /&gt;
This in turn means that you don&#039;t have to pass a identifier supplied by an event into your alias as parameter.&lt;br /&gt;
&lt;br /&gt;
== Commands vs identifiers ==&lt;br /&gt;
Being that you can use your aliases as both commands and identifiers, the question may rise which you should pick. The general answer is quite simple: if you want your alias to have a return value use identifiers and in any other case use commands.&lt;br /&gt;
&lt;br /&gt;
=== Error handling ===&lt;br /&gt;
However, mIRC&#039;s built-in error handling cannot be used for your aliases, so for proper error handling you might want to use return values. For example, you could use return value 1 when an action was succesfull and 0 when it was not.&lt;br /&gt;
 ; this identifier returns 1 if it was succesfull in what it would do and 0 if it wasn&#039;t&lt;br /&gt;
 ; the (useless) idea of the following identifier is to message &amp;quot;moo&amp;quot; to the currently active channel&lt;br /&gt;
 ; if it is on QuakeNet&lt;br /&gt;
 alias moo {&lt;br /&gt;
   if ([[$network]] != QuakeNet) || (!$chan) { return 0 }&lt;br /&gt;
   else {&lt;br /&gt;
     msg $chan moo&lt;br /&gt;
     return 1&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
To use this as error handling you could do the following:&lt;br /&gt;
 %error = $moo&lt;br /&gt;
 if (!%error) {&lt;br /&gt;
    ; do what you want to do if the command failed&lt;br /&gt;
    ; in this case when there was no channel active&lt;br /&gt;
    ; or the server was not QuakeNet&lt;br /&gt;
 }&lt;br /&gt;
 [[elseif]] (%error = 1) {&lt;br /&gt;
    ; do what you want to do if the command succeeded&lt;br /&gt;
    ; in this case when there was an active channel and&lt;br /&gt;
    ; the server was QuakeNet&lt;br /&gt;
 }&lt;br /&gt;
 else {&lt;br /&gt;
    ; the script should never reach this place!&lt;br /&gt;
 }&lt;br /&gt;
Although the same identifier could have been run as a command as well, error handling would not have been possible that way. Of course the alias itself has some error handling already, but there are cases in which you want an action to be able to fail.&lt;br /&gt;
&lt;br /&gt;
Another reason to prefer identifiers over comands are parameters. When you call an alias as a command every space will result in a new parameter and there is no way you can get around that. Using an alias as an identifier it is possible to get around the comma and thus have your parameters contain a comma. Here&#039;s how to do that:&lt;br /&gt;
 ; calling an identifier with a comma in a parameter&lt;br /&gt;
 [[alias]] test {&lt;br /&gt;
   ; the while loop will echo every parameter&lt;br /&gt;
   [[var]] %i = $0&lt;br /&gt;
   [[while]] (%i) {&lt;br /&gt;
     [[echo]] -ag $ [ $+ [ %i ] ]&lt;br /&gt;
     [[dec]] %i&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
 var %param = abcdef,ghijk&lt;br /&gt;
 %someVar = $test(%param)&lt;br /&gt;
The snippets above would result in having the identifier $test echo only 1 parameter: the data which was set in %param. Would you do the same for a command -- replacing the comma with a space -- it would result in /test getting 2 parameters. Handling parameters is much easier if you are a 100% sure which parameter will contain which data, and an identifier is more reliable in doing so.&lt;br /&gt;
&lt;br /&gt;
=== Forced identifiers ===&lt;br /&gt;
To force an alias to be an identifier -- it can&#039;t be used as a command --  or vice versa you can use the identifier [[$isid]].&lt;br /&gt;
 ; this alias can only be called as an identifier&lt;br /&gt;
 [[alias]] qnet {&lt;br /&gt;
   if ([[$isid]]) {&lt;br /&gt;
     ; the following code only gets executed if the alias was called as an identifier&lt;br /&gt;
     [[if]] ([[$network]] === QuakeNet) { [[return]] 1 }&lt;br /&gt;
     [[else]] { [[return]] 0 }&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
Calling the alias will result in a return value of either 0 or 1, while calling it as a command will do completely nothing.&lt;br /&gt;
&lt;br /&gt;
== Also See ==&lt;br /&gt;
* [[$isid]]&lt;br /&gt;
[[Category:mIRC_Help]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Category:Aliases&amp;diff=1389</id>
		<title>Category:Aliases</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Category:Aliases&amp;diff=1389"/>
		<updated>2006-04-25T13:01:08Z</updated>

		<summary type="html">&lt;p&gt;Doomie: perhaps like this?&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Basic ==&lt;br /&gt;
mIRC script allows you to create your own set of commands and identifiers, refered to as aliases. Aliases can be called from the command line, from other aliases, from popup and from remote scripts. An alias in mIRC can not be called recursively. They can be created by either putting them in the &amp;lt;nowiki&amp;gt;&amp;quot;Aliases&amp;quot;&amp;lt;/nowiki&amp;gt; section of the mIRC Scripts Editor, by using the /alias command from either the command line or in the &amp;lt;nowiki&amp;gt;&amp;quot;Remote&amp;quot;&amp;lt;/nowiki&amp;gt; section of the Scripts Editor. Creating an alias in the command line results in it being placed in the &amp;quot;Aliases&amp;quot; section of the Script Editor.&lt;br /&gt;
&lt;br /&gt;
=== Example ===&lt;br /&gt;
 ; These two work exactly the same way although they are stored in different places&lt;br /&gt;
 &lt;br /&gt;
 ; this is placed in the &amp;quot;Aliases&amp;quot; section&lt;br /&gt;
 moo { [[echo]] -ag moo }&lt;br /&gt;
 &lt;br /&gt;
 ; this is placed in the &amp;quot;Remote&amp;quot; section&lt;br /&gt;
 [[alias]] moo { [[echo]] -ag moo }&lt;br /&gt;
&lt;br /&gt;
== Naming aliases ==&lt;br /&gt;
You can give an alias virtually any name you want, but keep a few things in mind:&lt;br /&gt;
&lt;br /&gt;
* When you give an alias used as a command the same name as an existing mIRC command, your alias gets preference.&lt;br /&gt;
* Some inbuilt commands act differently than the rest, if you have an alias called [[timertest|Timer]], you will not be able to start a timer called test, like this: /timertest 0 1 MyTestFunction in this situation you can prefix the command with an exclamation mark (!) as shown below in the example.&lt;br /&gt;
* When you give an alias used as an identifier the same name as an existing mIRC identifier, mIRC&#039;s identifier gets preference, unless you prefix your alias with a period.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&lt;br /&gt;
 ; at first we add a new alias called &amp;quot;me&amp;quot;. If it is used as &amp;quot;$me&amp;quot;, it&#039;s supposed to return &amp;quot;AveIT!&amp;quot;, else it&#039;s the usual&lt;br /&gt;
 ; /me alias sending an action to the active channel&lt;br /&gt;
 /alias me { [[If-Then-Else|if]] ([[$isid]]) { [[return]] AveIT! } | else { [[describe]] [[$active]] [[$1-]] } }&lt;br /&gt;
  &lt;br /&gt;
 ; this alias will return the amount of milliseconds (ticks) pasted between two callings. &lt;br /&gt;
 ; When called the first time, it will set a variable %timerstart to the current value of $ticks.&lt;br /&gt;
 ; When called the second time, it echo&#039;s the difference between the set variable and the current value of ticks.&lt;br /&gt;
 ; This difference is obviously the elapsed time.&lt;br /&gt;
 /alias timertest { if (!%timerstart) [[set]] %timerstart [[$ticks]] | else { echo -ag [[$calc]]($ticks - %timerstart) ms | unset  %timerstart } }&lt;br /&gt;
 &lt;br /&gt;
In the following example, both the custom &#039;me&#039; and the &#039;timertest&#039; alias will be used:&lt;br /&gt;
&lt;br /&gt;
 ; call timertest the first time to set the variable %timertest&lt;br /&gt;
 timertest&lt;br /&gt;
  &lt;br /&gt;
 ; echo $me (that&#039;s the default $me alias as it can&#039;t be overwritten in the usual way&lt;br /&gt;
 ; and $.me (that&#039;s our custom alias returning &#039;AveIT!&#039;&lt;br /&gt;
 echo -ag I am $me but my custom identifer returns $.me&lt;br /&gt;
  &lt;br /&gt;
 ; call timertest a second time to echo the amount of elapsed milliseconds&lt;br /&gt;
 timertest&lt;br /&gt;
&lt;br /&gt;
Finally, the example above would return:&lt;br /&gt;
&lt;br /&gt;
 I am Dana but my custom identifer returns AveIT!&lt;br /&gt;
 16 ms&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;&#039;&#039;Note:&#039;&#039;&#039;&#039;&#039; If you want to start a timer called test with the alias called timertest, you have to prefix the timer with the ! to use the inbuilt mIRC timer command:&lt;br /&gt;
!timertest 1 1 echo -ag This is my test.&lt;br /&gt;
It is not encouraged to call an alias starting with timer, or identifers with mircdir, getdir, mididir, or any other alias which can be used with a suffix.&lt;br /&gt;
&lt;br /&gt;
== Aliases: parameters and events ==&lt;br /&gt;
mIRC script allows you to pass parameters to your aliases, just like you pass parameters into built-in mIRC commands or identifiers. They can be referred to as [[$0]], $1, $2 ... $N.&lt;br /&gt;
&lt;br /&gt;
=== Parameters ===&lt;br /&gt;
 [[alias]] moo { echo -ag m $+ [[$str]](o,$$1) }&lt;br /&gt;
&lt;br /&gt;
Assuming you pass a number as parameter this would echo an &amp;lt;nowiki&amp;gt;&amp;quot;m&amp;quot;&amp;lt;/nowiki&amp;gt; folowed by a number of &amp;lt;nowiki&amp;gt;&amp;quot;o&#039;s&amp;quot;&amp;lt;/nowiki&amp;gt;, depending on the number you specified as parameter. This alias can be called in 2 different ways:&lt;br /&gt;
 /moo 12&lt;br /&gt;
 $moo(27)&lt;br /&gt;
Note that $moo doesn&#039;t return anything in this case, it will simply echo the message.&lt;br /&gt;
&lt;br /&gt;
=== Events ===&lt;br /&gt;
When calling an alias from an event, the identifiers related to that event will still be available in that alias.&lt;br /&gt;
 on *:[[On_text|TEXT]]:hi:#: { myAlias }&lt;br /&gt;
 &lt;br /&gt;
 [[alias]] myAlias { [[msg]] [[$chan]] [[$nick]] said hi! }&lt;br /&gt;
&lt;br /&gt;
This would be exactly the same as:&lt;br /&gt;
 on *:TEXT:hi:#: { msg $chan $nick said hi! }&lt;br /&gt;
This in turn means that you don&#039;t have to pass a identifier supplied by an event into your alias as parameter.&lt;br /&gt;
&lt;br /&gt;
== Commands vs identifiers ==&lt;br /&gt;
Being that you can use your aliases as both commands and identifiers, the question may rise which you should pick. The general answer is quite simple: if you want your alias to have a return value use identifiers and in any other case use commands.&lt;br /&gt;
&lt;br /&gt;
=== Error handling ===&lt;br /&gt;
However, mIRC&#039;s built-in error handling cannot be used for your aliases, so for proper error handling you might want to use return values. For example, you could use return value 1 when an action was succesfull and 0 when it was not.&lt;br /&gt;
 ; this identifier returns 1 if it was succesfull in what it would do and 0 if it wasn&#039;t&lt;br /&gt;
 ; the (useless) idea of the following identifier is to message &amp;quot;moo&amp;quot; to the currently active channel&lt;br /&gt;
 ; if it is on QuakeNet&lt;br /&gt;
 alias moo {&lt;br /&gt;
   if ([[$network]] != QuakeNet) || (!$chan) { return 0 }&lt;br /&gt;
   else {&lt;br /&gt;
     msg $chan moo&lt;br /&gt;
     return 1&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
To use this as error handling you could do the following:&lt;br /&gt;
 %error = $moo&lt;br /&gt;
 if (!%error) {&lt;br /&gt;
    ; do what you want to do if the command failed&lt;br /&gt;
    ; in this case when there was no channel active&lt;br /&gt;
    ; or the server was not QuakeNet&lt;br /&gt;
 }&lt;br /&gt;
 [[elseif]] (%error = 1) {&lt;br /&gt;
    ; do what you want to do if the command succeeded&lt;br /&gt;
    ; in this case when there was an active channel and&lt;br /&gt;
    ; the server was QuakeNet&lt;br /&gt;
 }&lt;br /&gt;
 else {&lt;br /&gt;
    ; the script should never reach this place!&lt;br /&gt;
 }&lt;br /&gt;
Although the same identifier could have been run as a command as well, error handling would not have been possible that way. Of course the alias itself has some error handling already, but there are cases in which you want an action to be able to fail.&lt;br /&gt;
&lt;br /&gt;
Another reason to prefer identifiers over comands are parameters. When you call an alias as a command every space will result in a new parameter and there is no way you can get around that. Using an alias as an identifier it is possible to get around the comma and thus have your parameters contain a comma. Here&#039;s how to do that:&lt;br /&gt;
 ; calling an identifier with a comma in a parameter&lt;br /&gt;
 [[alias]] test {&lt;br /&gt;
   ; the while loop will echo every parameter&lt;br /&gt;
   [[var]] %i = $0&lt;br /&gt;
   [[while]] (%i) {&lt;br /&gt;
     [[echo]] -ag $ [ $+ [ %i ] ]&lt;br /&gt;
     [[dec]] %i&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
 var %param = abcdef,ghijk&lt;br /&gt;
 %someVar = $test(%param)&lt;br /&gt;
The snippets above would result in having the identifier $test echo only 1 parameter: the data which was set in %param. Would you do the same for a command -- replacing the comma with a space -- it would result in /test getting 2 parameters. Handling parameters is much easier if you are a 100% sure which parameter will contain which data, and an identifier is more reliable in doing so.&lt;br /&gt;
&lt;br /&gt;
=== Forced identifiers ===&lt;br /&gt;
To force an alias to be an identifier -- it can&#039;t be used as a command --  or vice versa you can use the identifier [[$isid]].&lt;br /&gt;
 ; this alias can only be called as an identifier&lt;br /&gt;
 [[alias]] qnet {&lt;br /&gt;
   if ([[$isid]]) {&lt;br /&gt;
     ; the following code only gets executed if the alias was called as an identifier&lt;br /&gt;
     [[if]] ([[$network]] === QuakeNet) { [[return]] 1 }&lt;br /&gt;
     [[else]] { [[return]] 0 }&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
Calling the alias will result in a return value of either 0 or 1, while calling it as a command will do completely nothing.&lt;br /&gt;
&lt;br /&gt;
== Also See ==&lt;br /&gt;
* [[$isid]]&lt;br /&gt;
[[Category:mIRC_Help]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Unsetall&amp;diff=2118</id>
		<title>Unsetall</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Unsetall&amp;diff=2118"/>
		<updated>2006-04-25T12:06:57Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Unsets and removes all variables from the variable list.&lt;br /&gt;
 /unsetall&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
[[Set|/set]] sets a variable.&amp;lt;br /&amp;gt;&lt;br /&gt;
[[Var|/var]] sets a local variable.&amp;lt;br /&amp;gt;&lt;br /&gt;
[[Unset|/unset]] unsets a variable.&lt;br /&gt;
&lt;br /&gt;
[[Category:Commands]]&lt;br /&gt;
[[Category:Variables]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Unset&amp;diff=2117</id>
		<title>Unset</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Unset&amp;diff=2117"/>
		<updated>2006-04-25T12:05:58Z</updated>

		<summary type="html">&lt;p&gt;Doomie: added it to category:variables&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Unsets and removes a variable from the variable list.&lt;br /&gt;
 /unset [-s] &amp;lt;%var&amp;gt;&lt;br /&gt;
The -s switch gives an output: * Unset %var&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039; that you can specify a variable with [[Wildcard|wildcard]] characters.&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
 /unset %moo&lt;br /&gt;
This will unset and remove the variable %moo.&lt;br /&gt;
 /unset %test*&lt;br /&gt;
This will unset and remove all variables that begin with %test.&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
[[Set|/set]] sets a variable.&amp;lt;br /&amp;gt;&lt;br /&gt;
[[Var|/var]] sets a local variable.&amp;lt;br /&amp;gt;&lt;br /&gt;
[[Unsetall|/unsetall]] unsets all variables.&lt;br /&gt;
&lt;br /&gt;
[[Category:Commands]]&lt;br /&gt;
[[Category:Variables]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=How_to_start&amp;diff=1528</id>
		<title>How to start</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=How_to_start&amp;diff=1528"/>
		<updated>2006-04-20T18:07:07Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This tutorial is supposed to give an introduction into scripting in mIRC. It will explain the so-called &#039;&#039;Scripts-Editor&#039;&#039; and it&#039;s functions, followed by a little example. At the end it will give some hints about how to debug a script.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== The Remote Editor ==&lt;br /&gt;
&lt;br /&gt;
If you want to begin to script in mIRC, you need to open the Script-Editor. You can do it in two ways: pressing &amp;quot;Alt + R&amp;quot; or with mIRC&#039;s menubar (Tools -&amp;gt; Scripts Editor).&lt;br /&gt;
&lt;br /&gt;
If you are using a premade script (for example nnscript), you will probably see a lot of code. Note that it is difficult to implement own scripts in such a premade one, as functions could interfere (if you want to change mIRC&#039;s default output for example). &lt;br /&gt;
&lt;br /&gt;
At first, you should open a &#039;&#039;&#039;new remote file&#039;&#039;&#039;. To do it, click on File -&amp;gt; New (see picture below).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Newfile.png]]&lt;br /&gt;
&lt;br /&gt;
Note that your script files will be saved &#039;&#039;&#039;automatically&#039;&#039;&#039;; all you need to do is pressing &#039;Ok&#039;.&lt;br /&gt;
&lt;br /&gt;
The next part is about the five different tabs of mIRC&#039;s Scripts Editor:&lt;br /&gt;
&lt;br /&gt;
[[Image:Scriptseditortabs.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Aliases-Tab === &lt;br /&gt;
&lt;br /&gt;
Basically, you do not need to use aliases.ini (that you can edit using this tab). Usually, if you want to add a new alias, it would look like:&lt;br /&gt;
&lt;br /&gt;
 [[alias]] moo { [[return]] moo }&lt;br /&gt;
&lt;br /&gt;
in your &#039;Remote-Section&#039; of the editor (the one that&#039;s active after pressing Alt + R). You can add the same alias in your Aliases-Section:&lt;br /&gt;
&lt;br /&gt;
 moo { return moo }&lt;br /&gt;
&lt;br /&gt;
Notice that you don&#039;t need to write &#039;alias&#039; infront of the new alias. Note that you cannot add events in this section.&lt;br /&gt;
&lt;br /&gt;
=== Popups-Tab ===&lt;br /&gt;
&lt;br /&gt;
Again you do not need to use this section. It&#039;s the same as using the [[menu]] alias in the remote section. Usually, there will be some menus added in this section (for example your nicklist-menu).&lt;br /&gt;
&lt;br /&gt;
[[Image:popupsview.png]]&lt;br /&gt;
&lt;br /&gt;
=== Remote-Tab ===&lt;br /&gt;
&lt;br /&gt;
This is the &amp;quot;maintab&amp;quot;. Every script is supposed to be saved in here.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039; that you should not have two same events in one file, as only the first matching one will be triggered. Example:&lt;br /&gt;
&lt;br /&gt;
 ; will be triggered&lt;br /&gt;
 on *:Text:*:*: { echo moo }&lt;br /&gt;
 &lt;br /&gt;
 ; will never be triggered&lt;br /&gt;
 on 10:Text:*:*: { echo maa }&lt;br /&gt;
&lt;br /&gt;
 ; will be trigger for level 10&lt;br /&gt;
 on 10:Text:*:*: { echo maa }&lt;br /&gt;
 &lt;br /&gt;
 ; will be triggered for all but level 10&lt;br /&gt;
 on *:Text:*:*: { echo moo }&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
So if you aren&#039;t sure whether it will work or not, just use another (a new) file (look above to see how to make a new file). &lt;br /&gt;
&lt;br /&gt;
The following script will trigger on every &amp;quot;!moo&amp;quot; in every channel and response with &amp;quot;moo00oo00&amp;quot;:&lt;br /&gt;
 &lt;br /&gt;
 [[On_text|on *:TEXT]]:!moo:#: {&lt;br /&gt;
  [[msg]] [[$chan]] moo00oo00&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
This would look like:&lt;br /&gt;
&lt;br /&gt;
[[Image:firstscript.png]]&lt;br /&gt;
&lt;br /&gt;
If you are scripting something more complex, you want to use the &amp;quot;{}&amp;quot;-button in the upper right corner (see below).&lt;br /&gt;
&lt;br /&gt;
[[Image:bracket-button.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If you&#039;ve pressed it and nothing happended, everything is ok (note that it doesn&#039;t mean that your scripts will work, just that there is no obvious bracket mistake (mIRC just counts the open and closed brackets)). If something&#039;s wrong, you will get the following popup:&lt;br /&gt;
&lt;br /&gt;
[[Image:bracketerror.png]]&lt;br /&gt;
&lt;br /&gt;
=== Users-Tab ===&lt;br /&gt;
&lt;br /&gt;
In this file your userlist is saved. You don&#039;t need to edit it manually, as there are aliases to do so. See [[auser]], [[guser]] and [[ruser]].&lt;br /&gt;
&lt;br /&gt;
=== Variables-Tab ===&lt;br /&gt;
&lt;br /&gt;
All your global variables are saved in here. Again, you don&#039;t need to edit it manually, as you can use [[set]], [[unset]] or [[unsetall]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== How to debug ==&lt;br /&gt;
&lt;br /&gt;
After you&#039;ve written some lines and you&#039;ve tested it, you will most likely notice, that it doesn&#039;t do what you expect it to do. The next step is to &#039;&#039;&#039;debug&#039;&#039;&#039; your script. At first take a look at your Status Window and check for error messages. If there are any, search for these errors in your script and correct them. If they aren&#039;t any, you should add [[echo]]&#039;s in your script to see where it stops to work. For example:&lt;br /&gt;
&lt;br /&gt;
 on *:TEXT:*:*: {&lt;br /&gt;
  if (%moo) { echo -a we are here }&lt;br /&gt;
  elseif (%moo2) { echo -a we are here 2 } &lt;br /&gt;
  echo -a after the if clauses&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
With this method, you can exactly see where it stops to work and correct this part.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Tutorials]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=How_to_query_a_CS_Server&amp;diff=1376</id>
		<title>How to query a CS Server</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=How_to_query_a_CS_Server&amp;diff=1376"/>
		<updated>2006-04-14T14:03:37Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;If you want to e.g. get the umber and names of all player who are currently playing on a CS-server, you have to send a so-called &amp;quot;query&amp;quot; to this server (using UDP) and handle everything the server sends back to you. This isn&#039;t as easy as it sounds. At first, you would have to &#039;learn&#039;, or, at least, understand the protocol a CS-server uses (e.g. what do I have to send to the server to get a &#039;good&#039; reply and what&#039;s the structure of this reply). If you want to learn more about these protocols, take a look at http://dev.kquery.com/ or http://www.valve-erc.com/srcsdk/Code/Networking/serverqueries.html.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The following script &#039;&#039;&#039;echo&#039;&#039;&#039;s the output to your active window. You will have to modify it to be able to use it as &#039;bot&#039;. It&#039;s a more complex script and you don&#039;t need to understand it (completly) to be able to use it.&lt;br /&gt;
&lt;br /&gt;
 ; HL server query snippet by Saturn&lt;br /&gt;
 ;&lt;br /&gt;
 ; usage:&lt;br /&gt;
 ; /hlinfo &amp;lt;ip&amp;gt; &amp;lt;port&amp;gt;&lt;br /&gt;
 ; /hlplay &amp;lt;ip&amp;gt; &amp;lt;port&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 ; the alias that opens a new socket if you want to get general information about a running CS-server&lt;br /&gt;
 [[alias]] hlinfo {&lt;br /&gt;
  ; using a dynamic socket name so we can use multiple instances at once&lt;br /&gt;
  [[var]] %sock = $+(hlinfo-,$ticks)&lt;br /&gt;
  ; actually open the socket&lt;br /&gt;
  [[sockudp]] -k %sock [[$1]]-2 [[$str]]([[$chr]](255),4) [[DollarPlus|$+]] TSource Engine Query&lt;br /&gt;
  ; closing the socket after 60seconds if there is no response (else it will be closed by another event (see below))&lt;br /&gt;
  .[[timer]] $+ %sock 1 60 [[sockclose]] %sock&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; this event will get all data send back from the server&lt;br /&gt;
 on *:udpread:hlinfo-*:{&lt;br /&gt;
  ; save it in a binary variable&lt;br /&gt;
  [[sockread]] -f &amp;amp;reply&lt;br /&gt;
 &lt;br /&gt;
  ; set some local variables that we will use below&lt;br /&gt;
  var %offset, %name, %map, %game, %num, %max, %ip, %dir&lt;br /&gt;
  &lt;br /&gt;
  ; following the protocol, this &amp;quot;m&amp;quot; shows us that we did query a Half-Life 1 server&lt;br /&gt;
  if ($chr($bvar(&amp;amp;reply,5)) == m) {&lt;br /&gt;
    ; Half-Life 1 info reply&lt;br /&gt;
    &lt;br /&gt;
    %offset = 6&lt;br /&gt;
  &lt;br /&gt;
    ; saving the ip&lt;br /&gt;
    %ip = $bvar(&amp;amp;reply,%offset,128).text&lt;br /&gt;
    inc %offset $calc($len(%ip) + 1)&lt;br /&gt;
    &lt;br /&gt;
    ; the same&lt;br /&gt;
    %name = $bvar(&amp;amp;reply,%offset,128).text&lt;br /&gt;
    inc %offset $calc($len(%name) + 1)&lt;br /&gt;
 &lt;br /&gt;
    ; the current map&lt;br /&gt;
    %map = $bvar(&amp;amp;reply,%offset,128).text&lt;br /&gt;
    inc %offset $calc($len(%map) + 1)&lt;br /&gt;
 &lt;br /&gt;
    ; the game directory&lt;br /&gt;
    %dir = $bvar(&amp;amp;reply,%offset,128).text&lt;br /&gt;
    inc %offset $calc($len(%dir) + 1)&lt;br /&gt;
 &lt;br /&gt;
    ; the name of the game&lt;br /&gt;
    %game = $bvar(&amp;amp;reply,%offset,128).text&lt;br /&gt;
    inc %offset $calc($len(%game) + 1)&lt;br /&gt;
 &lt;br /&gt;
    ; current and maximum players&lt;br /&gt;
    %num = $bvar(&amp;amp;reply,%offset)&lt;br /&gt;
    %max = $bvar(&amp;amp;reply,$calc(%offset + 1))&lt;br /&gt;
  }&lt;br /&gt;
  ; else we get data for a CS:Source game&lt;br /&gt;
  else {&lt;br /&gt;
    ; Source info reply&lt;br /&gt;
    ; we do the same as above&lt;br /&gt;
    %offset = 7&lt;br /&gt;
 &lt;br /&gt;
    %name = $bvar(&amp;amp;reply,%offset,128).text&lt;br /&gt;
    inc %offset $calc($len(%name) + 1)&lt;br /&gt;
 &lt;br /&gt;
    %map = $bvar(&amp;amp;reply,%offset,128).text&lt;br /&gt;
    inc %offset $calc($len(%map) + 1)&lt;br /&gt;
 &lt;br /&gt;
    %dir = $bvar(&amp;amp;reply,%offset,128).text&lt;br /&gt;
    inc %offset $calc($len(%dir) + 1)&lt;br /&gt;
 &lt;br /&gt;
    %game = $bvar(&amp;amp;reply,%offset,128).text&lt;br /&gt;
    inc %offset $calc($len(%game) + 1)&lt;br /&gt;
 &lt;br /&gt;
    %num = $bvar(&amp;amp;reply,$calc(%offset + 2))&lt;br /&gt;
    %max = $bvar(&amp;amp;reply,$calc(%offset + 3))&lt;br /&gt;
  }&lt;br /&gt;
  &lt;br /&gt;
  ; now we echo all stored details to the active window&lt;br /&gt;
  echo -a Info for $sock($sockname).saddr $+ : $+ $sock($sockname).sport&lt;br /&gt;
  echo -a Name: %name&lt;br /&gt;
  echo -a Map: %map&lt;br /&gt;
  echo -a Game: %game&lt;br /&gt;
  echo -a Players: %num $+ / $+ %max&lt;br /&gt;
  &lt;br /&gt;
  ; and turn the timer to close the socket off&lt;br /&gt;
  .timer $+ $sockname off&lt;br /&gt;
  ; as we can close it manually now&lt;br /&gt;
  sockclose $sockname&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 ; this is the alias that will be called from hlplay to open the socket &lt;br /&gt;
 alias hlchal {&lt;br /&gt;
  ; $1 = ip, $2 = port, $3- = what to call when received&lt;br /&gt;
  ; use dynamic socket name as above&lt;br /&gt;
  var %sock = $+(hlchal-,$ticks)&lt;br /&gt;
  ; open the socket&lt;br /&gt;
  sockudp -k %sock $1-2 $str($chr(255),4) $+ W &lt;br /&gt;
  ; mark it with the ip and port (and the query we want to call when we&#039;ve received something from the server&lt;br /&gt;
  sockmark %sock $3- $1-2&lt;br /&gt;
  ; and make a new timer to close it after 60 seconds&lt;br /&gt;
  .timer $+ %sock 1 60 sockclose %sock&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; read everything that comes back from the hlchal-* query&lt;br /&gt;
 on *:UDPREAD:hlchal-*:{&lt;br /&gt;
  ; and save it in the binary variable called &amp;amp;reply&lt;br /&gt;
  sockread -f &amp;amp;reply&lt;br /&gt;
  ; actually call the alias saved in the sockmark (hlplay_query)&lt;br /&gt;
  $sock($sockname).mark $bvar(&amp;amp;reply,6,4)&lt;br /&gt;
  ; and turn the timer off because we can close it manually&lt;br /&gt;
  .timer $+ $sockname off&lt;br /&gt;
  sockclose $sockname&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; the alias we can call to make everything easier &lt;br /&gt;
 ; it will call other aliases to open sockets etc.&lt;br /&gt;
 alias hlplay {&lt;br /&gt;
  hlchal $1-2 hlplay_query&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; the alias that opens the _real_ socket to receive data (everything before was just to challenge the server (read the website mentioned above)&lt;br /&gt;
 alias hlplay_query {&lt;br /&gt;
  ; set a binary variable&lt;br /&gt;
  bset &amp;amp;query 1 255 255 255 255 85 $3-&lt;br /&gt;
  ; use dynamic socket names again&lt;br /&gt;
  var %sock = $+(hlplay-,$ticks)&lt;br /&gt;
  ; open the socket&lt;br /&gt;
  sockudp -k %sock $1-2 &amp;amp;query&lt;br /&gt;
  ; and turn the alias to close the socket after 60seconds on&lt;br /&gt;
  .timer $+ %sock 1 60 sockclose %sock&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; this event will receive all data from the server as response to out query&lt;br /&gt;
 on *:UDPREAD:hlplay-*:{&lt;br /&gt;
  ; we save it in &amp;amp;reply&lt;br /&gt;
  sockread -f &amp;amp;reply&lt;br /&gt;
 &lt;br /&gt;
  ; set some local variables we will use later&lt;br /&gt;
  var %i = 1, %num = $bvar(&amp;amp;reply,6), %offset = 7&lt;br /&gt;
  var %count = 0, %name, %kills&lt;br /&gt;
 &lt;br /&gt;
  ; and echo the number of players&lt;br /&gt;
  echo -a Players on $sock($sockname).saddr $+ : $+ $sock($sockname).sport&lt;br /&gt;
 &lt;br /&gt;
  ; now we can loop through all player and save some details about them&lt;br /&gt;
  while (%i &amp;lt;= %num) {&lt;br /&gt;
    inc %offset&lt;br /&gt;
   &lt;br /&gt;
    ; the name&lt;br /&gt;
    %name = $bvar(&amp;amp;reply,%offset,128).text&lt;br /&gt;
    inc %offset $calc($len(%name) + 1)&lt;br /&gt;
 &lt;br /&gt;
    ; the kills&lt;br /&gt;
    %kills = $bvar(&amp;amp;reply,%offset).long&lt;br /&gt;
    if ($isbit(%kills,32)) dec %kills $calc(2^32)&lt;br /&gt;
    inc %offset 8&lt;br /&gt;
 &lt;br /&gt;
    ; and if there was a player&lt;br /&gt;
    if (%name != $null) {&lt;br /&gt;
      ; increase the variable that shows us the number of the player&lt;br /&gt;
      inc %count&lt;br /&gt;
      ; and echo it to the active window with the kills saved above&lt;br /&gt;
      echo -a %count $+ . %name - %kills&lt;br /&gt;
    }&lt;br /&gt;
  &lt;br /&gt;
    ; increase %i so we go on with the next player&lt;br /&gt;
    inc %i&lt;br /&gt;
  }&lt;br /&gt;
  &lt;br /&gt;
  ; if there are no players online, echo is aswell&lt;br /&gt;
  if (%count == 0) echo -a No players found!&lt;br /&gt;
 &lt;br /&gt;
  ; turn off the timer&lt;br /&gt;
  .timer $+ $sockname off&lt;br /&gt;
  ; and close the socket manually&lt;br /&gt;
  sockclose $sockname&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=How_to_query_a_CS_Server&amp;diff=1356</id>
		<title>How to query a CS Server</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=How_to_query_a_CS_Server&amp;diff=1356"/>
		<updated>2006-04-14T12:27:34Z</updated>

		<summary type="html">&lt;p&gt;Doomie: doesnt work + weird text - needs rewriting perhaps&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{stub}}&lt;br /&gt;
&lt;br /&gt;
If you want to e.g. get the umber and names of all player who are currently playing on a CS-server, you have to send a so-called &amp;quot;query&amp;quot; to this server (using UDP) and handle everything the server sends back to you. This isn&#039;t as easy as it sounds. At first, you would have to &#039;learn&#039;, or, at least, understand the protocol a CS-server uses (e.g. what do I have to send to the server to get a &#039;good&#039; reply and what&#039;s the structure of this reply). If you want to learn more about these protocols, take a look at http://dev.kquery.com/.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
The following script &#039;&#039;&#039;echo&#039;&#039;&#039;s the output to your active window. You will have to modify it to be able to use it as &#039;bot&#039;. It&#039;s a more complex script and you don&#039;t need to understand it (completly) to be able to use it.&lt;br /&gt;
&lt;br /&gt;
 ; this is a handy alias to call the script. It will call the &amp;quot;hlx&amp;quot; alias with an ip and a port as argument&lt;br /&gt;
 ; you can add more aliases like this one.&lt;br /&gt;
 ; if you want to all &amp;quot;hlq&amp;quot; directly, you can use something like: &amp;quot;/hlq &amp;lt;ip&amp;gt; &amp;lt;port&amp;gt;&amp;quot;&lt;br /&gt;
 [[alias]] hlx { hlq &amp;lt;ip&amp;gt; &amp;lt;port&amp;gt; }&lt;br /&gt;
 &lt;br /&gt;
 ; the main alias to open a new socket connections&lt;br /&gt;
 ; syntax: /hlq &amp;lt;ip&amp;gt; &amp;lt;port&amp;gt; &lt;br /&gt;
 alias hlq {&lt;br /&gt;
  [[sockudp]] -k hlq [[$1]]-2 [[DollarPlus|$+]]([[$str]]($chr(255),4),players)&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; this event will read every data from the cs server&lt;br /&gt;
 on *:udpread:hlq*:{&lt;br /&gt;
  ; we put it in a binary variable&lt;br /&gt;
  [[sockread]] -f &amp;amp;data&lt;br /&gt;
  &lt;br /&gt;
  ; the sixth byte is the number of players, so we set it to a variable &lt;br /&gt;
  [[var]] %players = $bvar(&amp;amp;data, 6, 1)&lt;br /&gt;
  var %offset = 7&lt;br /&gt;
  &lt;br /&gt;
  ; that&#039;s a variable for the while loop some lines below&lt;br /&gt;
  var %d = 1&lt;br /&gt;
  &lt;br /&gt;
  ; return a line seperator (usually &amp;quot;-&amp;quot;)&lt;br /&gt;
  [[linesep]]&lt;br /&gt;
  ; echo the number of players&lt;br /&gt;
  [[echo]] -a %players Players&lt;br /&gt;
   &lt;br /&gt;
  ; now we are looping through all players to get some stats about them&lt;br /&gt;
  [[while]] (%d &amp;lt;= %players) {&lt;br /&gt;
    ; the following lines are getting these stats. If you want to learn more about this, take a look&lt;br /&gt;
    ; at http://dev.kquery.com/&lt;br /&gt;
     &lt;br /&gt;
    ; we get the playernumber&lt;br /&gt;
    var %playernum = $bvar(&amp;amp;data, %offset, 1)&lt;br /&gt;
    [[inc]] %offset&lt;br /&gt;
    &lt;br /&gt;
    ; the name of the player&lt;br /&gt;
    var %name = $bvar(&amp;amp;data, %offset, 200).text&lt;br /&gt;
    inc %offset $calc($len(%name) + 1)&lt;br /&gt;
    &lt;br /&gt;
    ; the current score&lt;br /&gt;
    var %score = $bvar(&amp;amp;data, %offset, 4)&lt;br /&gt;
    inc %offset 4&lt;br /&gt;
    &lt;br /&gt;
    inc %offset 4&lt;br /&gt;
    &lt;br /&gt;
    ; and echo everything&lt;br /&gt;
    echo -a %playernum - name: %name - score: $be2le(%score)&lt;br /&gt;
  &lt;br /&gt;
    ; increase the variable for the while loop to get stats about the next player  &lt;br /&gt;
    inc %d&lt;br /&gt;
  }&lt;br /&gt;
  &lt;br /&gt;
  ; at the end, we are closing the socket to be able to open a new one later&lt;br /&gt;
  sockclose $sockname&lt;br /&gt;
 }&lt;br /&gt;
 ; this alias converts &#039;big endians&#039; into &#039;little endians&#039;&lt;br /&gt;
 alias be2le {&lt;br /&gt;
  tokenize 32 $1 | return $calc($1 + $2 * 2^8 + $4 * 2^16 + $3 * 2^24)&lt;br /&gt;
 }&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=How_to_start&amp;diff=1359</id>
		<title>How to start</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=How_to_start&amp;diff=1359"/>
		<updated>2006-04-11T17:43:16Z</updated>

		<summary type="html">&lt;p&gt;Doomie: /* Remote-Tab */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This tutorial is supposed to give an introduction into scripting in mIRC. It will explain the so-called &#039;&#039;Scripts-Editor&#039;&#039; and it&#039;s functions, followed by a little example. At the end it will give some hints about how to debug a script.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== The Remote Editor ==&lt;br /&gt;
&lt;br /&gt;
If you want to begin to script in mIRC, you need to open the Script-Editor. You can do it in two ways: pressing &amp;quot;Alt + R&amp;quot; or with mIRC&#039;s menubar (Tools -&amp;gt; Scripts Editor).&lt;br /&gt;
&lt;br /&gt;
If you are using a premade script (for example nnscript), you will probably see a lot of code. Note that it is difficult to implement own scripts in such a premade one, as functions could interfere (if you want to change mIRC&#039;s default output for example). &lt;br /&gt;
&lt;br /&gt;
At first, you should open a &#039;&#039;&#039;new remote file&#039;&#039;&#039;. To do it, click on File -&amp;gt; New (see picture below).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Newfile.png]]&lt;br /&gt;
&lt;br /&gt;
Note that your script files will be saved &#039;&#039;&#039;automatically&#039;&#039;&#039;; all you need to do is pressing &#039;Ok&#039;.&lt;br /&gt;
&lt;br /&gt;
The next part is about the five different tabs of mIRC&#039;s Scripts Editor:&lt;br /&gt;
&lt;br /&gt;
[[Image:Scriptseditortabs.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Aliases-Tab === &lt;br /&gt;
&lt;br /&gt;
Basically, you do not need to use aliases.ini (that you can edit using this tab). Usually, if you want to add a new alias, it would look like:&lt;br /&gt;
&lt;br /&gt;
 [[alias]] moo { [[return]] moo }&lt;br /&gt;
&lt;br /&gt;
in your &#039;Remote-Section&#039; of the editor (the one that&#039;s active after pressing Alt + R). You can add the same alias in your Aliases-Section:&lt;br /&gt;
&lt;br /&gt;
 moo { return moo }&lt;br /&gt;
&lt;br /&gt;
Notice that you don&#039;t need to write &#039;alias&#039; infront of the new alias. Note that you cannot add events in this section.&lt;br /&gt;
&lt;br /&gt;
=== Popups-Tab ===&lt;br /&gt;
&lt;br /&gt;
Again you do not need to use this section. It&#039;s the same as using the [[menu]] alias in the remote section. Usually, there will be some menus added in this section (for example your nicklist-menu).&lt;br /&gt;
&lt;br /&gt;
[[Image:popupsview.png]]&lt;br /&gt;
&lt;br /&gt;
=== Remote-Tab ===&lt;br /&gt;
&lt;br /&gt;
This is the &amp;quot;maintab&amp;quot;. Every script is supposed to be saved in here.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039; that you should not have two same events in one file, as only the first matching one will be triggered. Example:&lt;br /&gt;
&lt;br /&gt;
 ; will be triggered&lt;br /&gt;
 on *:Text:*:*: { echo moo }&lt;br /&gt;
 &lt;br /&gt;
 ; will never be triggered&lt;br /&gt;
 on 10:Text:*:*: { echo maa }&lt;br /&gt;
&lt;br /&gt;
 ; will be trigger for level 10&lt;br /&gt;
 on 10:Text:*:*: { echo maa }&lt;br /&gt;
 &lt;br /&gt;
 ; will be triggered for all but level 10&lt;br /&gt;
 on *:Text:*:*: { echo moo }&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
So if you aren&#039;t sure whether it will work or not, just use another (a new) file (look above to see how to make a new file). &lt;br /&gt;
&lt;br /&gt;
The following script will trigger on every &amp;quot;!moo&amp;quot; in every channel and response with &amp;quot;moo00oo00&amp;quot;:&lt;br /&gt;
 &lt;br /&gt;
 [[On_text|on *:TEXT]]:!moo:#: {&lt;br /&gt;
  [[msg]] [[$chan]] moo00oo00&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
This would look like:&lt;br /&gt;
&lt;br /&gt;
[[Image:firstscript.png]]&lt;br /&gt;
&lt;br /&gt;
If you are scripting something more complex, you want to use the &amp;quot;{}&amp;quot;-button in the upper right corner (see below).&lt;br /&gt;
&lt;br /&gt;
[[Image:bracket-button.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If you&#039;ve pressed it and nothing happended, everything is ok (note that it doesn&#039;t mean that your scripts will work, just that there is no obvious bracket mistake (mIRC just counts the open and closed brackets)). If something&#039;s wrong, you will get the following popup:&lt;br /&gt;
&lt;br /&gt;
[[Image:bracketerror.png]]&lt;br /&gt;
&lt;br /&gt;
=== Users-Tab ===&lt;br /&gt;
&lt;br /&gt;
In this file your userlist is saved. You don&#039;t need to edit it manually, as there are aliases to do so. See [[auser]], [[guser]] and [[ruser]].&lt;br /&gt;
&lt;br /&gt;
=== Variables-Tab ===&lt;br /&gt;
&lt;br /&gt;
All your global variables are saved in here. Again, you don&#039;t need to edit it manually, as you can use [[set]], [[unset]] or [[unsetall]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== How to debug ==&lt;br /&gt;
&lt;br /&gt;
After you&#039;ve written some lines and you&#039;ve tested it, you will most likely notice, that it doesn&#039;t do what you expect it to do. The next step is to &#039;&#039;&#039;debug&#039;&#039;&#039; your script. At first take a look at your Status Window and check for error messages. If there are any, search for these errors in your script and correct them. If they aren&#039;t any, you should add [[echo]]&#039;s in your script to see where it stops to work. For example:&lt;br /&gt;
&lt;br /&gt;
 on *:TEXT:*:*: {&lt;br /&gt;
  if (%moo) { echo -a we are here }&lt;br /&gt;
  elseif (%moo2) { echo -a we are here 2 } &lt;br /&gt;
  echo -a after the if clauses&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
With this method, you can exactly see where it stops to work and correct this part.&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=How_to_start&amp;diff=1339</id>
		<title>How to start</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=How_to_start&amp;diff=1339"/>
		<updated>2006-04-11T17:40:50Z</updated>

		<summary type="html">&lt;p&gt;Doomie: /* How to debug */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This tutorial is supposed to give an introduction into scripting in mIRC. It will explain the so-called &#039;&#039;Scripts-Editor&#039;&#039; and it&#039;s functions, followed by a little example. At the end it will give some hints about how to debug a script.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== The Remote Editor ==&lt;br /&gt;
&lt;br /&gt;
If you want to begin to script in mIRC, you need to open the Script-Editor. You can do it in two ways: pressing &amp;quot;Alt + R&amp;quot; or with mIRC&#039;s menubar (Tools -&amp;gt; Scripts Editor).&lt;br /&gt;
&lt;br /&gt;
If you are using a premade script (for example nnscript), you will probably see a lot of code. Note that it is difficult to implement own scripts in such a premade one, as functions could interfere (if you want to change mIRC&#039;s default output for example). &lt;br /&gt;
&lt;br /&gt;
At first, you should open a &#039;&#039;&#039;new remote file&#039;&#039;&#039;. To do it, click on File -&amp;gt; New (see picture below).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Newfile.png]]&lt;br /&gt;
&lt;br /&gt;
Note that your script files will be saved &#039;&#039;&#039;automatically&#039;&#039;&#039;; all you need to do is pressing &#039;Ok&#039;.&lt;br /&gt;
&lt;br /&gt;
The next part is about the five different tabs of mIRC&#039;s Scripts Editor:&lt;br /&gt;
&lt;br /&gt;
[[Image:Scriptseditortabs.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Aliases-Tab === &lt;br /&gt;
&lt;br /&gt;
Basically, you do not need to use aliases.ini (that you can edit using this tab). Usually, if you want to add a new alias, it would look like:&lt;br /&gt;
&lt;br /&gt;
 [[alias]] moo { [[return]] moo }&lt;br /&gt;
&lt;br /&gt;
in your &#039;Remote-Section&#039; of the editor (the one that&#039;s active after pressing Alt + R). You can add the same alias in your Aliases-Section:&lt;br /&gt;
&lt;br /&gt;
 moo { return moo }&lt;br /&gt;
&lt;br /&gt;
Notice that you don&#039;t need to write &#039;alias&#039; infront of the new alias. Note that you cannot add events in this section.&lt;br /&gt;
&lt;br /&gt;
=== Popups-Tab ===&lt;br /&gt;
&lt;br /&gt;
Again you do not need to use this section. It&#039;s the same as using the [[menu]] alias in the remote section. Usually, there will be some menus added in this section (for example your nicklist-menu).&lt;br /&gt;
&lt;br /&gt;
[[Image:popupsview.png]]&lt;br /&gt;
&lt;br /&gt;
=== Remote-Tab ===&lt;br /&gt;
&lt;br /&gt;
This is the &amp;quot;maintab&amp;quot;. Every script is supposed to be saved in here.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039; that you &#039;&#039;&#039;cannot&#039;&#039;&#039; have two same events in one file, as only the first matching one will be triggered. Example:&lt;br /&gt;
&lt;br /&gt;
 ; will be triggered&lt;br /&gt;
 on *:Text:*:*: { echo moo }&lt;br /&gt;
 &lt;br /&gt;
 ; will never be triggered&lt;br /&gt;
 on 10:Text:*:*: { echo maa }&lt;br /&gt;
&lt;br /&gt;
 ; will be trigger for level 10&lt;br /&gt;
 on 10:Text:*:*: { echo maa }&lt;br /&gt;
 &lt;br /&gt;
 ; will be triggered for all but level 10&lt;br /&gt;
 on *:Text:*:*: { echo moo }&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
So if you aren&#039;t sure whether it will work or not, just use another (a new) file (look above to see how to make a new file). &lt;br /&gt;
&lt;br /&gt;
The following script will trigger on every &amp;quot;!moo&amp;quot; in every channel and response with &amp;quot;moo00oo00&amp;quot;:&lt;br /&gt;
 &lt;br /&gt;
 [[On_text|on *:TEXT]]:!moo:#: {&lt;br /&gt;
  [[msg]] [[$chan]] moo00oo00&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
This would look like:&lt;br /&gt;
&lt;br /&gt;
[[Image:firstscript.png]]&lt;br /&gt;
&lt;br /&gt;
If you are scripting something more complex, you want to use the &amp;quot;{}&amp;quot;-button in the upper right corner (see below).&lt;br /&gt;
&lt;br /&gt;
[[Image:bracket-button.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If you&#039;ve pressed it and nothing happended, everything is ok (note that it doesn&#039;t mean that your scripts will work, just that there is no obvious bracket mistake (mIRC just counts the open and closed brackets)). If something&#039;s wrong, you will get the following popup:&lt;br /&gt;
&lt;br /&gt;
[[Image:bracketerror.png]]&lt;br /&gt;
&lt;br /&gt;
=== Users-Tab ===&lt;br /&gt;
&lt;br /&gt;
In this file your userlist is saved. You don&#039;t need to edit it manually, as there are aliases to do so. See [[auser]], [[guser]] and [[ruser]].&lt;br /&gt;
&lt;br /&gt;
=== Variables-Tab ===&lt;br /&gt;
&lt;br /&gt;
All your global variables are saved in here. Again, you don&#039;t need to edit it manually, as you can use [[set]], [[unset]] or [[unsetall]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== How to debug ==&lt;br /&gt;
&lt;br /&gt;
After you&#039;ve written some lines and you&#039;ve tested it, you will most likely notice, that it doesn&#039;t do what you expect it to do. The next step is to &#039;&#039;&#039;debug&#039;&#039;&#039; your script. At first take a look at your Status Window and check for error messages. If there are any, search for these errors in your script and correct them. If they aren&#039;t any, you should add [[echo]]&#039;s in your script to see where it stops to work. For example:&lt;br /&gt;
&lt;br /&gt;
 on *:TEXT:*:*: {&lt;br /&gt;
  if (%moo) { echo -a we are here }&lt;br /&gt;
  elseif (%moo2) { echo -a we are here 2 } &lt;br /&gt;
  echo -a after the if clauses&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
With this method, you can exactly see where it stops to work and correct this part.&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=How_to_start&amp;diff=1338</id>
		<title>How to start</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=How_to_start&amp;diff=1338"/>
		<updated>2006-04-11T17:40:34Z</updated>

		<summary type="html">&lt;p&gt;Doomie: /* Remote-Tab */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This tutorial is supposed to give an introduction into scripting in mIRC. It will explain the so-called &#039;&#039;Scripts-Editor&#039;&#039; and it&#039;s functions, followed by a little example. At the end it will give some hints about how to debug a script.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== The Remote Editor ==&lt;br /&gt;
&lt;br /&gt;
If you want to begin to script in mIRC, you need to open the Script-Editor. You can do it in two ways: pressing &amp;quot;Alt + R&amp;quot; or with mIRC&#039;s menubar (Tools -&amp;gt; Scripts Editor).&lt;br /&gt;
&lt;br /&gt;
If you are using a premade script (for example nnscript), you will probably see a lot of code. Note that it is difficult to implement own scripts in such a premade one, as functions could interfere (if you want to change mIRC&#039;s default output for example). &lt;br /&gt;
&lt;br /&gt;
At first, you should open a &#039;&#039;&#039;new remote file&#039;&#039;&#039;. To do it, click on File -&amp;gt; New (see picture below).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Newfile.png]]&lt;br /&gt;
&lt;br /&gt;
Note that your script files will be saved &#039;&#039;&#039;automatically&#039;&#039;&#039;; all you need to do is pressing &#039;Ok&#039;.&lt;br /&gt;
&lt;br /&gt;
The next part is about the five different tabs of mIRC&#039;s Scripts Editor:&lt;br /&gt;
&lt;br /&gt;
[[Image:Scriptseditortabs.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Aliases-Tab === &lt;br /&gt;
&lt;br /&gt;
Basically, you do not need to use aliases.ini (that you can edit using this tab). Usually, if you want to add a new alias, it would look like:&lt;br /&gt;
&lt;br /&gt;
 [[alias]] moo { [[return]] moo }&lt;br /&gt;
&lt;br /&gt;
in your &#039;Remote-Section&#039; of the editor (the one that&#039;s active after pressing Alt + R). You can add the same alias in your Aliases-Section:&lt;br /&gt;
&lt;br /&gt;
 moo { return moo }&lt;br /&gt;
&lt;br /&gt;
Notice that you don&#039;t need to write &#039;alias&#039; infront of the new alias. Note that you cannot add events in this section.&lt;br /&gt;
&lt;br /&gt;
=== Popups-Tab ===&lt;br /&gt;
&lt;br /&gt;
Again you do not need to use this section. It&#039;s the same as using the [[menu]] alias in the remote section. Usually, there will be some menus added in this section (for example your nicklist-menu).&lt;br /&gt;
&lt;br /&gt;
[[Image:popupsview.png]]&lt;br /&gt;
&lt;br /&gt;
=== Remote-Tab ===&lt;br /&gt;
&lt;br /&gt;
This is the &amp;quot;maintab&amp;quot;. Every script is supposed to be saved in here.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039; that you &#039;&#039;&#039;cannot&#039;&#039;&#039; have two same events in one file, as only the first matching one will be triggered. Example:&lt;br /&gt;
&lt;br /&gt;
 ; will be triggered&lt;br /&gt;
 on *:Text:*:*: { echo moo }&lt;br /&gt;
 &lt;br /&gt;
 ; will never be triggered&lt;br /&gt;
 on 10:Text:*:*: { echo maa }&lt;br /&gt;
&lt;br /&gt;
 ; will be trigger for level 10&lt;br /&gt;
 on 10:Text:*:*: { echo maa }&lt;br /&gt;
 &lt;br /&gt;
 ; will be triggered for all but level 10&lt;br /&gt;
 on *:Text:*:*: { echo moo }&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
So if you aren&#039;t sure whether it will work or not, just use another (a new) file (look above to see how to make a new file). &lt;br /&gt;
&lt;br /&gt;
The following script will trigger on every &amp;quot;!moo&amp;quot; in every channel and response with &amp;quot;moo00oo00&amp;quot;:&lt;br /&gt;
 &lt;br /&gt;
 [[On_text|on *:TEXT]]:!moo:#: {&lt;br /&gt;
  [[msg]] [[$chan]] moo00oo00&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
This would look like:&lt;br /&gt;
&lt;br /&gt;
[[Image:firstscript.png]]&lt;br /&gt;
&lt;br /&gt;
If you are scripting something more complex, you want to use the &amp;quot;{}&amp;quot;-button in the upper right corner (see below).&lt;br /&gt;
&lt;br /&gt;
[[Image:bracket-button.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If you&#039;ve pressed it and nothing happended, everything is ok (note that it doesn&#039;t mean that your scripts will work, just that there is no obvious bracket mistake (mIRC just counts the open and closed brackets)). If something&#039;s wrong, you will get the following popup:&lt;br /&gt;
&lt;br /&gt;
[[Image:bracketerror.png]]&lt;br /&gt;
&lt;br /&gt;
=== Users-Tab ===&lt;br /&gt;
&lt;br /&gt;
In this file your userlist is saved. You don&#039;t need to edit it manually, as there are aliases to do so. See [[auser]], [[guser]] and [[ruser]].&lt;br /&gt;
&lt;br /&gt;
=== Variables-Tab ===&lt;br /&gt;
&lt;br /&gt;
All your global variables are saved in here. Again, you don&#039;t need to edit it manually, as you can use [[set]], [[unset]] or [[unsetall]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== How to debug ==&lt;br /&gt;
&lt;br /&gt;
After you&#039;ve written some lines and you&#039;ve tested it, you will most likely notice, that it doesn&#039;t do what you expect it to do. The next step is to &#039;&#039;&#039;debug&#039;&#039;&#039; your script. At fist take a look at your Status Window and check for error messages. If there are any, search for these errors in your script and correct them. If they aren&#039;t any, you should add [[echo]]&#039;s in your script to see where it stops to work. For example:&lt;br /&gt;
&lt;br /&gt;
 on *:TEXT:*:*: {&lt;br /&gt;
  if (%moo) { echo -a we are here }&lt;br /&gt;
  elseif (%moo2) { echo -a we are here 2 } &lt;br /&gt;
  echo -a after the if clauses&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
With this method, you can exactly see where it stops to work and correct this part.&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=How_to_start&amp;diff=1337</id>
		<title>How to start</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=How_to_start&amp;diff=1337"/>
		<updated>2006-04-11T14:09:15Z</updated>

		<summary type="html">&lt;p&gt;Doomie: save #2&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This tutorial is supposed to give an introduction into scripting in mIRC. It will explain the so-called &#039;&#039;Scripts-Editor&#039;&#039; and it&#039;s functions, followed by a little example. At the end it will give some hints about how to debug a script.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== The Remote Editor ==&lt;br /&gt;
&lt;br /&gt;
If you want to begin to script in mIRC, you need to open the Script-Editor. You can do it in two ways: pressing &amp;quot;Alt + R&amp;quot; or with mIRC&#039;s menubar (Tools -&amp;gt; Scripts Editor).&lt;br /&gt;
&lt;br /&gt;
If you are using a premade script (for example nnscript), you will probably see a lot of code. Note that it is difficult to implement own scripts in such a premade one, as functions could interfere (if you want to change mIRC&#039;s default output for example). &lt;br /&gt;
&lt;br /&gt;
At first, you should open a &#039;&#039;&#039;new remote file&#039;&#039;&#039;. To do it, click on File -&amp;gt; New (see picture below).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Newfile.png]]&lt;br /&gt;
&lt;br /&gt;
Note that your script files will be saved &#039;&#039;&#039;automatically&#039;&#039;&#039;; all you need to do is pressing &#039;Ok&#039;.&lt;br /&gt;
&lt;br /&gt;
The next part is about the five different tabs of mIRC&#039;s Scripts Editor:&lt;br /&gt;
&lt;br /&gt;
[[Image:Scriptseditortabs.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Aliases-Tab === &lt;br /&gt;
&lt;br /&gt;
Basically, you do not need to use aliases.ini (that you can edit using this tab). Usually, if you want to add a new alias, it would look like:&lt;br /&gt;
&lt;br /&gt;
 [[alias]] moo { [[return]] moo }&lt;br /&gt;
&lt;br /&gt;
in your &#039;Remote-Section&#039; of the editor (the one that&#039;s active after pressing Alt + R). You can add the same alias in your Aliases-Section:&lt;br /&gt;
&lt;br /&gt;
 moo { return moo }&lt;br /&gt;
&lt;br /&gt;
Notice that you don&#039;t need to write &#039;alias&#039; infront of the new alias. Note that you cannot add events in this section.&lt;br /&gt;
&lt;br /&gt;
=== Popups-Tab ===&lt;br /&gt;
&lt;br /&gt;
Again you do not need to use this section. It&#039;s the same as using the [[menu]] alias in the remote section. Usually, there will be some menus added in this section (for example your nicklist-menu).&lt;br /&gt;
&lt;br /&gt;
[[Image:popupsview.png]]&lt;br /&gt;
&lt;br /&gt;
=== Remote-Tab ===&lt;br /&gt;
&lt;br /&gt;
This is the &amp;quot;maintab&amp;quot;. Every script is supposed to be saved in here.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039; that you &#039;&#039;&#039;cannot&#039;&#039;&#039; have two same events in one file. So if you aren&#039;t sure whether it will work or not, just use another (a new) file (look above to see how to make a new file). &lt;br /&gt;
&lt;br /&gt;
The following script will trigger on every &amp;quot;!moo&amp;quot; in every channel and response with &amp;quot;moo00oo00&amp;quot;:&lt;br /&gt;
 &lt;br /&gt;
 [[On_text|on *:TEXT]]:!moo:#: {&lt;br /&gt;
  [[msg]] [[$chan]] moo00oo00&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
This would look like:&lt;br /&gt;
&lt;br /&gt;
[[Image:firstscript.png]]&lt;br /&gt;
&lt;br /&gt;
If you are scripting something more complex, you want to use the &amp;quot;{}&amp;quot;-button in the upper right corner (see below)&lt;br /&gt;
&lt;br /&gt;
[[Image:bracket-button.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If you&#039;ve pressed it and nothing happended, everything is ok (note that it doesn&#039;t mean that your scripts will work, just that there is no obvious bracket mistake (mIRC just counts the open and closed brackets)). If something&#039;s wrong, you will get the following popup:&lt;br /&gt;
&lt;br /&gt;
[[Image:bracketerror.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Users-Tab ===&lt;br /&gt;
&lt;br /&gt;
In this file your userlist is saved. You don&#039;t need to edit it manually, as there are aliases to do so. See [[auser]], [[guser]] and [[ruser]].&lt;br /&gt;
&lt;br /&gt;
=== Variables-Tab ===&lt;br /&gt;
&lt;br /&gt;
All your global variables are saved in here. Again, you don&#039;t need to edit it manually, as you can use [[set]], [[unset]] or [[unsetall]].&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== How to debug ==&lt;br /&gt;
&lt;br /&gt;
After you&#039;ve written some lines and you&#039;ve tested it, you will most likely notice, that it doesn&#039;t do what you expect it to do. The next step is to &#039;&#039;&#039;debug&#039;&#039;&#039; your script. At fist take a look at your Status Window and check for error messages. If there are any, search for these errors in your script and correct them. If they aren&#039;t any, you should add [[echo]]&#039;s in your script to see where it stops to work. For example:&lt;br /&gt;
&lt;br /&gt;
 on *:TEXT:*:*: {&lt;br /&gt;
  if (%moo) { echo -a we are here }&lt;br /&gt;
  elseif (%moo2) { echo -a we are here 2 } &lt;br /&gt;
  echo -a after the if clauses&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
With this method, you can exactly see where it stops to work and correct this part.&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=File:Bracket-button.png&amp;diff=4487</id>
		<title>File:Bracket-button.png</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=File:Bracket-button.png&amp;diff=4487"/>
		<updated>2006-04-11T13:59:09Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=File:Firstscript.png&amp;diff=4486</id>
		<title>File:Firstscript.png</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=File:Firstscript.png&amp;diff=4486"/>
		<updated>2006-04-11T13:57:15Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=File:Bracketerror.png&amp;diff=4485</id>
		<title>File:Bracketerror.png</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=File:Bracketerror.png&amp;diff=4485"/>
		<updated>2006-04-11T13:56:48Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=How_to_start&amp;diff=1336</id>
		<title>How to start</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=How_to_start&amp;diff=1336"/>
		<updated>2006-04-11T13:21:17Z</updated>

		<summary type="html">&lt;p&gt;Doomie: just to save it&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This tutorial is supposed to give an introduction into scripting in mIRC. It will explain the so-called &#039;&#039;Scripts-Editor&#039;&#039; and it&#039;s functions, followed by a little example. At the end it will give some hints about how to debug a script.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== The Remote Editor ==&lt;br /&gt;
&lt;br /&gt;
If you want to begin to script in mIRC, you need to open the Script-Editor. You can do it in two ways: pressing &amp;quot;Alt + R&amp;quot; or with mIRC&#039;s menubar (Tools -&amp;gt; Scripts Editor).&lt;br /&gt;
&lt;br /&gt;
If you are using a premade script (for example nnscript), you will probably see a lot of code. Note that it is difficult to implement own scripts in such a premade one, as functions could interfere (if you want to change mIRC&#039;s default output for example). &lt;br /&gt;
&lt;br /&gt;
At first, you should open a &#039;&#039;&#039;new remote file&#039;&#039;&#039;. To do it, click on File -&amp;gt; New (see picture below).&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Image:Newfile.png]]&lt;br /&gt;
&lt;br /&gt;
Note that your script files will be saved &#039;&#039;&#039;automatically&#039;&#039;&#039;; all you need to do is pressing &#039;Ok&#039;.&lt;br /&gt;
&lt;br /&gt;
The next part is about the five different tabs of mIRC&#039;s Scripts Editor:&lt;br /&gt;
&lt;br /&gt;
[[Image:Scriptseditortabs.png]]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Aliases-Tab === &lt;br /&gt;
&lt;br /&gt;
Basically, you do not need to use aliases.ini (that you can edit using this tab). Usually, if you want to add a new alias, it would look like:&lt;br /&gt;
&lt;br /&gt;
 alias moo { return moo }&lt;br /&gt;
&lt;br /&gt;
in your &#039;Remote-Section&#039; of the editor (the one that&#039;s active after pressing Alt + R). You can add the same alias in your Aliases-Section:&lt;br /&gt;
&lt;br /&gt;
 moo { return moo }&lt;br /&gt;
&lt;br /&gt;
Notice that you don&#039;t need to write &#039;alias&#039; infront of the new alias. Note that you cannot add events in this section.&lt;br /&gt;
&lt;br /&gt;
=== Popups-Tab ===&lt;br /&gt;
&lt;br /&gt;
Again you do not need to use this section. It&#039;s the same as using [[menu]] in the remote section. Usually, there will be some menus added in this section (for example your nicklist-menu).&lt;br /&gt;
&lt;br /&gt;
[[Image:popupsview.png]]&lt;br /&gt;
&lt;br /&gt;
=== Remote-Tab ===&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=File:Popupsview.png&amp;diff=4483</id>
		<title>File:Popupsview.png</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=File:Popupsview.png&amp;diff=4483"/>
		<updated>2006-04-11T13:20:33Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=File:Scriptseditortabs.png&amp;diff=4482</id>
		<title>File:Scriptseditortabs.png</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=File:Scriptseditortabs.png&amp;diff=4482"/>
		<updated>2006-04-11T13:14:07Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=File:Newfile.png&amp;diff=4481</id>
		<title>File:Newfile.png</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=File:Newfile.png&amp;diff=4481"/>
		<updated>2006-04-11T13:08:55Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Category:Aliases&amp;diff=1331</id>
		<title>Category:Aliases</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Category:Aliases&amp;diff=1331"/>
		<updated>2006-04-10T19:55:46Z</updated>

		<summary type="html">&lt;p&gt;Doomie: so that it&amp;#039;s on one line for better reading ;)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Basic ==&lt;br /&gt;
mIRC script allows you to create your own set of commands and identifiers, refered to as aliases. Aliases can be called from the command line, from other aliases, from popup and from remote scripts. An alias in mIRC can not be called recursively. They can be created by either putting them in the &amp;lt;nowiki&amp;gt;&amp;quot;Aliases&amp;quot;&amp;lt;/nowiki&amp;gt; section of the mIRC Scripts Editor, by using the /alias command from either the command line or in the &amp;lt;nowiki&amp;gt;&amp;quot;Remote&amp;quot;&amp;lt;/nowiki&amp;gt; section of the Scripts Editor. Creating an alias in the command line results in it being placed in the &amp;quot;Aliases&amp;quot; section of the Script Editor.&lt;br /&gt;
&lt;br /&gt;
=== Example ===&lt;br /&gt;
 ; this is placed in the &amp;quot;Aliases&amp;quot; section&lt;br /&gt;
 moo { [[echo]] -ag moo }&lt;br /&gt;
 &lt;br /&gt;
 ; this is placed in the &amp;quot;Remote&amp;quot; section&lt;br /&gt;
 [[alias]] moo { [[echo]] -ag moo }&lt;br /&gt;
&lt;br /&gt;
== Naming aliases ==&lt;br /&gt;
You can give an alias virtualy any name you want, but keep a few things in mind:&lt;br /&gt;
&lt;br /&gt;
* When you give an alias used as a command the same name as an existing mIRC command, your alias gets preference.&lt;br /&gt;
* When you give an alias used as an identifier the same name as an existing mIRC identifier, mIRC&#039;s identifier gets preference.&lt;br /&gt;
&lt;br /&gt;
== Aliases: parameters and events ==&lt;br /&gt;
mIRC script allows you to pass parameters to your aliases, just like you pass parameters into built-in mIRC commands or identifiers. They can be referred to as $1, $2 ... $N.&lt;br /&gt;
&lt;br /&gt;
=== Parameters ===&lt;br /&gt;
 [[alias]] moo { echo -ag m $+ [[$str]](o,$$1)&lt;br /&gt;
&lt;br /&gt;
Assuming you pass a number as parameter this would echo an &amp;lt;nowiki&amp;gt;&amp;quot;m&amp;quot;&amp;lt;/nowiki&amp;gt; folowed by a number of &amp;lt;nowiki&amp;gt;&amp;quot;o&#039;s&amp;quot;&amp;lt;/nowiki&amp;gt;, depending on the number you specified as parameter. This alias can be called in 2 different ways:&lt;br /&gt;
 /moo 12&lt;br /&gt;
 $moo(27)&lt;br /&gt;
Note that $moo doesn&#039;t return anything in this case, it will simply echo the message.&lt;br /&gt;
&lt;br /&gt;
=== Events ===&lt;br /&gt;
When calling an alias from an event, the identifiers related to that event will still be available in that alias.&lt;br /&gt;
 on *:TEXT:hi:#: { myAlias }&lt;br /&gt;
 &lt;br /&gt;
 [[alias]] myAlias { [[msg]] [[$chan]] [[$nick]] said hi!&lt;br /&gt;
&lt;br /&gt;
This would be exactly the same as:&lt;br /&gt;
 on *:TEXT:hi:#: { [[msg]] [[$chan]] [[$nick]] said hi!&lt;br /&gt;
This in turn means that you don&#039;t have to pass a identifier supplied by an event into your alias as parameter.&lt;br /&gt;
&lt;br /&gt;
== Commands vs identifiers ==&lt;br /&gt;
Being that you can use your aliases as both commands as identifiers, the question may rise which you should pick. The general answer is quite simple: if you want your alias to have a return value use identifiers and in any other case use commands.&lt;br /&gt;
&lt;br /&gt;
=== Error handling ===&lt;br /&gt;
However, mIRC&#039;s built-in error handling cannot be used for your aliases, so for proper error handling you might want to use return values. For example, you could use return value 1 when an action was succesfull and 0 when it was not.&lt;br /&gt;
 ; this identifier returns 1 if it was succesfull in what it would do and 0 if it wasn&#039;t&lt;br /&gt;
 ; the (useless) idea of the following identifier is to message &amp;quot;moo&amp;quot; to the currently active channel&lt;br /&gt;
 ; if it is on QuakeNet&lt;br /&gt;
 [[alias]] moo {&lt;br /&gt;
   [[if]] ([[$network]] != QuakeNet) || (![[$chan]]) { [[return]] 0 }&lt;br /&gt;
   [[else]] {&lt;br /&gt;
     [[msg]] [[$chan]] moo&lt;br /&gt;
     [[return]] 1&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
To use this as error handling you could do the following:&lt;br /&gt;
 %error = $moo&lt;br /&gt;
 [[if]] (!%error) {&lt;br /&gt;
    ; do what you want to do if the command failed&lt;br /&gt;
    ; in this case when there was no channel active&lt;br /&gt;
    ; or the server was not QuakeNet&lt;br /&gt;
 }&lt;br /&gt;
 [[elseif]] (%error = 1) {&lt;br /&gt;
    ; do what you want to do if the command succeeded&lt;br /&gt;
    ; in this case when there was an active channel and&lt;br /&gt;
    ; the server was QuakeNet&lt;br /&gt;
 }&lt;br /&gt;
 [[else]] {&lt;br /&gt;
    ; the script should never reach this place!&lt;br /&gt;
 }&lt;br /&gt;
Although the same identifier could have been run as a command as well, error handling would not have been possible that way. Of course the alias itself has some error handling already, but there are cases in which you want an action to be able to fail.&lt;br /&gt;
&lt;br /&gt;
Another reason to prefer identifiers over comands are parameters. When you call an alias as a command every space will result in a new parameter and there is no way you can get around that. Using an alias as an identifier it is possible to get around the comma and thus have your parameters contain a comma. Here&#039;s how to do that:&lt;br /&gt;
 ; calling an identifier with a comma in a parameter&lt;br /&gt;
 [[alias]] test {&lt;br /&gt;
   ; the while loop will echo every parameter&lt;br /&gt;
   [[var]] %i = $0&lt;br /&gt;
   [[while]] (%i)&lt;br /&gt;
     [[echo]] -ag $ [ $+ [ %i ] ]&lt;br /&gt;
     [[dec]] %i&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
 var %param = abcdef,ghijk&lt;br /&gt;
 %someVar = $test(%param)&lt;br /&gt;
The snippets above would result in having the identifier $test echo only 1 parameter: the data which was set in %param. Would you do the same for a command -- replacing the comma with a space -- it would result in /test getting 2 parameters. Handling parameters is much easier if you are a 100% sure which parameter will contain which data, and an identifier is more reliable in doing so.&lt;br /&gt;
&lt;br /&gt;
=== Forced identifiers ===&lt;br /&gt;
To force an alias to be an identifier -- it can&#039;t be used as a command --  or vice versa you can use the identifier [[$isid]].&lt;br /&gt;
 ; this alias can only be called as an identifier&lt;br /&gt;
 [[alias]] qnet {&lt;br /&gt;
   if ([[$isid]]) {&lt;br /&gt;
     ; the following code only gets executed if the alias was called as an identifier&lt;br /&gt;
     [[if]] ([[$network]] === QuakeNet) { [[return]] 1 }&lt;br /&gt;
     [[else]] { [[return]] 0 }&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
Calling the alias will result in a return value of either 0 or 1, while calling it as a command will do completely nothing.&lt;br /&gt;
[[Category:mIRC_Help]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=$chr&amp;diff=2179</id>
		<title>$chr</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=$chr&amp;diff=2179"/>
		<updated>2006-04-02T15:55:00Z</updated>

		<summary type="html">&lt;p&gt;Doomie: added link to ascii table&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Returns the character with ascii number N.&lt;br /&gt;
 $chr(N)&lt;br /&gt;
&lt;br /&gt;
To get a list of all ascii chars and ascii numbers, take a look at http://www.lookuptables.com/.&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
 [[echo]] -a $chr(65) &lt;br /&gt;
This example would return the character with the ASCII-code 65. That is an &#039;A&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
[[$asc]] returns the ascii number of a character.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Text_and_Number_Identifiers]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=$asc&amp;diff=1655</id>
		<title>$asc</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=$asc&amp;diff=1655"/>
		<updated>2006-04-02T15:42:47Z</updated>

		<summary type="html">&lt;p&gt;Doomie: just a little explanation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Returns the ascii number of the character C.&lt;br /&gt;
 $asc(C)&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
 echo -a $asc(A) ; returns &#039;&#039;65&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To get the ascii value of a character, just type:&lt;br /&gt;
 //echo -a $asc([[$?]])&lt;br /&gt;
Type the character you want the ascii value of in the prompt and press enter. This is necessary as you can&#039;t use something like &#039;echo -a $asc(,)&#039;, as mIRC would think the comma is seperating parameters and so return &#039;* Too many parameters: $asc&#039;.&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
[[$chr]] returns the character of an ascii number.&lt;br /&gt;
&lt;br /&gt;
[[Category:Text_and_Number_Identifiers]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=$chr&amp;diff=1325</id>
		<title>$chr</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=$chr&amp;diff=1325"/>
		<updated>2006-04-02T15:41:28Z</updated>

		<summary type="html">&lt;p&gt;Doomie: wouldnt know what to say&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Returns the character with ascii number N.&lt;br /&gt;
 $chr(N)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
 [[echo]] -a $chr(65) &lt;br /&gt;
This example would return the character with the ASCII-code 65. That is an &#039;A&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
[[$asc]] returns the ascii number of a character.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Text_and_Number_Identifiers]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=How_to_press_a_key_using_an_alias&amp;diff=2598</id>
		<title>How to press a key using an alias</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=How_to_press_a_key_using_an_alias&amp;diff=2598"/>
		<updated>2006-04-02T15:38:28Z</updated>

		<summary type="html">&lt;p&gt;Doomie: perhaps like this&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;With this alias, you are able to &amp;quot;send keys&amp;quot; to the active window, which doesnt have to be mIRC.&lt;br /&gt;
For descriptions of all the keys, see: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/script56/html/wsmthsendkeys.asp&lt;br /&gt;
&lt;br /&gt;
You will have to paste this script into the &#039;Remote&#039; section of mIRC&#039;s script editor.&lt;br /&gt;
&lt;br /&gt;
 alias sendkey {&lt;br /&gt;
  [[set]] -l %name sendkeys $+ [[$ticks]]&lt;br /&gt;
  .[[comopen]] %name WScript.Shell&lt;br /&gt;
  .[[comclose]] %name [[$com]](%name,SendKeys,3,bstr,[[$1-]])&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
&lt;br /&gt;
 sendkey {TAB}&lt;br /&gt;
&lt;br /&gt;
This sends the &amp;quot;Tab&amp;quot;-Key to the active window (using the alias specified above). It is the same as if you&#039;d press the &amp;quot;Tab&amp;quot;-Key on your keyboard.&lt;br /&gt;
&lt;br /&gt;
 &lt;br /&gt;
 sendkey +(ab)c&lt;br /&gt;
This would send &amp;quot;ABc&amp;quot; to the active window, as +(ab) means &#039;shift&#039; and &#039;a&#039; and &#039;b&#039; and a lone &#039;c&#039; after that.&lt;br /&gt;
&lt;br /&gt;
[[Category:Script Archive]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Raw_484&amp;diff=3968</id>
		<title>Raw 484</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Raw_484&amp;diff=3968"/>
		<updated>2006-04-02T14:23:49Z</updated>

		<summary type="html">&lt;p&gt;Doomie: added a newline&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;table&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;Name:&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;ERR_ISCHANSERVICE&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;Format:&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
&amp;lt;source&amp;gt; 484 &amp;lt;target&amp;gt; &amp;lt;nick&amp;gt; &amp;lt;channel&amp;gt; :Cannot [[Kill|kill]], [[Kick|kick]] or [[Mode|deop]] an [[IRC]] operator&amp;lt;br /&amp;gt;&lt;br /&gt;
&amp;lt;source&amp;gt; 484 &amp;lt;target&amp;gt; KILL &amp;lt;nick&amp;gt; :Cannot kill, kick or deop an IRC operator&lt;br /&gt;
&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;Info:&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt; This is returned when trying to kill, kick or deop an IRC Operator with usermode [[Mode|+k]] set&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;Example:&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;&lt;br /&gt;
irc.quakenet.org 484 [[Dana]] Dana #help.script :Cannot kill, kick or deop an IRC operator&lt;br /&gt;
&lt;br /&gt;
irc.quakenet.org 484 Dana KILL Dana :Cannot kill, kick or deop an IRC operator&lt;br /&gt;
&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
&lt;br /&gt;
[[Category:Raws]][[Category:Raw_kick]][[Category:Raw_kill]][[Category:Raw_mode]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Category:Raws&amp;diff=3788</id>
		<title>Category:Raws</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Category:Raws&amp;diff=3788"/>
		<updated>2006-03-30T10:42:58Z</updated>

		<summary type="html">&lt;p&gt;Doomie: added $ support in the syntax (regex-based matchtext)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;== Raws ==&lt;br /&gt;
When the IRC server send you information it contains either a command or a RAW numeric. The numerics are a supplement to the normal events (NOTICE/PRIVMSG/MODE/etc.) not a replacement. Because raw events receive the information from the server in its native form, they give you maximum flexibility in regards to how you choose to use it or present it to the user of your script.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To read more about the IRC RFC, look here: RFC 1459&lt;br /&gt;
&lt;br /&gt;
== Syntax== &lt;br /&gt;
To actually react on numeric-raws, you have to use:&lt;br /&gt;
 raw [$]&amp;lt;numeric&amp;gt;:&amp;lt;matchtext&amp;gt;:{ commands }&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039; that raw-events are just like &amp;quot;normal&amp;quot; events, like [[On_text|On Text]] or [[On_notice|On Notice]]. That means that you &#039;&#039;&#039;can&#039;t&#039;&#039;&#039; use them in an alias or in another event. If you are using &#039;&#039;$&#039;&#039; infront of the numeric, you have to use a regex-based matchtext.&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
For example you get several numeric raws when you join a channel:&lt;br /&gt;
*[[Raw_332|332]] - containing the topic of the channel (like when using [[Topic|/topic]])&lt;br /&gt;
*[[Raw_333|333]] - containing the one who has set the topic and when it was set&lt;br /&gt;
*[[Raw_353|353]] - containing the names on the channel (like when using [[Names|/names]])&lt;br /&gt;
*[[Raw_366|366]] - containing the message that the list of names has ended&lt;br /&gt;
*[[Raw_324|324]] - containing the modes that are currently set (like when using [[Mode|/mode]])&lt;br /&gt;
*[[Raw_329|329]] - containing the creation date of the channel&lt;br /&gt;
&lt;br /&gt;
If you e.g. want to echo the creation date of the channel to your status window, you would have to use:&lt;br /&gt;
 ; raw 329 returns: &amp;lt;yournick&amp;gt; &amp;lt;#channel&amp;gt; &amp;lt;creation time in unix format&amp;gt;&lt;br /&gt;
 raw 329:*: {&lt;br /&gt;
  [[echo]] -a $2 was created at: [[$asctime]]($3)&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
If you want to halt mIRC&#039;s default output in connection with a raw-event, you can use [[Haltdef|/haltdef]]. For example:&lt;br /&gt;
 raw 332:*: {&lt;br /&gt;
  haltdef&lt;br /&gt;
 }&lt;br /&gt;
This example would make mIRC not show the topic of a channel you have joined.&lt;br /&gt;
&lt;br /&gt;
[[Category:IRC]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=$status&amp;diff=2451</id>
		<title>$status</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=$status&amp;diff=2451"/>
		<updated>2006-03-29T21:33:16Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Returns server connection status.&lt;br /&gt;
&lt;br /&gt;
 $status&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This identifier can return several values:&lt;br /&gt;
* connected - if your mIRC is connected (this includes the [[On_connect|On connect event]])&lt;br /&gt;
* disconnected - if your mIRC is not connected &lt;br /&gt;
* connecting - during connection process (between &#039;&#039;Connecting to ...&#039;&#039; and &#039;&#039;Looking up hostname&#039;&#039;)&lt;br /&gt;
* disconnecting - during disconnect (between [[quit|/quit]] and &#039;&#039;* Disconnected&#039;&#039;)&lt;br /&gt;
* closing - in an [[On_disconnect|On disconnect event]]&lt;br /&gt;
&lt;br /&gt;
[[Category:Other Identifiers]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=$modespl&amp;diff=4476</id>
		<title>$modespl</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=$modespl&amp;diff=4476"/>
		<updated>2006-03-29T16:03:35Z</updated>

		<summary type="html">&lt;p&gt;Doomie: i did decide against an example as it would prolly be massmode support.. welcome for other ideas ;)&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Returns the maximum number of modes allowed per [[mode|/mode]].&lt;br /&gt;
 $modespl&lt;br /&gt;
&lt;br /&gt;
On QuakeNet, this identifier would return &amp;quot;6&amp;quot;, as you can set 6 modes at once (e.g. /mode &amp;lt;channel&amp;gt; +oooooo &amp;lt;nick&amp;gt; &amp;lt;nick&amp;gt; ...)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Other_Identifiers]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Else&amp;diff=4475</id>
		<title>Else</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Else&amp;diff=4475"/>
		<updated>2006-03-29T15:43:44Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;#redirect [[if-then-else]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=On_disconnect&amp;diff=4474</id>
		<title>On disconnect</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=On_disconnect&amp;diff=4474"/>
		<updated>2006-03-29T15:36:32Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The on DISCONNECT event triggers when you quit or are disconnected from an IRC Server.&lt;br /&gt;
&lt;br /&gt;
 on &amp;lt;level&amp;gt;:DISCONNECT:&amp;lt;commands&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can use this event to unset variables or delete / free hashtables.&lt;br /&gt;
== Example ==&lt;br /&gt;
&lt;br /&gt;
The following example will unset all variables beginning with &amp;quot;moo&amp;quot; whenever you close mIRC or are disconnected.&lt;br /&gt;
&lt;br /&gt;
 on *:DISCONNECT: {&lt;br /&gt;
  [[unset]] %moo*&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
* [[on_connect|on connect]] triggers when you connect to an IRC Server&lt;br /&gt;
* [[on_quit|on quit]] triggers whenever someone quits from IRC&lt;br /&gt;
&lt;br /&gt;
[[Category:Events]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Unbannick&amp;diff=1326</id>
		<title>Unbannick</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Unbannick&amp;diff=1326"/>
		<updated>2006-03-29T15:30:06Z</updated>

		<summary type="html">&lt;p&gt;Doomie: first try, needs testing + comments + perhaps nicer text..&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Stub}}&lt;br /&gt;
This script provides an alias to unban a &amp;quot;nick&amp;quot; (respectivly his address) even if this user isn&#039;t on the channel. Therefor, it uses the [[who|/who]] command to get the current address of a nickname.&lt;br /&gt;
&lt;br /&gt;
The syntax is: /unbannick &amp;lt;channel&amp;gt; &amp;lt;nickname&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Additionally, it will drop the one unbanning this nick a message and the one that got unbanned a notice. The part about uhexec will be without further comments.&lt;br /&gt;
 &lt;br /&gt;
 ; on disconnect we clear the hashtable uhexec has used.&lt;br /&gt;
 [[On_disconnect|on *:DISCONNECT]]:[[hdel]] -w uhexec $cid $+ .*&lt;br /&gt;
 [[alias]] -l uhq [[return]] [[$iif]]([[$hget]](uhexec,$+($cid,.,[[$1]])),$v1,$iif($1 !isnum,0))&lt;br /&gt;
 alias -l uhnext {&lt;br /&gt;
  $iif($0 &amp;gt; 1,hadd -m,hdel) uhexec $+($cid,.,$uhq($1) $2-)&lt;br /&gt;
  [[hadd]] uhexec $+($cid,.,$1) $iif($uhq($1) &amp;lt; 64,$calc($v1 + 1),0)&lt;br /&gt;
 }&lt;br /&gt;
 alias -l uhexec {&lt;br /&gt;
  [[if]] ([[$status]] == connected) || ([[$ial]]($1).addr != [[$null]]) {&lt;br /&gt;
    uhnext head $1-&lt;br /&gt;
    [[userhost]] $1&lt;br /&gt;
  }&lt;br /&gt;
  [[else]] $2- $ial($1).addr&lt;br /&gt;
 }&lt;br /&gt;
 [[Raw_302|raw $302]]:/^\S+( (\S+?)\*?=[+-](\S+)|) ?$/:{&lt;br /&gt;
  [[tokenize]] 32 $uhq($uhq(tail))&lt;br /&gt;
  if ($0) &amp;amp;&amp;amp; (([[$regml]](0) &amp;lt; 2) || ($1 == $regml(2))) {&lt;br /&gt;
    uhnext tail&lt;br /&gt;
    $2- $regml(3)&lt;br /&gt;
    [[halt]]&lt;br /&gt;
  }&lt;br /&gt;
 }&lt;br /&gt;
 alias -l uncb {&lt;br /&gt;
  ; &amp;lt;chan&amp;gt; &amp;lt;nick&amp;gt; [host]&lt;br /&gt;
  if ($3 == $null) return&lt;br /&gt;
  [[var]] %i = 1, %b, %a = $+($2,!,$3)&lt;br /&gt;
  [[while]] ($ibl($1,%i) != $null) {&lt;br /&gt;
    if ($v1 iswm %a) {&lt;br /&gt;
      %b = %b $v1&lt;br /&gt;
      if ([[$numtok]](%b,32) == [[$modespl]]) {&lt;br /&gt;
        [[mode]] $1 - $+ [[$str]](b,$numtok(%b,32)) %b&lt;br /&gt;
        %b =&lt;br /&gt;
      }&lt;br /&gt;
    }&lt;br /&gt;
    [[inc]] %i&lt;br /&gt;
  }&lt;br /&gt;
  if (%b != $null) mode $1 - $+ $str(b,$numtok(%b,32)) %b&lt;br /&gt;
  [[msg]] $1 Unbanned $2 upon request&lt;br /&gt;
  [[notice]] $2 You&#039;re now unbanned on $1&lt;br /&gt;
 }&lt;br /&gt;
 ; actually provide the alias (Syntax: /unbannick &amp;lt;chan&amp;gt; &amp;lt;nick&amp;gt;)&lt;br /&gt;
 alias unbannick uhexec $2 uncb $1-2&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[Category:Script Archive]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=User:Doomie&amp;diff=2351</id>
		<title>User:Doomie</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=User:Doomie&amp;diff=2351"/>
		<updated>2006-03-13T08:20:55Z</updated>

		<summary type="html">&lt;p&gt;Doomie: yearly update&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Babel-2|de|en-3}}&lt;br /&gt;
&amp;lt;table border=&amp;quot;0&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;tr&amp;gt;&lt;br /&gt;
&amp;lt;!--&amp;lt;td&amp;gt;[[Image:Doomie.jpg]]&amp;lt;/td&amp;gt;--&amp;gt;&lt;br /&gt;
&amp;lt;td&amp;gt;&lt;br /&gt;
  &amp;lt;table border=&amp;quot;0&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;b&amp;gt;Name&amp;lt;/b&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;Philipp Krone&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;b&amp;gt;Age&amp;lt;/b&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;19&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;tr valign=&amp;quot;top&amp;quot; height=&amp;quot;40&amp;quot;&amp;gt;&amp;lt;td&amp;gt;&amp;lt;b&amp;gt;Country&amp;lt;/b&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;Chemnitz, Germany&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;tr&amp;gt;&amp;lt;td&amp;gt;&amp;lt;b&amp;gt;Words of wisdom&amp;lt;/b&amp;gt;&amp;lt;/td&amp;gt;&amp;lt;td&amp;gt;Mhh, moo!&amp;lt;/td&amp;gt;&amp;lt;/tr&amp;gt;&lt;br /&gt;
  &amp;lt;/table&amp;gt;&lt;br /&gt;
&amp;lt;/td&amp;gt;&lt;br /&gt;
&amp;lt;/tr&amp;gt;&lt;br /&gt;
&amp;lt;/table&amp;gt;&lt;br /&gt;
[[Category:Members]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=Weekday&amp;diff=4384</id>
		<title>Weekday</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=Weekday&amp;diff=4384"/>
		<updated>2006-03-13T08:08:56Z</updated>

		<summary type="html">&lt;p&gt;Doomie: typos.. changed &amp;quot;,&amp;quot; to &amp;quot;.&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The following alias returns the name of a date you have specified. Only after 01.01.0001. If no date is specified, it returns the name of the current day.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
 ; format: $day2 or $day2(day,month,year) or $day2(day.month.year)&lt;br /&gt;
 [[alias]] day2 {   &lt;br /&gt;
  ; if there are no parameter, just return the name of the current day&lt;br /&gt;
  [[if]] (!$1) { [[return]] $day }&lt;br /&gt;
  ; we get parameters&lt;br /&gt;
  else {&lt;br /&gt;
    ; lets check if we get $day2(day.month.year), then tokenize it&lt;br /&gt;
    if (($1) &amp;amp;&amp;amp; (!$2) &amp;amp;&amp;amp; ($numtok($1,46) == 3)) { [[tokenize]] 46 $1 }&lt;br /&gt;
    ; lets first check if we got 3 correct ones&lt;br /&gt;
    if (($1 !isnum 1-31) || ($2 !isnum 1-12) || (!$3)) { return $false }&lt;br /&gt;
    ; there are no 5.10.1582 -&amp;gt; 14.10.1582 due to the change of calendar&lt;br /&gt;
    if (($3 == 1582) &amp;amp;&amp;amp; ($2 == 10) &amp;amp;&amp;amp; ($1 &amp;gt; 4) &amp;amp;&amp;amp; ($1 &amp;lt; 15)) { return $false }&lt;br /&gt;
    ; we need the days of months&lt;br /&gt;
    [[var]] %month = 31,28,31,30,31,30,31,31,30,31,30,31&lt;br /&gt;
    ; lets calc all days of all complete years and days in the current month&lt;br /&gt;
    var %days = [[$calc]]((($3 - 1)*365) + ($1 - 1))&lt;br /&gt;
    ; now lets include all complete month in the current year (we need to loop through all)&lt;br /&gt;
    var %i = 0&lt;br /&gt;
    [[while]] (%i &amp;lt; $calc($2 - 1)) {&lt;br /&gt;
      %days = $calc(%days + [[$gettok]](%month,$calc(%i + 1),44))&lt;br /&gt;
      [[inc]] %i&lt;br /&gt;
    }&lt;br /&gt;
    ; decrease days by ten due to change of calendar&lt;br /&gt;
    if (($3 &amp;gt; 1582) || (($3 == 1582) &amp;amp;&amp;amp; (($2 &amp;gt; 10) || (($2 == 10) &amp;amp;&amp;amp; ($1 &amp;gt; 4))))) {&lt;br /&gt;
      %days = $calc(%days - 10)&lt;br /&gt;
    }&lt;br /&gt;
    ; leapyears til 1599:  all years divided by 4&lt;br /&gt;
    ; after 1600: all years divided by 4 but not at full centurys, only if they are dividable by 400&lt;br /&gt;
    var %leapyears = $floor($calc($3 / 4))&lt;br /&gt;
    if (($calc($3 % 4) == 0) &amp;amp;&amp;amp; ($2 &amp;lt; 3)) { [[dec]] %leapyears }&lt;br /&gt;
    if ($3 &amp;gt;= 1600) { &lt;br /&gt;
      %leapyears = $calc(%leapyears - [[$floor]]($calc(($3 - 1600) / 100)))&lt;br /&gt;
      %leapyears = $calc(%leapyears + $floor($calc(($3 - 1600) / 400))) &lt;br /&gt;
      if (($calc($3 % 100) == 0) &amp;amp;&amp;amp; ($2 &amp;lt; 3)) {&lt;br /&gt;
        inc %leapyears&lt;br /&gt;
        if ($calc($3 % 400) == 0) { dec %leapyears }&lt;br /&gt;
      }&lt;br /&gt;
    }&lt;br /&gt;
    %days = $calc(%days + %leapyears)&lt;br /&gt;
    ; lets show the result&lt;br /&gt;
    var %week = Saturday,Sunday,Monday,Tuesday,Wednesday,Thursday,Friday&lt;br /&gt;
    var %erg = $gettok(%week,$calc((%days % 7) + 1),44)&lt;br /&gt;
    return %erg&lt;br /&gt;
  }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
[[Category:Script Archive]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=On_usermode&amp;diff=1705</id>
		<title>On usermode</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=On_usermode&amp;diff=1705"/>
		<updated>2006-01-21T20:21:55Z</updated>

		<summary type="html">&lt;p&gt;Doomie: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;The on USERMODE event triggers triggers when you change your usermode.&lt;br /&gt;
 on &amp;lt;level&amp;gt;:USERMODE:&amp;lt;commands&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Read [[Access_Levels|access levels]] to get more info about the &amp;lt;level&amp;gt; field.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note&#039;&#039;&#039; that $1- refers to the changed usermode.&lt;br /&gt;
== Example ==&lt;br /&gt;
 on *:USERMODE: {&lt;br /&gt;
  [[echo]] -a Changed usermode: $1-&lt;br /&gt;
 }&lt;br /&gt;
This event would trigger when you get the confirmation of a usermode changing and echo&#039;s it to the active window.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
To check if you e.g. have set +x is more complicated as $1- could e.g. be &amp;quot;-w+x&amp;quot;, so you have to loop through $1-.&lt;br /&gt;
 on *:USERMODE: {&lt;br /&gt;
  ; set looping variable and %m as variable holding whether the current mode we are looking at&lt;br /&gt;
  ; was set or unset&lt;br /&gt;
  [[var]] %i = 1, %m&lt;br /&gt;
  ; begin to loop through $1-&lt;br /&gt;
  [[while]] (%i &amp;lt;= [[$len]]($1-)) {&lt;br /&gt;
   ; check if the current char is &amp;quot;-&amp;quot; and set %m to it (all modes will be unset after &amp;quot;-&amp;quot;)&lt;br /&gt;
   if ([[$mid]]($1-,%i,1) == -) { %m = - }&lt;br /&gt;
   ; check if the current char is &amp;quot;+&amp;quot; and set %m to it (all modes will be set after &amp;quot;+&amp;quot;)&lt;br /&gt;
   if ($mid($1-,%i,1) == +) { %m = + }&lt;br /&gt;
   ; if the char we are looking at is &amp;quot;x&amp;quot;&lt;br /&gt;
   if ($mid($1-,%i,1) == x) { &lt;br /&gt;
    ; we need to check whether %m is &amp;quot;+&amp;quot; (so x is set, not unset) and echo it&lt;br /&gt;
    if (%m == +) { echo -a Mode +x was just set. }&lt;br /&gt;
   }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
To react on channelmode changes, take a look at the [[On_mode|On Mode event]].&lt;br /&gt;
&lt;br /&gt;
[[Category:Events]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
	<entry>
		<id>https://script.quakenet.org/wiki/index.php?title=WHO_usage_and_numeric_events&amp;diff=2646</id>
		<title>WHO usage and numeric events</title>
		<link rel="alternate" type="text/html" href="https://script.quakenet.org/wiki/index.php?title=WHO_usage_and_numeric_events&amp;diff=2646"/>
		<updated>2005-12-26T17:54:26Z</updated>

		<summary type="html">&lt;p&gt;Doomie: changed link + removed author tag&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This script is supposed to show everyone how easy it is to get someones Q-authname, save it in a variable and/or return it.&lt;br /&gt;
&lt;br /&gt;
Covers the usage of raw events and the /who command.&lt;br /&gt;
&lt;br /&gt;
 ; A simple little alias that returns the time interval for the flood protection (in seconds).&lt;br /&gt;
 ; We make this [[:Category:Aliases|alias]] local (-l switch), since we wont need it outside this script.&lt;br /&gt;
 &lt;br /&gt;
 alias -l authflood {&lt;br /&gt;
  [[return]] 3&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; Basic [[On_text|On Text]] [[Events|event]] to trigger the script.&lt;br /&gt;
 &lt;br /&gt;
 on *:Text:!auth *:#: {&lt;br /&gt;
 &lt;br /&gt;
  ; Flood protection so that noone can abuse the command and flood you off the server.&lt;br /&gt;
  ; If the variable %authflood doesnt exist, the script continues.&lt;br /&gt;
 &lt;br /&gt;
  [[If-Then-Else|if]] (!%authflood) {&lt;br /&gt;
 &lt;br /&gt;
    ; Check if there really is a nick to get the auth of, by making sure $2 exists.&lt;br /&gt;
 &lt;br /&gt;
    if ($2) {&lt;br /&gt;
 &lt;br /&gt;
      ; At first, we will save $2 in a variable, since we need it later on.&lt;br /&gt;
 &lt;br /&gt;
      [[set]] %nickname $2&lt;br /&gt;
 &lt;br /&gt;
      ; Perform a /who request of the nick with the appropriate flags (n%nat). For more info on /who command, read:&lt;br /&gt;
      ; http://www.mircscripts.org/showdoc.php?type=tutorial&amp;amp;id=2412&lt;br /&gt;
      ; the t flag is to identify the reply, which we assign a random number, in this case 465 (later on being used in the &amp;quot;raw 354&amp;quot;-event)&lt;br /&gt;
 &lt;br /&gt;
      [[who]] $2 n%nat,465  &lt;br /&gt;
 &lt;br /&gt;
      ; Assign %authchan the value of $chan so we can access it later&lt;br /&gt;
 &lt;br /&gt;
      set %authchan $chan&lt;br /&gt;
 &lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    ; if there is no $2, show the syntax&lt;br /&gt;
 &lt;br /&gt;
    else {&lt;br /&gt;
      msg $chan To use it correctly, type !auth &amp;lt;nickname&amp;gt;&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    ; Set the %authflood variable (in order to prevent abuse of the command) to $authflood seconds using the -u switch.&lt;br /&gt;
 &lt;br /&gt;
    set -u [ $+ [ $authflood ] ] %authflood 1&lt;br /&gt;
  }&lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; Raw numeric 354 is the servers reply of the /who request. We check if &amp;quot;465&amp;quot; is in the reply&lt;br /&gt;
 ; to be sure its the reply we are looking for.&lt;br /&gt;
 ;&lt;br /&gt;
 ; (To read more about raws, have a look at: [[:Category:Raws|Raws]]&lt;br /&gt;
 &lt;br /&gt;
 [[Raw_354|raw 354]]:&amp;amp; 465 &amp;amp; *: {&lt;br /&gt;
 &lt;br /&gt;
  ; syntax of raw 354 (with our flags): &amp;quot;me 465 nick authname&amp;quot; for authed people or&lt;br /&gt;
  ; &amp;quot;me 465 nick 0&amp;quot; for non-authed ones.&lt;br /&gt;
  ; but for now we will just assign %authname the value of $4 without checking if is 0 or not&lt;br /&gt;
 &lt;br /&gt;
  set %authname $4&lt;br /&gt;
 &lt;br /&gt;
 }&lt;br /&gt;
 &lt;br /&gt;
 ; Raw numeric 315 notifies us that the /who request is over. Now is the time to&lt;br /&gt;
 ; process whatever data we have.&lt;br /&gt;
 &lt;br /&gt;
 [[Raw_315|raw 315]]:*: {&lt;br /&gt;
 &lt;br /&gt;
  ; syntax of raw 315: &amp;quot;me nick End of /WHO list.&amp;quot;&lt;br /&gt;
  ;&lt;br /&gt;
  ; We check if its really our reply by comparing the nickname ($2) against requested nickname (%nickname)&lt;br /&gt;
 &lt;br /&gt;
  if ($2 == %nickname) {&lt;br /&gt;
 &lt;br /&gt;
    ; At this stage %nickname should contain the nick of the requested nick, %authname the authname of %authnick&lt;br /&gt;
    ; and %authchan the channel to which we should send the information.&lt;br /&gt;
    ;&lt;br /&gt;
    ; We have to check if %authname isnt 0, since &amp;quot;!%authname&amp;quot; would return $true if %authname is 0&lt;br /&gt;
 &lt;br /&gt;
    if (!%authname) &amp;amp;&amp;amp; (%authname != 0) {&lt;br /&gt;
      [[msg]] %authchan There is noone with the nick %nickname $+ .&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    ; if %authname is set to 0 the nick isnt authed.&lt;br /&gt;
 &lt;br /&gt;
    elseif (%authname == 0) {&lt;br /&gt;
      msg %authchan %nickname is currently not authed.&lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    ; else we assume the user is authed and print the authname&lt;br /&gt;
 &lt;br /&gt;
    else {&lt;br /&gt;
      msg %authchan %nickname is authed as %authname $+ .&lt;br /&gt;
 &lt;br /&gt;
    }&lt;br /&gt;
 &lt;br /&gt;
    ; Unset the used variables&lt;br /&gt;
 &lt;br /&gt;
    [[unset]] %authname&lt;br /&gt;
    unset %authchan&lt;br /&gt;
    unset %nickname&lt;br /&gt;
 &lt;br /&gt;
  }&lt;br /&gt;
 }&lt;br /&gt;
&lt;br /&gt;
[[Category:Script Archive]]&lt;/div&gt;</summary>
		<author><name>Doomie</name></author>
	</entry>
</feed>