<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://community.bistudio.com/wiki?action=history&amp;feed=atom&amp;title=Arma_Reforger%3AScripting_First_Steps</id>
	<title>Arma Reforger:Scripting First Steps - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://community.bistudio.com/wiki?action=history&amp;feed=atom&amp;title=Arma_Reforger%3AScripting_First_Steps"/>
	<link rel="alternate" type="text/html" href="https://community.bistudio.com/wiki?title=Arma_Reforger:Scripting_First_Steps&amp;action=history"/>
	<updated>2026-05-23T14:38:55Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.0</generator>
	<entry>
		<id>https://community.bistudio.com/wiki?title=Arma_Reforger:Scripting_First_Steps&amp;diff=376784&amp;oldid=prev</id>
		<title>Lou Montana: Some wiki formatting</title>
		<link rel="alternate" type="text/html" href="https://community.bistudio.com/wiki?title=Arma_Reforger:Scripting_First_Steps&amp;diff=376784&amp;oldid=prev"/>
		<updated>2025-11-18T17:40:30Z</updated>

		<summary type="html">&lt;p&gt;Some wiki formatting&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 19:40, 18 November 2025&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-l43&quot;&gt;Line 43:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 43:&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;br/&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br/&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;−&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Basic &lt;del style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Math &lt;/del&gt;==&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;{{Feature|important|&lt;/ins&gt;&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;A percent sign is printed without issue using &amp;lt;enforce inline methods=&amp;quot;Print&amp;quot;&amp;gt;Print&amp;lt;/enforce&amp;gt;, however it requires to be doubled with &amp;lt;enforce inline methods=&amp;quot;PrintFormat&amp;quot;&amp;gt;PrintFormat&amp;lt;/enforce&amp;gt;, being a special character to this function:&lt;/ins&gt;&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;&amp;lt;enforce&amp;gt;&lt;/ins&gt;&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;Print(&amp;quot;5%&amp;quot;);			// prints &amp;quot;5%&amp;quot;&lt;/ins&gt;&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;Print(&amp;quot;%%&amp;quot;);			// prints &amp;quot;%%&amp;quot;&lt;/ins&gt;&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;/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;PrintFormat(&amp;quot;%1&amp;quot;, 5);	// prints &amp;quot;5&amp;quot;&lt;/ins&gt;&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;PrintFormat(&amp;quot;5%&amp;quot;);		// prints &amp;quot;5&amp;quot;&lt;/ins&gt;&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;PrintFormat(&amp;quot;5%%&amp;quot;);		// prints &amp;quot;5%&amp;quot;&lt;/ins&gt;&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;PrintFormat(&amp;quot;%1%%&amp;quot;, 5);	// prints &amp;quot;5%&amp;quot;&lt;/ins&gt;&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;&amp;lt;/enforce&amp;gt;&lt;/ins&gt;&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;}}&lt;/ins&gt;&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;/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;/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;== Basic &lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;Maths &lt;/ins&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;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;Try these commands one by one in the Remote Console:&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;Try these commands one by one in the Remote Console:&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Lou Montana</name></author>
	</entry>
	<entry>
		<id>https://community.bistudio.com/wiki?title=Arma_Reforger:Scripting_First_Steps&amp;diff=376779&amp;oldid=prev</id>
		<title>Lou Montana: Some wiki formatting</title>
		<link rel="alternate" type="text/html" href="https://community.bistudio.com/wiki?title=Arma_Reforger:Scripting_First_Steps&amp;diff=376779&amp;oldid=prev"/>
		<updated>2025-11-17T23:21:35Z</updated>

		<summary type="html">&lt;p&gt;Some wiki formatting&lt;/p&gt;
&lt;a href=&quot;https://community.bistudio.com/wiki?title=Arma_Reforger:Scripting_First_Steps&amp;amp;diff=376779&amp;amp;oldid=376758&quot;&gt;Show changes&lt;/a&gt;</summary>
		<author><name>Lou Montana</name></author>
	</entry>
	<entry>
		<id>https://community.bistudio.com/wiki?title=Arma_Reforger:Scripting_First_Steps&amp;diff=376758&amp;oldid=prev</id>
		<title>Tanin69: Page creation</title>
		<link rel="alternate" type="text/html" href="https://community.bistudio.com/wiki?title=Arma_Reforger:Scripting_First_Steps&amp;diff=376758&amp;oldid=prev"/>
		<updated>2025-11-16T15:34:14Z</updated>

		<summary type="html">&lt;p&gt;Page creation&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;Welcome to Enforce Script! This guide will get you writing and testing your '''first lines of code in 5 minutes'''.&lt;br /&gt;
&lt;br /&gt;
{{Feature|informative|This is a hands-on quick start. Skip the theory, start coding immediately!}}&lt;br /&gt;
&lt;br /&gt;
== What You Need ==&lt;br /&gt;
&lt;br /&gt;
* '''Arma Reforger Tools''' (Enfusion Workbench) installed via Steam&lt;br /&gt;
* That's it!&lt;br /&gt;
&lt;br /&gt;
== Step 1: Open Workbench and Remote Console ==&lt;br /&gt;
&lt;br /&gt;
# Launch '''Enfusion Workbench''' from Steam (Arma Reforger Tools)&lt;br /&gt;
# Click on the '''Script Editor''' icon or select it from the menu&lt;br /&gt;
&lt;br /&gt;
[[File:WE_UI.png|thumb|right|500px|Launch Script Editor from Workbench]]&lt;br /&gt;
&lt;br /&gt;
# If the '''Remote Console''' window is not visible, open it from the menu&lt;br /&gt;
# Click on the '''Remote Console''' and '''Output''' tabs at the bottom to switch to the appropriate view&lt;br /&gt;
&lt;br /&gt;
[[File:SE_UI_Default.png|thumb|right|500px|Script Editor default UI - click the tabs at the bottom]]&lt;br /&gt;
&lt;br /&gt;
[[File:SE UI RC and output.png|thumb|right|500px|Script Editor with Remote Console and Output panels visible]]&lt;br /&gt;
&lt;br /&gt;
# You're ready to start coding!&lt;br /&gt;
&lt;br /&gt;
{{Feature|informative|For these basic exercises, you don't need to load a world or run the game. The Remote Console can execute simple code directly.}}&lt;br /&gt;
&lt;br /&gt;
== Step 2: Your First Line of Code ==&lt;br /&gt;
&lt;br /&gt;
Type this in the '''Remote Console''' and click the '''Run''' button at the top of the remote console panel:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;enforce&amp;gt;&lt;br /&gt;
Print(&amp;quot;Hello Arma Reforger!&amp;quot;);&lt;br /&gt;
&amp;lt;/enforce&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''You did it!''' You just wrote your first Enforce Script code. The text appears in the console output.&lt;br /&gt;
&lt;br /&gt;
== Step 3: Basic Math ==&lt;br /&gt;
&lt;br /&gt;
Try these commands one by one in the Remote Console:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;enforce&amp;gt;&lt;br /&gt;
Print(10 + 5);&lt;br /&gt;
Print(20 * 3);&lt;br /&gt;
Print(100 / 4);&lt;br /&gt;
&amp;lt;/enforce&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The console shows: &amp;lt;code&amp;gt;15&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;60&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;25&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Step 4: Variables (Storing Values) ==&lt;br /&gt;
&lt;br /&gt;
Variables let you store and reuse values:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;enforce&amp;gt;&lt;br /&gt;
int myAge = 25;&lt;br /&gt;
Print(&amp;quot;I am &amp;quot; + myAge + &amp;quot; years old&amp;quot;);&lt;br /&gt;
&amp;lt;/enforce&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Try changing the number and run it again!&lt;br /&gt;
&lt;br /&gt;
'''Common variable types:'''&lt;br /&gt;
* &amp;lt;enforce inline&amp;gt;int&amp;lt;/enforce&amp;gt; - whole numbers (1, 42, -5)&lt;br /&gt;
* &amp;lt;enforce inline&amp;gt;float&amp;lt;/enforce&amp;gt; - decimal numbers (3.14, 10.5)&lt;br /&gt;
* &amp;lt;enforce inline&amp;gt;string&amp;lt;/enforce&amp;gt; - text (&amp;quot;Hello&amp;quot;, &amp;quot;Arma&amp;quot;)&lt;br /&gt;
* &amp;lt;enforce inline&amp;gt;bool&amp;lt;/enforce&amp;gt; - true or false&lt;br /&gt;
&lt;br /&gt;
{{Feature|informative|For a complete list of all data types, see {{Link|Arma Reforger:Scripting: Values|Scripting Values}}.}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;enforce&amp;gt;&lt;br /&gt;
float distance = 150.5;&lt;br /&gt;
string playerName = &amp;quot;Soldier&amp;quot;;&lt;br /&gt;
bool isAlive = true;&lt;br /&gt;
&lt;br /&gt;
Print(playerName + &amp;quot; is at &amp;quot; + distance + &amp;quot;m&amp;quot;);&lt;br /&gt;
&amp;lt;/enforce&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Step 5: Making Decisions (if/else) ==&lt;br /&gt;
&lt;br /&gt;
&amp;lt;enforce&amp;gt;&lt;br /&gt;
int health = 75;&lt;br /&gt;
&lt;br /&gt;
if (health &amp;gt; 50)&lt;br /&gt;
{&lt;br /&gt;
	Print(&amp;quot;Healthy!&amp;quot;);&lt;br /&gt;
}&lt;br /&gt;
else&lt;br /&gt;
{&lt;br /&gt;
	Print(&amp;quot;Need medical attention&amp;quot;);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/enforce&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Try changing &amp;lt;code&amp;gt;health&amp;lt;/code&amp;gt; to different numbers!&lt;br /&gt;
&lt;br /&gt;
== Step 6: Arrays (Lists) ==&lt;br /&gt;
&lt;br /&gt;
Arrays store multiple values:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;enforce&amp;gt;&lt;br /&gt;
array&amp;lt;string&amp;gt; soldiers = {&amp;quot;Alpha&amp;quot;, &amp;quot;Bravo&amp;quot;, &amp;quot;Charlie&amp;quot;};&lt;br /&gt;
&lt;br /&gt;
Print(soldiers[0]);  // Prints &amp;quot;Alpha&amp;quot;&lt;br /&gt;
Print(soldiers[1]);  // Prints &amp;quot;Bravo&amp;quot;&lt;br /&gt;
&lt;br /&gt;
soldiers.Insert(&amp;quot;Delta&amp;quot;);&lt;br /&gt;
Print(&amp;quot;Squad size: &amp;quot; + soldiers.Count());&lt;br /&gt;
&amp;lt;/enforce&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Step 6: Loops (Repeat Actions) ==&lt;br /&gt;
&lt;br /&gt;
'''For loop''' - repeat a specific number of times:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;enforce&amp;gt;&lt;br /&gt;
for (int i = 0; i &amp;lt; 5; i++)&lt;br /&gt;
{&lt;br /&gt;
	Print(&amp;quot;Count: &amp;quot; + i);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/enforce&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Foreach loop''' - go through each item in an array:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;enforce&amp;gt;&lt;br /&gt;
array&amp;lt;string&amp;gt; weapons = {&amp;quot;Rifle&amp;quot;, &amp;quot;Pistol&amp;quot;, &amp;quot;Grenade&amp;quot;};&lt;br /&gt;
&lt;br /&gt;
foreach (string weapon : weapons)&lt;br /&gt;
{&lt;br /&gt;
	Print(&amp;quot;Weapon: &amp;quot; + weapon);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/enforce&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Your First Mini-Program ==&lt;br /&gt;
&lt;br /&gt;
Combine what you learned! Copy this entire block and run it:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;enforce&amp;gt;&lt;br /&gt;
// Soldier health checker&lt;br /&gt;
array&amp;lt;string&amp;gt; squad = {&amp;quot;Alpha&amp;quot;, &amp;quot;Bravo&amp;quot;, &amp;quot;Charlie&amp;quot;, &amp;quot;Delta&amp;quot;};&lt;br /&gt;
array&amp;lt;int&amp;gt; healthValues = {100, 45, 80, 20};&lt;br /&gt;
&lt;br /&gt;
Print(&amp;quot;=== Squad Status Report ===&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
for (int i = 0; i &amp;lt; squad.Count(); i++)&lt;br /&gt;
{&lt;br /&gt;
	string soldierName = squad[i];&lt;br /&gt;
	int health = healthValues[i];&lt;br /&gt;
	&lt;br /&gt;
	if (health &amp;gt; 70)&lt;br /&gt;
	{&lt;br /&gt;
		Print(soldierName + &amp;quot;: Healthy (&amp;quot; + health + &amp;quot;%)&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
	else if (health &amp;gt; 30)&lt;br /&gt;
	{&lt;br /&gt;
		Print(soldierName + &amp;quot;: Injured (&amp;quot; + health + &amp;quot;%)&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
	else&lt;br /&gt;
	{&lt;br /&gt;
		Print(soldierName + &amp;quot;: Critical! (&amp;quot; + health + &amp;quot;%)&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
Print(&amp;quot;=== End of Report ===&amp;quot;);&lt;br /&gt;
&amp;lt;/enforce&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Feature|informative|Lines starting with &amp;lt;enforce inline&amp;gt;//'''&amp;lt;/enforce&amp;gt; are '''comments''' - they're ignored by the code but help explain what's happening.}}&lt;br /&gt;
&lt;br /&gt;
== Quick Reference Card ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Category !! Code !! What it does&lt;br /&gt;
|-&lt;br /&gt;
| '''Output''' || &amp;lt;enforce inline&amp;gt;Print(&amp;quot;text&amp;quot;);&amp;lt;/enforce&amp;gt; || Shows text in console&lt;br /&gt;
|-&lt;br /&gt;
| '''Variables''' || &amp;lt;enforce inline&amp;gt;int number = 42;&amp;lt;/enforce&amp;gt; || Stores a whole number&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;float decimal = 3.14;&amp;lt;/enforce&amp;gt; || Stores a decimal number&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;string text = &amp;quot;Hi&amp;quot;;&amp;lt;/enforce&amp;gt; || Stores text&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;bool flag = true;&amp;lt;/enforce&amp;gt; || Stores true/false&lt;br /&gt;
|-&lt;br /&gt;
| '''Arrays''' || &amp;lt;enforce inline&amp;gt;array&amp;lt;int&amp;gt; numbers = {1, 2, 3};&amp;lt;/enforce&amp;gt; || Creates a list&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;myArray.Insert(value);&amp;lt;/enforce&amp;gt; || Adds item to list&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;myArray.Count();&amp;lt;/enforce&amp;gt; || Gets list size&lt;br /&gt;
|-&lt;br /&gt;
| '''If/Else''' || &amp;lt;enforce inline&amp;gt;if (condition) { }&amp;lt;/enforce&amp;gt; || Do something if true&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;else { }&amp;lt;/enforce&amp;gt; || Do something if false&lt;br /&gt;
|-&lt;br /&gt;
| '''Loops''' || &amp;lt;enforce inline&amp;gt;for (int i = 0; i &amp;lt; 10; i++) { }&amp;lt;/enforce&amp;gt; || Repeat 10 times&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;foreach (item : array) { }&amp;lt;/enforce&amp;gt; || Repeat for each item&lt;br /&gt;
|-&lt;br /&gt;
| '''Math''' || &amp;lt;enforce inline&amp;gt;+&amp;lt;/enforce&amp;gt; || Add&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;-&amp;lt;/enforce&amp;gt; || Subtract&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;*&amp;lt;/enforce&amp;gt; || Multiply&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;/&amp;lt;/enforce&amp;gt; || Divide&lt;br /&gt;
|-&lt;br /&gt;
| '''Compare''' || &amp;lt;enforce inline&amp;gt;==&amp;lt;/enforce&amp;gt; || Equal to&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;!=&amp;lt;/enforce&amp;gt; || Not equal to&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;&amp;gt;&amp;lt;/enforce&amp;gt; || Greater than&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;&amp;lt;&amp;lt;/enforce&amp;gt; || Less than&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;&amp;gt;=&amp;lt;/enforce&amp;gt; || Greater or equal&lt;br /&gt;
|-&lt;br /&gt;
| || &amp;lt;enforce inline&amp;gt;&amp;lt;=&amp;lt;/enforce&amp;gt; || Less or equal&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Common Mistakes to Avoid ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! ❌ Wrong !! ✅ Correct !! Why&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;enforce inline&amp;gt;print(&amp;quot;hello&amp;quot;)&amp;lt;/enforce&amp;gt;&lt;br /&gt;
| &amp;lt;enforce inline&amp;gt;Print(&amp;quot;hello&amp;quot;)&amp;lt;/enforce&amp;gt;&lt;br /&gt;
| Capital P in Print&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;enforce inline&amp;gt;int x = 5&amp;lt;/enforce&amp;gt;&lt;br /&gt;
| &amp;lt;enforce inline&amp;gt;int x = 5;&amp;lt;/enforce&amp;gt;&lt;br /&gt;
| Missing semicolon&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;enforce inline&amp;gt;if (x = 5)&amp;lt;/enforce&amp;gt;&lt;br /&gt;
| &amp;lt;enforce inline&amp;gt;if (x == 5)&amp;lt;/enforce&amp;gt;&lt;br /&gt;
| Use == for comparison, = for assignment&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;enforce inline&amp;gt;array[5]&amp;lt;/enforce&amp;gt; on 5-item array&lt;br /&gt;
| &amp;lt;enforce inline&amp;gt;array[4]&amp;lt;/enforce&amp;gt;&lt;br /&gt;
| Arrays start at 0, not 1&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;enforce inline&amp;gt;string name = John&amp;lt;/enforce&amp;gt;&lt;br /&gt;
| &amp;lt;enforce inline&amp;gt;string name = &amp;quot;John&amp;quot;&amp;lt;/enforce&amp;gt;&lt;br /&gt;
| Text needs quotes&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{{Feature|informative|Follow professional coding standards: {{Link|Arma Reforger:Scripting: Conventions|Scripting Conventions}}.}}&lt;br /&gt;
&lt;br /&gt;
== Practice Exercises ==&lt;br /&gt;
&lt;br /&gt;
Try these challenges on your own:&lt;br /&gt;
&lt;br /&gt;
'''Exercise 1: Temperature Converter'''&lt;br /&gt;
Create a program that converts 25°C to Fahrenheit.&lt;br /&gt;
&amp;lt;spoiler text=&amp;quot;Show solution&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;enforce&amp;gt;&lt;br /&gt;
// Convert Celsius to Fahrenheit&lt;br /&gt;
float celsius = 25;&lt;br /&gt;
float fahrenheit = (celsius * 9 / 5) + 32;&lt;br /&gt;
Print(celsius + &amp;quot;°C = &amp;quot; + fahrenheit + &amp;quot;°F&amp;quot;);&lt;br /&gt;
&amp;lt;/enforce&amp;gt;&lt;br /&gt;
&amp;lt;/spoiler&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Exercise 2: Countdown'''&lt;br /&gt;
Create a countdown from 10 to 0, then print &amp;quot;Launch!&amp;quot;.&lt;br /&gt;
&amp;lt;spoiler text=&amp;quot;Show solution&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;enforce&amp;gt;&lt;br /&gt;
// Count down from 10 to 0&lt;br /&gt;
for (int i = 10; i &amp;gt;= 0; i--)&lt;br /&gt;
{&lt;br /&gt;
	Print(i);&lt;br /&gt;
}&lt;br /&gt;
Print(&amp;quot;Launch!&amp;quot;);&lt;br /&gt;
&amp;lt;/enforce&amp;gt;&lt;br /&gt;
&amp;lt;/spoiler&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Exercise 3: Squad Filter'''&lt;br /&gt;
Print only the soldiers with health above 50 from two arrays (names and health values).&lt;br /&gt;
&amp;lt;spoiler text=&amp;quot;Show solution&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;enforce&amp;gt;&lt;br /&gt;
// Only print soldiers with health above 50&lt;br /&gt;
array&amp;lt;string&amp;gt; names = {&amp;quot;Alpha&amp;quot;, &amp;quot;Bravo&amp;quot;, &amp;quot;Charlie&amp;quot;};&lt;br /&gt;
array&amp;lt;int&amp;gt; health = {80, 30, 90};&lt;br /&gt;
&lt;br /&gt;
for (int i = 0; i &amp;lt; names.Count(); i++)&lt;br /&gt;
{&lt;br /&gt;
	if (health[i] &amp;gt; 50)&lt;br /&gt;
	{&lt;br /&gt;
		Print(names[i] + &amp;quot; is combat ready&amp;quot;);&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/enforce&amp;gt;&lt;br /&gt;
&amp;lt;/spoiler&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Troubleshooting ==&lt;br /&gt;
&lt;br /&gt;
'''Console won't open?'''&lt;br /&gt;
* Make sure you've opened the '''Script Editor''' in Workbench&lt;br /&gt;
* Look for the '''Remote Console''' panel - if hidden, open it from the menu&lt;br /&gt;
* Ensure Workbench is properly installed via Steam (Arma Reforger Tools)&lt;br /&gt;
&lt;br /&gt;
'''Code doesn't work?'''&lt;br /&gt;
* Check for missing semicolons &amp;lt;enforce inline&amp;gt;;&amp;lt;/enforce&amp;gt;&lt;br /&gt;
* Make sure quotes match: &amp;lt;enforce inline&amp;gt;&amp;quot;text&amp;quot;&amp;lt;/enforce&amp;gt;&lt;br /&gt;
* Check spelling and capitalization (it matters!)&lt;br /&gt;
* Look for error messages in red&lt;br /&gt;
&lt;br /&gt;
'''Getting errors?'''&lt;br /&gt;
* Read the error message - it often tells you what's wrong&lt;br /&gt;
* Check line numbers&lt;br /&gt;
* Make sure all brackets &amp;lt;enforce inline&amp;gt;{ }&amp;lt;/enforce&amp;gt; are balanced&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
'''Reference Documentation:'''&lt;br /&gt;
* {{Link|Arma Reforger:Scripting: Values|Scripting Values}} - All data types in detail&lt;br /&gt;
* {{Link|Arma Reforger:Scripting: Conventions|Scripting Conventions}} - Bohemia Interactive coding standards&lt;br /&gt;
* {{Link|Arma Reforger:Object Oriented Programming Basics|OOP Basics}} - Object-oriented programming fundamentals&lt;br /&gt;
&lt;br /&gt;
{{GameCategory|armaR|Modding|Scripting|Tutorials}}&lt;/div&gt;</summary>
		<author><name>Tanin69</name></author>
	</entry>
</feed>