<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://chronocrash.com/openbor/wiki/index.php?action=history&amp;feed=atom&amp;title=Updatedscript</id>
	<title>Updatedscript - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://chronocrash.com/openbor/wiki/index.php?action=history&amp;feed=atom&amp;title=Updatedscript"/>
	<link rel="alternate" type="text/html" href="https://chronocrash.com/openbor/wiki/index.php?title=Updatedscript&amp;action=history"/>
	<updated>2026-08-26T18:43:52Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.46.0</generator>
	<entry>
		<id>https://chronocrash.com/openbor/wiki/index.php?title=Updatedscript&amp;diff=1026&amp;oldid=prev</id>
		<title>Dcurrent at 00:01, 21 August 2026</title>
		<link rel="alternate" type="text/html" href="https://chronocrash.com/openbor/wiki/index.php?title=Updatedscript&amp;diff=1026&amp;oldid=prev"/>
		<updated>2026-08-21T00:01:14Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw-interface=&quot;&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 20:01, 20 August 2026&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=&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:Level]]&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:Level]]&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;&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Category:Script]]&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-added&quot;&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:Script Events]]&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:Script Events]]&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 colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l219&quot;&gt;Line 219:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 218:&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;* [[Time]]&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;* [[Time]]&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;* [[Script Overview]]&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;* [[Script Overview]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&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;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;[[Category:OpenBOR Index]]&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Dcurrent</name></author>
	</entry>
	<entry>
		<id>https://chronocrash.com/openbor/wiki/index.php?title=Updatedscript&amp;diff=1025&amp;oldid=prev</id>
		<title>Dcurrent: /* Execution */</title>
		<link rel="alternate" type="text/html" href="https://chronocrash.com/openbor/wiki/index.php?title=Updatedscript&amp;diff=1025&amp;oldid=prev"/>
		<updated>2026-08-21T00:00:17Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Execution&lt;/span&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw-interface=&quot;&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 20:00, 20 August 2026&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-l54&quot;&gt;Line 54:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 54:&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;# OpenBOR refreshes timing and player input state.&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;# OpenBOR refreshes timing and player input state.&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;# Global &amp;lt;code&amp;gt;data/scripts/update.c&amp;lt;/code&amp;gt; executes when present.&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;# Global &amp;lt;code&amp;gt;data/scripts/update.c&amp;lt;/code&amp;gt; executes when present.&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;# The current level&#039;s [[&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Updatescript (Level)|&lt;/del&gt;updatescript]] executes when declared.&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;# The current level&#039;s [[updatescript]] executes when declared.&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;# OpenBOR processes applicable key-script events.&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;# OpenBOR processes applicable key-script events.&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;# OpenBOR advances logical time and performs scrolling, timer, and entity simulation work as required.&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;# OpenBOR advances logical time and performs scrolling, timer, and entity simulation work as required.&lt;/div&gt;&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-l145&quot;&gt;Line 145:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 145:&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;| Universal managers and common early-cycle state&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;| Universal managers and common early-cycle state&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;| [[Updatescript &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;(Level)&lt;/del&gt;|level updatescript]]&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;| [[Updatescript|level updatescript]]&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;| Current level&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;| Current level&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;| After global &amp;lt;code&amp;gt;update.c&amp;lt;/code&amp;gt;, before key events and simulation&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;| After global &amp;lt;code&amp;gt;update.c&amp;lt;/code&amp;gt;, before key events and simulation&lt;/div&gt;&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-l189&quot;&gt;Line 189:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 189:&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;| Global early-cycle hook that executes before the level&amp;#039;s &amp;lt;code&amp;gt;updatescript&amp;lt;/code&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;| Global early-cycle hook that executes before the level&amp;#039;s &amp;lt;code&amp;gt;updatescript&amp;lt;/code&amp;gt;.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;| [[&lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Updatescript (Level)|&lt;/del&gt;updatescript]]&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;| [[updatescript]]&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;| Level-specific early-cycle hook that executes before key events and simulation.&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;| Level-specific early-cycle hook that executes before key events and simulation.&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;|-&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l211&quot;&gt;Line 211:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 211:&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;* [[Updated]]&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;* [[Updated]]&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;* [[Updatescript (Level)]]&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;* [[&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Updatescript|&lt;/ins&gt;Updatescript (Level)]]&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;* [[Update]]&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;* [[Update]]&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;* [[Updateentityscript]]&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;* [[Updateentityscript]]&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Dcurrent</name></author>
	</entry>
	<entry>
		<id>https://chronocrash.com/openbor/wiki/index.php?title=Updatedscript&amp;diff=1024&amp;oldid=prev</id>
		<title>Dcurrent: Created page with &quot;Category:Level Category:Script Category:Script Events  &#039;&#039;&#039;updatedscript&#039;&#039;&#039; is a level-specific recurring event hook. It executes late in each eligible outer update cycle, after entity simulation and standard display-queue construction. The global &lt;code&gt;data/scripts/updated.c&lt;/code&gt; hook executes first, followed by the current level&#039;s &lt;code&gt;updatedscript&lt;/code&gt;. OpenBOR then draws the completed sprite queue.  This position makes &lt;code&gt;updatedscript&lt;/code&gt; the...&quot;</title>
		<link rel="alternate" type="text/html" href="https://chronocrash.com/openbor/wiki/index.php?title=Updatedscript&amp;diff=1024&amp;oldid=prev"/>
		<updated>2026-08-20T23:58:05Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;&lt;a href=&quot;/openbor/wiki/index.php/Category:Level&quot; title=&quot;Category:Level&quot;&gt;Category:Level&lt;/a&gt; &lt;a href=&quot;/openbor/wiki/index.php/Category:Script&quot; title=&quot;Category:Script&quot;&gt;Category:Script&lt;/a&gt; &lt;a href=&quot;/openbor/wiki/index.php/Category:Script_Events&quot; title=&quot;Category:Script Events&quot;&gt;Category:Script Events&lt;/a&gt;  &amp;#039;&amp;#039;&amp;#039;updatedscript&amp;#039;&amp;#039;&amp;#039; is a level-specific recurring event hook. It executes late in each eligible outer update cycle, after entity simulation and standard display-queue construction. The global &amp;lt;code&amp;gt;data/scripts/updated.c&amp;lt;/code&amp;gt; hook executes first, followed by the current level&amp;#039;s &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt;. OpenBOR then draws the completed sprite queue.  This position makes &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt; the...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;[[Category:Level]]&lt;br /&gt;
[[Category:Script]]&lt;br /&gt;
[[Category:Script Events]]&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;updatedscript&amp;#039;&amp;#039;&amp;#039; is a level-specific recurring event hook. It executes late in each eligible outer update cycle, after entity simulation and standard display-queue construction. The global &amp;lt;code&amp;gt;data/scripts/updated.c&amp;lt;/code&amp;gt; hook executes first, followed by the current level&amp;#039;s &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt;. OpenBOR then draws the completed sprite queue.&lt;br /&gt;
&lt;br /&gt;
This position makes &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt; the level&amp;#039;s final recurring control point before presentation. It can evaluate the results of the current simulation, resolve stage-specific systems using finalized state, append custom presentation to the current display queue, and prepare values for the next cycle without placing level-only logic in the global updated script.&lt;br /&gt;
&lt;br /&gt;
== Usage ==&lt;br /&gt;
&lt;br /&gt;
Add &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt; to a level definition and provide the path to the script file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;text&amp;quot;&amp;gt;&lt;br /&gt;
updatedscript data/scripts/levels/storm_docks_updated.c&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The referenced script uses a &amp;lt;code&amp;gt;main()&amp;lt;/code&amp;gt; entry point and receives no automatic event variables.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;c&amp;quot; line&amp;gt;&lt;br /&gt;
void main()&lt;br /&gt;
{&lt;br /&gt;
    // Perform recurring late-cycle level logic here.&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
OpenBOR loads the script with the level and executes it only while that level remains available. No project-wide script file or model command is required.&lt;br /&gt;
&lt;br /&gt;
Only one &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt; command is available to a level. Multiple recurring tasks may be organized into functions and called from the script&amp;#039;s &amp;lt;code&amp;gt;main()&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== Inline Script ==&lt;br /&gt;
&lt;br /&gt;
The command also supports an inline script block:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;text&amp;quot; line&amp;gt;&lt;br /&gt;
updatedscript @script&lt;br /&gt;
void main()&lt;br /&gt;
{&lt;br /&gt;
    int objective_complete = getglobalvar(&amp;quot;storm_docks_complete&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    if (objective_complete)&lt;br /&gt;
    {&lt;br /&gt;
        drawstring(8, 16, 0, &amp;quot;OBJECTIVE COMPLETE&amp;quot;, 1000000);&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
@end_script&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inline form is useful for concise level-only behavior. External files are easier to reuse and organize when the late-cycle controller contains several systems or helper functions.&lt;br /&gt;
&lt;br /&gt;
== Execution ==&lt;br /&gt;
&lt;br /&gt;
The relevant outer update sequence is:&lt;br /&gt;
&lt;br /&gt;
# OpenBOR refreshes timing and player input state.&lt;br /&gt;
# Global &amp;lt;code&amp;gt;data/scripts/update.c&amp;lt;/code&amp;gt; executes when present.&lt;br /&gt;
# The current level&amp;#039;s [[Updatescript (Level)|updatescript]] executes when declared.&lt;br /&gt;
# OpenBOR processes applicable key-script events.&lt;br /&gt;
# OpenBOR advances logical time and performs scrolling, timer, and entity simulation work as required.&lt;br /&gt;
# OpenBOR clears the working screen and constructs the standard background, interface, text, and entity display queues.&lt;br /&gt;
# Global &amp;lt;code&amp;gt;data/scripts/updated.c&amp;lt;/code&amp;gt; executes when present.&lt;br /&gt;
# The current level&amp;#039;s &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt; executes when declared.&lt;br /&gt;
# OpenBOR processes the remaining control work, draws the completed sprite queue, presents the screen, and clears the queue.&lt;br /&gt;
&lt;br /&gt;
Global &amp;lt;code&amp;gt;updated.c&amp;lt;/code&amp;gt; always executes before the level &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt;. The level hook can therefore consume common late-cycle state established by &amp;lt;code&amp;gt;updated.c&amp;lt;/code&amp;gt;, specialize it for the current stage, or add level-specific presentation to the same display queue.&lt;br /&gt;
&lt;br /&gt;
Simulation for the cycle has already completed when &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt; begins. State produced by entity updates, movement, scrolling, timers, attacks, and other simulation work is available for final evaluation. This is particularly useful when a decision should account for everything that happened during the current cycle rather than the state that existed at its beginning.&lt;br /&gt;
&lt;br /&gt;
== Display Queue Position ==&lt;br /&gt;
&lt;br /&gt;
Standard background, status, text, and entity display entries are normally queued before &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt;. The queue has not yet been drawn. Script drawing functions such as &amp;lt;code&amp;gt;drawstring()&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;drawbox()&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;drawsprite()&amp;lt;/code&amp;gt;, and &amp;lt;code&amp;gt;drawscreen()&amp;lt;/code&amp;gt; can therefore append presentation that appears in the same screen update.&lt;br /&gt;
&lt;br /&gt;
Queue placement still follows each drawing function&amp;#039;s layer, Z, and sorting rules. Calling a drawing function later does not by itself force the result above every existing item.&lt;br /&gt;
&lt;br /&gt;
Changes to entity or level state also take effect immediately, though standard entity display entries for the current cycle have already been prepared. Such changes naturally influence later logic and the next display-queue build. Custom drawing added directly by &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt; can appear during the current cycle.&lt;br /&gt;
&lt;br /&gt;
This combination supports both roles cleanly:&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Post-simulation control&amp;#039;&amp;#039;&amp;#039; - Evaluate finalized gameplay state and prepare subsequent behavior.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Current-cycle presentation&amp;#039;&amp;#039;&amp;#039; - Add overlays, messages, flashes, subscreens, debugging information, or other custom draw work before the queue is rendered.&lt;br /&gt;
&lt;br /&gt;
== Execution Frequency ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt; executes once per eligible outer update cycle. Outer update frequency is independent of OpenBOR&amp;#039;s logical clock and may vary with the selected update limit, display synchronization, platform timing, and runtime conditions.&lt;br /&gt;
&lt;br /&gt;
One execution therefore does not necessarily represent one logical tick. Each outer cycle may contain no entity simulation step or may process several logical ticks before reaching &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt;. Gameplay duration should be measured with &amp;lt;code&amp;gt;openborvariant(&amp;quot;elapsed_time&amp;quot;)&amp;lt;/code&amp;gt; or another suitable time source instead of counting executions.&lt;br /&gt;
&lt;br /&gt;
During an in-game update cycle, the updated hooks are not suppressed by the pause flag. &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt; can consequently execute during paused cycles even though simulation and standard display-queue preparation are paused. Enabling &amp;lt;code&amp;gt;alwaysupdate&amp;lt;/code&amp;gt; expands eligibility to other update calls, provided the level remains loaded.&lt;br /&gt;
&lt;br /&gt;
== Level Scope ==&lt;br /&gt;
&lt;br /&gt;
Global &amp;lt;code&amp;gt;updated.c&amp;lt;/code&amp;gt; is appropriate for late-cycle systems used throughout a project. Level &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt; supplies the same phase with a narrower lifetime and direct ownership by one level.&lt;br /&gt;
&lt;br /&gt;
This separation keeps stage-specific resolution and presentation with the stage that uses them. Universal overlay managers, diagnostics, or project-wide post-simulation systems can remain in &amp;lt;code&amp;gt;updated.c&amp;lt;/code&amp;gt;, while individual levels provide their own objectives, encounter resolution, environmental composition, cinematic treatment, or late-cycle coordination.&lt;br /&gt;
&lt;br /&gt;
== Example: Post-Simulation Encounter Resolution ==&lt;br /&gt;
&lt;br /&gt;
The following compact controller advances an encounter after participating systems report that no targets remain:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;c&amp;quot; line&amp;gt;&lt;br /&gt;
void main()&lt;br /&gt;
{&lt;br /&gt;
    int phase = getglobalvar(&amp;quot;foundry_phase&amp;quot;);&lt;br /&gt;
    int enemies_remaining = getglobalvar(&amp;quot;foundry_enemies_remaining&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    if (phase == 2 &amp;amp;&amp;amp; enemies_remaining &amp;lt;= 0)&lt;br /&gt;
    {&lt;br /&gt;
        setglobalvar(&amp;quot;foundry_phase&amp;quot;, 3);&lt;br /&gt;
        setglobalvar(&amp;quot;foundry_gate_open&amp;quot;, 1);&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Entity scripts or other encounter components may update &amp;lt;code&amp;gt;foundry_enemies_remaining&amp;lt;/code&amp;gt; during simulation. Running the decision in &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt; lets the level controller evaluate the resulting state after those updates have finished for the cycle.&lt;br /&gt;
&lt;br /&gt;
== Example: Same-Cycle Objective Message ==&lt;br /&gt;
&lt;br /&gt;
This example adds a timed message after the standard display entries are prepared:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;c&amp;quot; line&amp;gt;&lt;br /&gt;
void main()&lt;br /&gt;
{&lt;br /&gt;
    long elapsed = openborvariant(&amp;quot;elapsed_time&amp;quot;);&lt;br /&gt;
    long message_until = getglobalvar(&amp;quot;foundry_message_until&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    if (message_until &amp;gt; elapsed)&lt;br /&gt;
    {&lt;br /&gt;
        drawstring(8, 16, 0, &amp;quot;COOLING SYSTEM DISABLED&amp;quot;, 1000000);&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The text is added to the current display queue and appears when OpenBOR draws that queue later in the same cycle. Logical time controls the duration, so the message does not depend on outer update frequency.&lt;br /&gt;
&lt;br /&gt;
== Choosing an Update Hook ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Hook&lt;br /&gt;
! Scope&lt;br /&gt;
! Phase&lt;br /&gt;
! Typical responsibility&lt;br /&gt;
|-&lt;br /&gt;
| [[Update|&amp;lt;code&amp;gt;data/scripts/update.c&amp;lt;/code&amp;gt;]]&lt;br /&gt;
| Project-wide&lt;br /&gt;
| First recurring script in the outer update cycle&lt;br /&gt;
| Universal managers and common early-cycle state&lt;br /&gt;
|-&lt;br /&gt;
| [[Updatescript (Level)|level updatescript]]&lt;br /&gt;
| Current level&lt;br /&gt;
| After global &amp;lt;code&amp;gt;update.c&amp;lt;/code&amp;gt;, before key events and simulation&lt;br /&gt;
| Stage-specific preparation, rules, objectives, and encounter control&lt;br /&gt;
|-&lt;br /&gt;
| [[Updateentityscript|model script]]&lt;br /&gt;
| Individual active entity&lt;br /&gt;
| Entity simulation&lt;br /&gt;
| Per-entity recurring behavior&lt;br /&gt;
|-&lt;br /&gt;
| [[Updated|&amp;lt;code&amp;gt;data/scripts/updated.c&amp;lt;/code&amp;gt;]]&lt;br /&gt;
| Project-wide&lt;br /&gt;
| After simulation and standard display-queue construction&lt;br /&gt;
| Universal post-simulation logic and late presentation&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;level updatedscript&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
| Current level&lt;br /&gt;
| After global &amp;lt;code&amp;gt;updated.c&amp;lt;/code&amp;gt;, before the display queue is drawn&lt;br /&gt;
| Stage-specific final evaluation and same-cycle presentation&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
These hooks complement one another. Projects can distribute work according to ownership and timing instead of forcing unrelated systems into a single recurring script.&lt;br /&gt;
&lt;br /&gt;
== Other Uses ==&lt;br /&gt;
&lt;br /&gt;
Quick applications include:&lt;br /&gt;
&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Encounter resolution&amp;#039;&amp;#039;&amp;#039; - Confirm wave completion, release exits, choose the next phase, or reconcile multi-part battle state after entity updates.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Objectives&amp;#039;&amp;#039;&amp;#039; - Evaluate escorts, survival conditions, collectibles, simultaneous targets, or optional challenges using the cycle&amp;#039;s resulting state.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Custom presentation&amp;#039;&amp;#039;&amp;#039; - Queue messages, overlays, flashes, letterboxing, subscreens, weather effects, lighting treatments, or cinematic elements for the current screen update.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Environment coordination&amp;#039;&amp;#039;&amp;#039; - Capture resulting camera, scrolling, hazard, palette, or stage state for presentation and subsequent logic.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Multiplayer reconciliation&amp;#039;&amp;#039;&amp;#039; - Evaluate the complete participating-player state after movement, damage, defeat, joining, or other simulation work.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Transition preparation&amp;#039;&amp;#039;&amp;#039; - Set values consumed at the start of the next cycle, request a new phase, or coordinate a clean handoff between systems.&lt;br /&gt;
* &amp;#039;&amp;#039;&amp;#039;Development tools&amp;#039;&amp;#039;&amp;#039; - Display current state, verify entity counts, inspect timing, expose camera values, or append level-specific diagnostics.&lt;br /&gt;
&lt;br /&gt;
== Related Scripts ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Script&lt;br /&gt;
! Relationship&lt;br /&gt;
|-&lt;br /&gt;
| [[Update|update.c]]&lt;br /&gt;
| Global early-cycle hook that executes before the level&amp;#039;s &amp;lt;code&amp;gt;updatescript&amp;lt;/code&amp;gt;.&lt;br /&gt;
|-&lt;br /&gt;
| [[Updatescript (Level)|updatescript]]&lt;br /&gt;
| Level-specific early-cycle hook that executes before key events and simulation.&lt;br /&gt;
|-&lt;br /&gt;
| [[Updated|updated.c]]&lt;br /&gt;
| Global late-cycle hook that executes before the level&amp;#039;s &amp;lt;code&amp;gt;updatedscript&amp;lt;/code&amp;gt;.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;#039;&amp;#039;&amp;#039;updatedscript&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
| Level-specific late-cycle hook that executes after global &amp;lt;code&amp;gt;updated.c&amp;lt;/code&amp;gt; and before display-queue drawing.&lt;br /&gt;
|-&lt;br /&gt;
| [[Updateentityscript|updateentityscript]]&lt;br /&gt;
| Recurring model hook executed as part of entity simulation.&lt;br /&gt;
|-&lt;br /&gt;
| [[Levelscript|levelscript]]&lt;br /&gt;
| One-time level-start hook used to establish initial state before recurring updates begin.&lt;br /&gt;
|-&lt;br /&gt;
| [[Endlevelscript|endlevelscript]]&lt;br /&gt;
| One-time level-end hook used to finalize state after recurring updates stop.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[Updated]]&lt;br /&gt;
* [[Updatescript (Level)]]&lt;br /&gt;
* [[Update]]&lt;br /&gt;
* [[Updateentityscript]]&lt;br /&gt;
* [[Levelscript]]&lt;br /&gt;
* [[Endlevelscript]]&lt;br /&gt;
* [[Drawing Functions]]&lt;br /&gt;
* [[Time]]&lt;br /&gt;
* [[Script Overview]]&lt;/div&gt;</summary>
		<author><name>Dcurrent</name></author>
	</entry>
</feed>