<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.digitalmzx.com/wiki/index.php?action=history&amp;feed=atom&amp;title=Busyloop</id>
	<title>Busyloop - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://www.digitalmzx.com/wiki/index.php?action=history&amp;feed=atom&amp;title=Busyloop"/>
	<link rel="alternate" type="text/html" href="https://www.digitalmzx.com/wiki/index.php?title=Busyloop&amp;action=history"/>
	<updated>2026-05-11T20:24:53Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.7</generator>
	<entry>
		<id>https://www.digitalmzx.com/wiki/index.php?title=Busyloop&amp;diff=7974&amp;oldid=prev</id>
		<title>Kuroneko at 05:02, 27 July 2012</title>
		<link rel="alternate" type="text/html" href="https://www.digitalmzx.com/wiki/index.php?title=Busyloop&amp;diff=7974&amp;oldid=prev"/>
		<updated>2012-07-27T05:02:14Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 05:02, 27 July 2012&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l3&quot;&gt;Line 3:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 3:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  . &amp;quot;do some code here&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  . &amp;quot;do some code here&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  goto &amp;quot;loop&amp;quot;&amp;lt;/tt&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  goto &amp;quot;loop&amp;quot;&amp;lt;/tt&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;More specifically, this term often refers to a loop like the previous one that does not have an explicit [[cycle]] terminator, and thus does more work than it should per cycle.  In the past this wasn't a big deal and had few negative effects, since the [[commands]]-per-cycle limit of 40 forced execution to move to the next robot fairly quickly.  Since the addition of the &amp;quot;commands&amp;quot; counter, which can variably set this number into the billions, a loop like this becomes a far more serious problem, and can easily cause a game to hang.  For this reason, it is recommended that all busyloops contain either of the commands &amp;quot;[[wait &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;1&lt;/del&gt;]]&amp;quot; or &amp;quot;[[cycle]] 1&amp;quot; at some point in their execution.  Usually the best place is right after the loop label, if there are multiple points of return; or right before the &amp;quot;goto&amp;quot; command if there is only one.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;More specifically, this term often refers to a loop like the previous one that does not have an explicit [[cycle]] terminator, and thus does more work than it should per cycle.  In the past this wasn't a big deal and had few negative effects, since the [[commands]]-per-cycle limit of 40 forced execution to move to the next robot fairly quickly.  Since the addition of the &amp;quot;commands&amp;quot; counter, which can variably set this number into the billions, a loop like this becomes a far more serious problem, and can easily cause a game to hang.  For this reason, it is recommended that all busyloops contain either of the commands &amp;quot;[[wait]] &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;1&lt;/ins&gt;&amp;quot; or &amp;quot;[[cycle]] 1&amp;quot; at some point in their execution.  Usually the best place is right after the loop label, if there are multiple points of return; or right before the &amp;quot;goto&amp;quot; command if there is only one.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:MegaZeux]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:MegaZeux]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Kuroneko</name></author>
	</entry>
	<entry>
		<id>https://www.digitalmzx.com/wiki/index.php?title=Busyloop&amp;diff=7973&amp;oldid=prev</id>
		<title>Kuroneko at 05:01, 27 July 2012</title>
		<link rel="alternate" type="text/html" href="https://www.digitalmzx.com/wiki/index.php?title=Busyloop&amp;diff=7973&amp;oldid=prev"/>
		<updated>2012-07-27T05:01:36Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 05:01, 27 July 2012&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l3&quot;&gt;Line 3:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 3:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  . &amp;quot;do some code here&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  . &amp;quot;do some code here&amp;quot;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  goto &amp;quot;loop&amp;quot;&amp;lt;/tt&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;  goto &amp;quot;loop&amp;quot;&amp;lt;/tt&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;More specifically, this term often refers to a loop like the previous one that does not have an explicit [[cycle]] terminator, and thus does more work than it should per cycle.  In the past this wasn't a big deal and had few negative effects, since the [[commands]]-per-cycle limit of 40 forced execution to move to the next robot fairly quickly.  Since the addition of the &amp;quot;commands&amp;quot; counter, which can variably set this number into the billions, a loop like this becomes a far more serious problem, and can easily cause a game to hang.  For this reason, it is recommended that all busyloops contain the &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;command &lt;/del&gt;&amp;quot;cycle 1&amp;quot; at some point in their execution.  Usually the best place is right after the loop label, if there are multiple points of return; or right before the &amp;quot;goto&amp;quot; command if there is only one.&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;More specifically, this term often refers to a loop like the previous one that does not have an explicit [[cycle]] terminator, and thus does more work than it should per cycle.  In the past this wasn't a big deal and had few negative effects, since the [[commands]]-per-cycle limit of 40 forced execution to move to the next robot fairly quickly.  Since the addition of the &amp;quot;commands&amp;quot; counter, which can variably set this number into the billions, a loop like this becomes a far more serious problem, and can easily cause a game to hang.  For this reason, it is recommended that all busyloops contain &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;either of &lt;/ins&gt;the &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;commands &lt;/ins&gt;&amp;quot;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[wait 1]]&amp;quot; or &amp;quot;[[&lt;/ins&gt;cycle&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;]] &lt;/ins&gt;1&amp;quot; at some point in their execution.  Usually the best place is right after the loop label, if there are multiple points of return; or right before the &amp;quot;goto&amp;quot; command if there is only one.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:MegaZeux]]&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:MegaZeux]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Kuroneko</name></author>
	</entry>
	<entry>
		<id>https://www.digitalmzx.com/wiki/index.php?title=Busyloop&amp;diff=6644&amp;oldid=prev</id>
		<title>Wervyn: New, short explanation of busyloops</title>
		<link rel="alternate" type="text/html" href="https://www.digitalmzx.com/wiki/index.php?title=Busyloop&amp;diff=6644&amp;oldid=prev"/>
		<updated>2009-01-29T23:53:37Z</updated>

		<summary type="html">&lt;p&gt;New, short explanation of busyloops&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;In [[MegaZeux]] parlance, a '''busyloop''' is any program loop designed to execute continuously during the game, such as:&amp;lt;tt&amp;gt;&lt;br /&gt;
 : &amp;quot;loop&amp;quot;&lt;br /&gt;
 . &amp;quot;do some code here&amp;quot;&lt;br /&gt;
 goto &amp;quot;loop&amp;quot;&amp;lt;/tt&amp;gt;&lt;br /&gt;
More specifically, this term often refers to a loop like the previous one that does not have an explicit [[cycle]] terminator, and thus does more work than it should per cycle.  In the past this wasn't a big deal and had few negative effects, since the [[commands]]-per-cycle limit of 40 forced execution to move to the next robot fairly quickly.  Since the addition of the &amp;quot;commands&amp;quot; counter, which can variably set this number into the billions, a loop like this becomes a far more serious problem, and can easily cause a game to hang.  For this reason, it is recommended that all busyloops contain the command &amp;quot;cycle 1&amp;quot; at some point in their execution.  Usually the best place is right after the loop label, if there are multiple points of return; or right before the &amp;quot;goto&amp;quot; command if there is only one.&lt;br /&gt;
&lt;br /&gt;
[[Category:MegaZeux]]&lt;/div&gt;</summary>
		<author><name>Wervyn</name></author>
	</entry>
</feed>