<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>https://staredit.net/wiki/index.php?action=history&amp;feed=atom&amp;title=Wait_blocks</id>
		<title>Wait blocks - Revision history</title>
		<link rel="self" type="application/atom+xml" href="https://staredit.net/wiki/index.php?action=history&amp;feed=atom&amp;title=Wait_blocks"/>
		<link rel="alternate" type="text/html" href="https://staredit.net/wiki/index.php?title=Wait_blocks&amp;action=history"/>
		<updated>2026-04-09T14:57:22Z</updated>
		<subtitle>Revision history for this page on the wiki</subtitle>
		<generator>MediaWiki 1.27.7</generator>

	<entry>
		<id>https://staredit.net/wiki/index.php?title=Wait_blocks&amp;diff=629&amp;oldid=prev</id>
		<title>Zurg: adding to the Reference category</title>
		<link rel="alternate" type="text/html" href="https://staredit.net/wiki/index.php?title=Wait_blocks&amp;diff=629&amp;oldid=prev"/>
				<updated>2019-11-23T09:58:22Z</updated>
		
		<summary type="html">&lt;p&gt;adding to the Reference category&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;' lang='en'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 09:58, 23 November 2019&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-l112&quot; &gt;Line 112:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 112:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:StarCraft]]&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;[[Category:StarCraft]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; 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;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Category:Reference]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Zurg</name></author>	</entry>

	<entry>
		<id>https://staredit.net/wiki/index.php?title=Wait_blocks&amp;diff=561&amp;oldid=prev</id>
		<title>Zurg at 02:56, 3 August 2015</title>
		<link rel="alternate" type="text/html" href="https://staredit.net/wiki/index.php?title=Wait_blocks&amp;diff=561&amp;oldid=prev"/>
				<updated>2015-08-03T02:56:24Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;col class='diff-marker' /&gt;
				&lt;col class='diff-content' /&gt;
				&lt;tr style='vertical-align: top;' lang='en'&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan='2' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 02:56, 3 August 2015&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-l1&quot; &gt;Line 1:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; 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;'''Wait blocks''' are [[trigger]]-related issues in ''&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;[[&lt;/del&gt;StarCraft&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;]]&lt;/del&gt;'' maps. They occur when the game tries to execute two Wait actions at the same time. Only one Wait action may be run at a time, so if a second is encountered, it is forcibly delayed until the first completes.&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; 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;'''Wait blocks''' are [[trigger]]-related issues in ''StarCraft'' maps. They occur when the game tries to execute two Wait actions at the same time. Only one Wait action may be run at a time, so if a second is encountered, it is forcibly delayed until the first completes.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Wait blocks commonly occur when a map's triggers use both Waits and Wait-based [[hyper triggers]].&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Wait blocks commonly occur when a map's triggers use both Waits and Wait-based [[hyper triggers]].&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Zurg</name></author>	</entry>

	<entry>
		<id>https://staredit.net/wiki/index.php?title=Wait_blocks&amp;diff=306&amp;oldid=prev</id>
		<title>DevliN: 1 revision imported: Restoring SC1 backup</title>
		<link rel="alternate" type="text/html" href="https://staredit.net/wiki/index.php?title=Wait_blocks&amp;diff=306&amp;oldid=prev"/>
				<updated>2015-03-21T04:39:37Z</updated>
		
		<summary type="html">&lt;p&gt;1 revision imported: Restoring SC1 backup&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr style='vertical-align: top;' lang='en'&gt;
				&lt;td colspan='1' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan='1' style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Revision as of 04:39, 21 March 2015&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan='2' style='text-align: center;' lang='en'&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(No difference)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>DevliN</name></author>	</entry>

	<entry>
		<id>https://staredit.net/wiki/index.php?title=Wait_blocks&amp;diff=305&amp;oldid=prev</id>
		<title>Zurg: /* Inner workings of the Wait action */</title>
		<link rel="alternate" type="text/html" href="https://staredit.net/wiki/index.php?title=Wait_blocks&amp;diff=305&amp;oldid=prev"/>
				<updated>2015-03-09T22:44:12Z</updated>
		
		<summary type="html">&lt;p&gt;‎&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;Inner workings of the Wait action&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;'''Wait blocks''' are [[trigger]]-related issues in ''[[StarCraft]]'' maps. They occur when the game tries to execute two Wait actions at the same time. Only one Wait action may be run at a time, so if a second is encountered, it is forcibly delayed until the first completes.&lt;br /&gt;
&lt;br /&gt;
Wait blocks commonly occur when a map's triggers use both Waits and Wait-based [[hyper triggers]].&lt;br /&gt;
&lt;br /&gt;
== Inner workings of the Wait action ==&lt;br /&gt;
Wait actions do more than just delaying other trigger actions by a given amount of milliseconds. When ''StarCraft'' runs a trigger for a player and encounters a Wait action, it takes the triggers that it has already processed for that player, and re-processes them all. ''Then'', the game delays the actions following the Wait. Consider a map with the following two triggers:&lt;br /&gt;
&lt;br /&gt;
{{StarCraft Trigger&lt;br /&gt;
|description=Create a Marine every trigger cycle.&lt;br /&gt;
|players=*Player 1&lt;br /&gt;
|conditions=*Always&lt;br /&gt;
|actions=&lt;br /&gt;
*Create 1 [[Terran Marine (StarCraft)|Terran Marine]] at Anywhere for Player 1.&lt;br /&gt;
*Preserve trigger.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
{{StarCraft Trigger&lt;br /&gt;
|description=Display a message, wait a full second, and display another message.&lt;br /&gt;
|players=*Player 1&lt;br /&gt;
|conditions=*Always&lt;br /&gt;
|actions=&lt;br /&gt;
*Display for current player:Hello!&lt;br /&gt;
*Wait 1000 milliseconds.&lt;br /&gt;
*Display for current player:Goodbye!&lt;br /&gt;
*Preserve trigger.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
When those triggers are processed, ''StarCraft'' will do the following:&lt;br /&gt;
*Create a Terran Marine for Player 1.&lt;br /&gt;
*Display &amp;quot;Hello!&amp;quot; on Player 1's screen.&lt;br /&gt;
*Process the Wait action, by re-executing all Player 1 triggers.&lt;br /&gt;
**Create a Terran Marine for Player 1.&lt;br /&gt;
**Wait for a full second.&lt;br /&gt;
*Display &amp;quot;Goodbye!&amp;quot; on Player 1's screen.&lt;br /&gt;
That would be one trigger cycle.&lt;br /&gt;
&lt;br /&gt;
== Wait blocks ==&lt;br /&gt;
The problems come when two Waits exist for the same player. Consider ''these'' triggers:&lt;br /&gt;
&lt;br /&gt;
{{StarCraft Trigger&lt;br /&gt;
|description=TRIGGER 1. Create a Marine, wait a full second, and create another Marine.&lt;br /&gt;
|players=*Player 1&lt;br /&gt;
|conditions=*Always&lt;br /&gt;
|actions=&lt;br /&gt;
*Create 1 Terran Marine at Anywhere for Player 1.&lt;br /&gt;
*Wait 1000 milliseconds.&lt;br /&gt;
*Create 1 [[Terran SCV (StarCraft)|Terran SCV]] at Anywhere for Player 1.&lt;br /&gt;
*Preserve trigger.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
{{StarCraft Trigger&lt;br /&gt;
|description=TRIGGER 2. Display a message, wait a full second, and display another message.&lt;br /&gt;
|players=*Player 1&lt;br /&gt;
|conditions=*Always&lt;br /&gt;
|actions=&lt;br /&gt;
*Display for current player:Hello!&lt;br /&gt;
*Wait 1000 milliseconds.&lt;br /&gt;
*Display for current player:Goodbye!&lt;br /&gt;
*Preserve trigger.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
'''When ''StarCraft'' processes those triggers, it will do the following:'''&lt;br /&gt;
*First trigger round&lt;br /&gt;
*Create a Terran Marine for Player 1.&lt;br /&gt;
**Increase wait timer by 1000 (TRIGGER 1)&lt;br /&gt;
*Display &amp;quot;Hello!&amp;quot; on Player 1's screen.&lt;br /&gt;
**There is already a wait on the wait timer, so wait until it's over to continue&lt;br /&gt;
*Wait for a full second. (TRIGGER 1)&lt;br /&gt;
*Create a Terran SCV for Player 1.&lt;br /&gt;
**Increase wait timer by 1000 (TRIGGER 2)&lt;br /&gt;
*Next trigger round&lt;br /&gt;
*Create a Terran Marine for Player 1.&lt;br /&gt;
**There is already a wait on the wait timer, but it's from a previous round, so increase wait timer by 1000 (Trigger 1)&lt;br /&gt;
*Wait for 2 seconds. (TRIGGER 1+2)&lt;br /&gt;
*Next trigger round&lt;br /&gt;
*Create a Terran SCV for Player 1.&lt;br /&gt;
*Display for current player:Goodbye!&lt;br /&gt;
&lt;br /&gt;
**The Wait action here cannot be processed, because the game is already processing a Wait action. This Wait and any remaining actions in this trigger (TRIGGER 1) will be delayed.&lt;br /&gt;
**Wait for a full second.&lt;br /&gt;
**Execute any delayed trigger actions.&lt;br /&gt;
***Process the delayed Wait from TRIGGER 1.&lt;br /&gt;
****There are no Player 1 triggers before TRIGGER 1.&lt;br /&gt;
****Wait for a full second.&lt;br /&gt;
***Create a Terran Marine for Player 1.&lt;br /&gt;
*Display &amp;quot;Goodbye!&amp;quot; on Player 1's screen.&lt;br /&gt;
&lt;br /&gt;
'''That is a full trigger cycle. In simpler terms, here is what happens:'''&lt;br /&gt;
*Create a Terran Marine for Player 1.&lt;br /&gt;
*Display &amp;quot;Hello!&amp;quot;&lt;br /&gt;
*Wait for a full second. (TRIGGER 1)&lt;br /&gt;
*Create a Terran SCV for Player 1.&lt;br /&gt;
*Create a Terran Marine for Player 1.&lt;br /&gt;
*Wait for a full second. (TRIGGER 2)&lt;br /&gt;
*Wait for a full second. (TRIGGER 1)&lt;br /&gt;
**Essentially, the two waits are combined.&lt;br /&gt;
*Create a Terran SCV for Player 1.&lt;br /&gt;
*Display &amp;quot;Goodbye!&amp;quot;&lt;br /&gt;
&lt;br /&gt;
In simple systems, this is often only a minor annoyance... But when large amounts of waits are used (as is the case when using Wait-based hyper triggers), the combined Wait time can cause a massive (or even infinitely long) wait block, completely breaking the map's triggers.&lt;br /&gt;
&lt;br /&gt;
== Why do Waits behave this way? ==&lt;br /&gt;
The reason that previous triggers are re-processed when a Wait is run is to prevent problems in the trigger system. If triggers were not re-processed, then for the above example, there would be ''a full second where no triggers can run''. (This would translate to a full second in which no Marines are created.) In maps that need to detect things like unit locations and deaths, this would be a catastrophic delay. Any kind of map that requires precision or timing would end up completely broken. By re-processing the trigger list, ''StarCraft'' is able to delay trigger actions without breaking the trigger system. Wait blocks are simply an unanticipated problem in this system.&lt;br /&gt;
&lt;br /&gt;
== Solutions ==&lt;br /&gt;
*When using Wait-based hyper triggers, set them up properly. Alternatively, switch to &amp;quot;complex&amp;quot; hyper triggers, which are (ironically) much easier to set up and maintain.&lt;br /&gt;
*Avoid situations where a player could end up running multiple Waits at once.&lt;br /&gt;
*Use different methods to keep track of time. Timers can use [[death counters]], countdown timers, the movement of a unit from one location to another, or even the burning and destruction of a badly-damaged [[Terran]] building (using the death counters or Extended Unit Deaths to detect certain values.)&lt;br /&gt;
&lt;br /&gt;
== External links ==&lt;br /&gt;
*[http://www.youtube.com/watch?v=olYjMbmqj5g A YouTube video] illustrating how waits are processed, using some of the example triggers [[#Inner workings of the wait action|in this article]].&lt;br /&gt;
&lt;br /&gt;
[[Category:StarCraft]]&lt;/div&gt;</summary>
		<author><name>Zurg</name></author>	</entry>

	</feed>