<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://temp.ufopaedia.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Deldonut1</id>
	<title>UFOpaedia - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://temp.ufopaedia.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Deldonut1"/>
	<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/Special:Contributions/Deldonut1"/>
	<updated>2026-05-01T09:45:14Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.6</generator>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Installing_(OpenApoc)&amp;diff=126346</id>
		<title>Installing (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Installing_(OpenApoc)&amp;diff=126346"/>
		<updated>2026-03-01T23:32:12Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Major rewrite: updated installation steps for current releases; added GOG and Steam instructions; added troubleshooting&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;Installing (OpenApoc)&#039;&#039;&#039; covers how to download, install, and run [https://github.com/OpenApoc/OpenApoc OpenApoc] on Windows, Linux, and macOS. OpenApoc is an open-source reimplementation of [[Apocalypse|X-COM: Apocalypse]] and requires the original game files to play.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; OpenApoc is currently in &#039;&#039;&#039;alpha&#039;&#039;&#039; state. Expect bugs, crashes, and incomplete features. Please report issues on the [https://github.com/OpenApoc/OpenApoc/issues bug tracker].&lt;br /&gt;
&lt;br /&gt;
== System Requirements ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Video card&#039;&#039;&#039;: OpenGL 2.0 compatible&lt;br /&gt;
* &#039;&#039;&#039;Original game files&#039;&#039;&#039;: X-COM: Apocalypse (from [https://store.steampowered.com/app/7660/XCOM_Apocalypse/ Steam], [https://www.gog.com/game/xcom_apocalypse GOG], or the original retail CD)&lt;br /&gt;
* &#039;&#039;&#039;Windows only&#039;&#039;&#039;: Latest [https://docs.microsoft.com/en-US/cpp/windows/latest-supported-vc-redist Visual C++ Redistributable]&lt;br /&gt;
&lt;br /&gt;
=== Supported Platforms ===&lt;br /&gt;
&lt;br /&gt;
* Windows (x64)&lt;br /&gt;
* Linux&lt;br /&gt;
* macOS (including Apple Silicon)&lt;br /&gt;
&lt;br /&gt;
== Downloading OpenApoc ==&lt;br /&gt;
&lt;br /&gt;
=== GitHub Releases (Recommended) ===&lt;br /&gt;
&lt;br /&gt;
The primary download location for OpenApoc is the &#039;&#039;&#039;[https://github.com/OpenApoc/OpenApoc/releases GitHub Releases]&#039;&#039;&#039; page. This provides the latest official Windows builds.&lt;br /&gt;
&lt;br /&gt;
# Visit [https://github.com/OpenApoc/OpenApoc/releases https://github.com/OpenApoc/OpenApoc/releases]&lt;br /&gt;
# Download the appropriate installer or zip package&lt;br /&gt;
# Run the installer and follow the prompts&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; Linux and macOS users must compile from source. See &#039;&#039;&#039;[[Compiling (OpenApoc)]]&#039;&#039;&#039; for instructions.&lt;br /&gt;
&lt;br /&gt;
=== AppVeyor CI Builds (Experimental) ===&lt;br /&gt;
&lt;br /&gt;
For users who want the very latest (and potentially unstable) development builds, experimental Windows x64 builds are available from AppVeyor:&lt;br /&gt;
&lt;br /&gt;
# Visit [https://ci.appveyor.com/project/OpenApoc/openapoc/history https://ci.appveyor.com/project/OpenApoc/openapoc/history]&lt;br /&gt;
# Look for a build with a &#039;&#039;&#039;green&#039;&#039;&#039; bar indicating a successful build (use &amp;quot;Show More&amp;quot; to list additional builds if needed)&lt;br /&gt;
# Click on the green build entry&lt;br /&gt;
# Click &#039;&#039;&#039;ARTIFACTS&#039;&#039;&#039;&lt;br /&gt;
# Download the file ending in &amp;lt;code&amp;gt;.exe&amp;lt;/code&amp;gt; that does &#039;&#039;&#039;not&#039;&#039;&#039; contain &amp;quot;debug&amp;quot; in the filename&lt;br /&gt;
# Run the downloaded installer&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Warning:&#039;&#039;&#039; AppVeyor CI builds are experimental and may contain untested changes. Only Windows x64 builds are available from AppVeyor. For stable releases, use GitHub Releases instead.&lt;br /&gt;
&lt;br /&gt;
== Setting Up Original Game Files ==&lt;br /&gt;
&lt;br /&gt;
OpenApoc requires the original X-COM: Apocalypse game data to run. The game files must include the &#039;&#039;&#039;music tracks&#039;&#039;&#039;; pirated or incomplete disc images that are missing music will cause problems such as crashes and map issues.&lt;br /&gt;
&lt;br /&gt;
=== Steam ===&lt;br /&gt;
&lt;br /&gt;
# Locate your Steam installation of X-COM: Apocalypse&lt;br /&gt;
#* The default path is typically: &amp;lt;code&amp;gt;C:\Program Files (x86)\Steam\steamapps\common\X-COM Apocalypse&amp;lt;/code&amp;gt;&lt;br /&gt;
# Find the &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt; file in the Steam installation directory&lt;br /&gt;
# Copy &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt; into the OpenApoc &amp;lt;code&amp;gt;data&amp;lt;/code&amp;gt; folder&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; On Linux, the Steam version of X-COM: Apocalypse will only install if &#039;&#039;&#039;Steam Play&#039;&#039;&#039; (Proton) is enabled.&lt;br /&gt;
&lt;br /&gt;
=== GOG ===&lt;br /&gt;
&lt;br /&gt;
The GOG version provides the game data as &amp;lt;code&amp;gt;.cue&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;.bin&amp;lt;/code&amp;gt; files. These require a specific setup:&lt;br /&gt;
&lt;br /&gt;
# Locate the GOG installation directory for X-COM: Apocalypse&lt;br /&gt;
# Find the &amp;lt;code&amp;gt;XCOM.cue&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;XCOM.BIN&amp;lt;/code&amp;gt; files&lt;br /&gt;
# &#039;&#039;&#039;Rename&#039;&#039;&#039; &amp;lt;code&amp;gt;XCOM.cue&amp;lt;/code&amp;gt; to &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt;&lt;br /&gt;
# Place the renamed &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt; file into the OpenApoc &amp;lt;code&amp;gt;data&amp;lt;/code&amp;gt; folder&lt;br /&gt;
# Place &amp;lt;code&amp;gt;XCOM.BIN&amp;lt;/code&amp;gt; into the OpenApoc &amp;lt;code&amp;gt;data&amp;lt;/code&amp;gt; folder &#039;&#039;&#039;without renaming it&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Both files (&amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;XCOM.BIN&amp;lt;/code&amp;gt;) must be present in the &amp;lt;code&amp;gt;data&amp;lt;/code&amp;gt; folder for the GOG version to work correctly.&lt;br /&gt;
&lt;br /&gt;
=== Original Retail CD ===&lt;br /&gt;
&lt;br /&gt;
# Create an ISO disc image from your original X-COM: Apocalypse CD-ROM&lt;br /&gt;
#* You can use tools such as [https://www.imgburn.com/ ImgBurn] (Windows) or &amp;lt;code&amp;gt;dd&amp;lt;/code&amp;gt; (Linux/macOS) to create the image&lt;br /&gt;
# Rename the resulting image file to &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt;&lt;br /&gt;
# Place &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt; into the OpenApoc &amp;lt;code&amp;gt;data&amp;lt;/code&amp;gt; folder&lt;br /&gt;
&lt;br /&gt;
=== Alternative: Specify Location During Installation ===&lt;br /&gt;
&lt;br /&gt;
If you use the Windows installer, you may specify the location of &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt; during the installation process. In that case, you do not need to manually copy the file into the &amp;lt;code&amp;gt;data&amp;lt;/code&amp;gt; folder.&lt;br /&gt;
&lt;br /&gt;
== Running OpenApoc ==&lt;br /&gt;
&lt;br /&gt;
=== Windows ===&lt;br /&gt;
&lt;br /&gt;
After installation, run OpenApoc from the Start Menu shortcut or from the installation directory. Ensure that:&lt;br /&gt;
&lt;br /&gt;
* The &amp;lt;code&amp;gt;data&amp;lt;/code&amp;gt; folder (containing &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt;) is present in the OpenApoc installation directory (unless you specified a different location during install)&lt;br /&gt;
* The latest [https://docs.microsoft.com/en-US/cpp/windows/latest-supported-vc-redist Visual C++ Redistributable] is installed&lt;br /&gt;
&lt;br /&gt;
=== Linux ===&lt;br /&gt;
&lt;br /&gt;
Linux does not have prebuilt packages; you must compile from source (see &#039;&#039;&#039;[[Compiling (OpenApoc)]]&#039;&#039;&#039;). After building, run the executable from the repository root so that it can find the &amp;lt;code&amp;gt;data&amp;lt;/code&amp;gt; folder:&lt;br /&gt;
&lt;br /&gt;
 ./build/bin/OpenApoc&lt;br /&gt;
&lt;br /&gt;
=== macOS ===&lt;br /&gt;
&lt;br /&gt;
macOS does not have prebuilt packages; you must compile from source (see &#039;&#039;&#039;[[Compiling (OpenApoc)]]&#039;&#039;&#039;). After building, run the application from the repository root:&lt;br /&gt;
&lt;br /&gt;
 open ./build/bin/OpenApoc.app&lt;br /&gt;
&lt;br /&gt;
== Portable Installation ==&lt;br /&gt;
&lt;br /&gt;
The Windows installer offers a &#039;&#039;&#039;portable install&#039;&#039;&#039; option. When selected, all save games and configuration settings are stored within the installation directory rather than in your user profile. This is useful if you want to:&lt;br /&gt;
&lt;br /&gt;
* Run OpenApoc from a USB drive or external storage&lt;br /&gt;
* Keep multiple independent installations with separate settings&lt;br /&gt;
* Easily back up or move your entire OpenApoc setup including saves&lt;br /&gt;
&lt;br /&gt;
To use portable mode, select the &amp;quot;portable install&amp;quot; option when running the installer.&lt;br /&gt;
&lt;br /&gt;
== Post-Installation Configuration ==&lt;br /&gt;
&lt;br /&gt;
OpenApoc stores its settings in a file named &amp;lt;code&amp;gt;OpenApoc_settings.conf&amp;lt;/code&amp;gt;. For portable installations, this file is located in the installation directory. For standard installations, it is located in your user profile directory.&lt;br /&gt;
&lt;br /&gt;
You can create or edit this file to configure common settings. Below are some useful options.&lt;br /&gt;
&lt;br /&gt;
=== Changing Language to English ===&lt;br /&gt;
&lt;br /&gt;
If OpenApoc displays blank buttons or garbled text because your system language is not English, you can force English by adding the following to &amp;lt;code&amp;gt;OpenApoc_settings.conf&amp;lt;/code&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[Framework]&lt;br /&gt;
Language=en_GB.UTF-8&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Restart OpenApoc after saving the file.&lt;br /&gt;
&lt;br /&gt;
=== Fullscreen Mode ===&lt;br /&gt;
&lt;br /&gt;
To run OpenApoc in fullscreen at a specific resolution, add the following to &amp;lt;code&amp;gt;OpenApoc_settings.conf&amp;lt;/code&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[Framework.Screen]&lt;br /&gt;
Width=1920&lt;br /&gt;
Height=1080&lt;br /&gt;
Fullscreen=1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Adjust the &amp;lt;code&amp;gt;Width&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;Height&amp;lt;/code&amp;gt; values to match your monitor&#039;s resolution.&lt;br /&gt;
&lt;br /&gt;
=== Skipping the Intro Movie ===&lt;br /&gt;
&lt;br /&gt;
To skip the intro movie on startup, add the following to &amp;lt;code&amp;gt;OpenApoc_settings.conf&amp;lt;/code&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[Game]&lt;br /&gt;
SkipIntro=1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Updating OpenApoc ==&lt;br /&gt;
&lt;br /&gt;
When updating to a newer version of OpenApoc, it is recommended to install to a &#039;&#039;&#039;new folder&#039;&#039;&#039; rather than overwriting the existing installation. In-place updates may cause issues. After verifying that the new version works correctly, you can delete the old installation folder.&lt;br /&gt;
&lt;br /&gt;
Your save games and settings will be preserved if you are using a standard (non-portable) installation, since they are stored in your user profile directory.&lt;br /&gt;
&lt;br /&gt;
== Troubleshooting ==&lt;br /&gt;
&lt;br /&gt;
=== Blank Buttons in the Interface ===&lt;br /&gt;
&lt;br /&gt;
This is a known issue that can occur when your system&#039;s native language is not English. OpenApoc has translations in multiple languages, but not all fonts are available yet. To fix this:&lt;br /&gt;
&lt;br /&gt;
* Set the language to English using the &amp;lt;code&amp;gt;OpenApoc_settings.conf&amp;lt;/code&amp;gt; file as described in the [[#Changing Language to English|Post-Installation Configuration]] section above&lt;br /&gt;
* Check the [https://github.com/OpenApoc/OpenApoc/issues bug tracker] for the latest status of this issue&lt;br /&gt;
&lt;br /&gt;
=== Crashes or Map Problems ===&lt;br /&gt;
&lt;br /&gt;
If you experience crashes at startup or broken maps during gameplay:&lt;br /&gt;
&lt;br /&gt;
* Verify that your &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt; is a complete copy of the original game including all music tracks&lt;br /&gt;
* Incomplete or pirated disc images that are missing music are known to cause these issues&lt;br /&gt;
* Re-acquire the game files from a legitimate source (Steam, GOG, or original CD)&lt;br /&gt;
&lt;br /&gt;
=== GOG Version Not Working ===&lt;br /&gt;
&lt;br /&gt;
If the GOG version does not load correctly:&lt;br /&gt;
&lt;br /&gt;
* Ensure you have &#039;&#039;&#039;both&#039;&#039;&#039; &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt; (the renamed &amp;lt;code&amp;gt;XCOM.cue&amp;lt;/code&amp;gt;) and &amp;lt;code&amp;gt;XCOM.BIN&amp;lt;/code&amp;gt; in the &amp;lt;code&amp;gt;data&amp;lt;/code&amp;gt; folder&lt;br /&gt;
* Ensure &amp;lt;code&amp;gt;XCOM.BIN&amp;lt;/code&amp;gt; has &#039;&#039;&#039;not&#039;&#039;&#039; been renamed&lt;br /&gt;
&lt;br /&gt;
=== Missing Visual C++ Runtime (Windows) ===&lt;br /&gt;
&lt;br /&gt;
If OpenApoc fails to start on Windows with errors about missing DLLs:&lt;br /&gt;
&lt;br /&gt;
* Download and install the latest [https://docs.microsoft.com/en-US/cpp/windows/latest-supported-vc-redist Visual C++ Redistributable] from Microsoft&lt;br /&gt;
&lt;br /&gt;
=== Getting Help ===&lt;br /&gt;
&lt;br /&gt;
If you encounter issues not covered here:&lt;br /&gt;
&lt;br /&gt;
* Search the [https://github.com/OpenApoc/OpenApoc/issues bug tracker] for known issues&lt;br /&gt;
* Join the [https://discord.gg/f8Rayre OpenApoc Discord] server, which is the most active community hub for support and discussion&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[Compiling (OpenApoc)]] - Building OpenApoc from source code&lt;br /&gt;
* [[Controls (OpenApoc)]] - Keyboard and mouse controls&lt;br /&gt;
* [[Coding Style (OpenApoc)]] - Development coding standards&lt;br /&gt;
* [[Differences to X-COM (OpenApoc)]] - How OpenApoc differs from the original game&lt;br /&gt;
* [[Credits (OpenApoc)]] - Project contributors&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc OpenApoc on GitHub] - Source code repository&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Modding_(OpenApoc)&amp;diff=126345</id>
		<title>Modding (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Modding_(OpenApoc)&amp;diff=126345"/>
		<updated>2026-03-01T23:21:22Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: New page: comprehensive modding guide covering XML data patching, Lua scripting API, mod loading system, save editing, and community resources&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{DISPLAYTITLE:Modding (OpenApoc)}}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Modding&#039;&#039;&#039; is a core design goal of [[OpenApoc]]. Nearly every aspect of the game &amp;amp;mdash; weapons, vehicles, organisations, research, maps, difficulty settings, economy, and more &amp;amp;mdash; is defined in human-readable XML data files that can be overridden or extended by mods. OpenApoc also includes a &#039;&#039;&#039;Lua scripting&#039;&#039;&#039; system that allows mods to hook into game events and alter game logic at runtime.&lt;br /&gt;
&lt;br /&gt;
This page covers the mod system architecture, the data file format, savegame editing, Lua scripting, configurable mod options, and how to create your own mods.&lt;br /&gt;
&lt;br /&gt;
== Mod System Overview ==&lt;br /&gt;
&lt;br /&gt;
OpenApoc loads game data in layers. The base game data is extracted from the original X-COM: Apocalypse CD image, then OpenApoc&#039;s own data patches are applied on top, and finally any enabled mods are loaded in order. Each layer can add new data or override existing values from previous layers.&lt;br /&gt;
&lt;br /&gt;
=== How Mods Are Loaded ===&lt;br /&gt;
&lt;br /&gt;
Mod loading is controlled by two configuration options (found in &amp;lt;code&amp;gt;settings.cfg&amp;lt;/code&amp;gt; or set via the launcher):&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;&amp;lt;code&amp;gt;Game.Mods&amp;lt;/code&amp;gt;&#039;&#039;&#039; &amp;amp;mdash; A colon-separated list of mod directory names to load (relative to the mod directory). Default: &amp;lt;code&amp;gt;base&amp;lt;/code&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;&amp;lt;code&amp;gt;Game.ModPath&amp;lt;/code&amp;gt;&#039;&#039;&#039; &amp;amp;mdash; The directory containing all mods. Default: &amp;lt;code&amp;gt;./data/mods&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When the game starts, it iterates through the mod list in order. For each mod it:&lt;br /&gt;
&lt;br /&gt;
# Reads &amp;lt;code&amp;gt;modinfo.xml&amp;lt;/code&amp;gt; from the mod&#039;s root directory&lt;br /&gt;
# Appends the mod&#039;s &#039;&#039;&#039;data path&#039;&#039;&#039; to the virtual filesystem (making the mod&#039;s resources available and able to override earlier files)&lt;br /&gt;
# Loads the mod&#039;s &#039;&#039;&#039;game state&#039;&#039;&#039; (XML data that gets merged into the running GameState)&lt;br /&gt;
# Loads any &#039;&#039;&#039;language patches&#039;&#039;&#039; applicable to the current locale&lt;br /&gt;
# Executes the mod&#039;s &#039;&#039;&#039;load script&#039;&#039;&#039; (a Lua script run when the mod is first loaded)&lt;br /&gt;
&lt;br /&gt;
Because mods are loaded in the order specified, later mods override earlier ones. The &amp;lt;code&amp;gt;base&amp;lt;/code&amp;gt; mod is the foundation and should generally always be listed first.&lt;br /&gt;
&lt;br /&gt;
=== The Launcher ===&lt;br /&gt;
&lt;br /&gt;
The OpenApoc Launcher (a Qt-based GUI) includes a &#039;&#039;&#039;Mods&#039;&#039;&#039; tab that lets you enable and disable mods without manually editing configuration files. It scans the &amp;lt;code&amp;gt;data/mods/&amp;lt;/code&amp;gt; directory for subdirectories containing a valid &amp;lt;code&amp;gt;modinfo.xml&amp;lt;/code&amp;gt; and displays them in two lists: enabled mods and disabled mods. You can move mods between the lists and reorder them.&lt;br /&gt;
&lt;br /&gt;
== The modinfo.xml File ==&lt;br /&gt;
&lt;br /&gt;
Every mod must contain a &amp;lt;code&amp;gt;modinfo.xml&amp;lt;/code&amp;gt; file in its root directory. This file describes the mod&#039;s metadata and tells OpenApoc how to load it. Here is the structure, using the base game mod as an example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;openapoc_modinfo&amp;gt;&lt;br /&gt;
    &amp;lt;name&amp;gt;OpenApoc base game&amp;lt;/name&amp;gt;&lt;br /&gt;
    &amp;lt;author&amp;gt;OpenApoc team&amp;lt;/author&amp;gt;&lt;br /&gt;
    &amp;lt;version&amp;gt;0.1&amp;lt;/version&amp;gt;&lt;br /&gt;
    &amp;lt;description&amp;gt;The base OpenApoc game&amp;lt;/description&amp;gt;&lt;br /&gt;
    &amp;lt;link&amp;gt;http://www.openapoc.org&amp;lt;/link&amp;gt;&lt;br /&gt;
    &amp;lt;id&amp;gt;org.openapoc.base&amp;lt;/id&amp;gt;&lt;br /&gt;
    &amp;lt;datapath&amp;gt;data&amp;lt;/datapath&amp;gt;&lt;br /&gt;
    &amp;lt;statepath&amp;gt;base_gamestate&amp;lt;/statepath&amp;gt;&lt;br /&gt;
    &amp;lt;minversion&amp;gt;&amp;lt;/minversion&amp;gt;&lt;br /&gt;
    &amp;lt;modloadscript&amp;gt;scripts/org.openapoc.base/onload.lua&amp;lt;/modloadscript&amp;gt;&lt;br /&gt;
    &amp;lt;requires /&amp;gt;&lt;br /&gt;
    &amp;lt;conflicts /&amp;gt;&lt;br /&gt;
    &amp;lt;languages&amp;gt;&lt;br /&gt;
        &amp;lt;entry&amp;gt;&lt;br /&gt;
            &amp;lt;ID&amp;gt;en.UTF-8&amp;lt;/ID&amp;gt;&lt;br /&gt;
            &amp;lt;patch&amp;gt;&amp;lt;/patch&amp;gt;&lt;br /&gt;
            &amp;lt;data&amp;gt;lang/data/en.UTF-8&amp;lt;/data&amp;gt;&lt;br /&gt;
        &amp;lt;/entry&amp;gt;&lt;br /&gt;
    &amp;lt;/languages&amp;gt;&lt;br /&gt;
&amp;lt;/openapoc_modinfo&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Field Reference ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Field !! Description&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;name&amp;lt;/code&amp;gt; || The human-readable name of the mod, displayed in the launcher.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;author&amp;lt;/code&amp;gt; || The author(s) of the mod.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;version&amp;lt;/code&amp;gt; || A version string (any format; purely informational).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;description&amp;lt;/code&amp;gt; || A short description of what the mod does.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;link&amp;lt;/code&amp;gt; || A URL for the mod&#039;s homepage, forum thread, etc.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;id&amp;lt;/code&amp;gt; || A &#039;&#039;&#039;unique&#039;&#039;&#039; identifier for the mod. Use a reverse-DNS-like format to avoid conflicts, e.g. &amp;lt;code&amp;gt;org.openapoc.mod.YOUR_USERNAME.YOUR_MOD&amp;lt;/code&amp;gt;.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;datapath&amp;lt;/code&amp;gt; || Path (relative to the mod directory) to a folder whose contents are added to the virtual filesystem. Files here can override any game resource (images, sounds, forms, etc.).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;statepath&amp;lt;/code&amp;gt; || Path (relative to the mod directory) to a folder or ZIP archive containing XML game state data to merge into the GameState.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;minversion&amp;lt;/code&amp;gt; || The minimum version of OpenApoc required to run this mod (currently informational).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;modloadscript&amp;lt;/code&amp;gt; || Path to a Lua script that is executed when the mod is loaded (after game state is merged).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;requires&amp;lt;/code&amp;gt; || A list of mod IDs that this mod depends on. Listed as &amp;lt;code&amp;gt;&amp;lt;entry&amp;gt;mod.id&amp;lt;/entry&amp;gt;&amp;lt;/code&amp;gt; elements.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;conflicts&amp;lt;/code&amp;gt; || A list of mod IDs that this mod is incompatible with.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;languages&amp;lt;/code&amp;gt; || Language-specific data and translation patches. Each entry has an &amp;lt;code&amp;gt;ID&amp;lt;/code&amp;gt; (locale), optional &amp;lt;code&amp;gt;patch&amp;lt;/code&amp;gt; (game state overlay for that language), and optional &amp;lt;code&amp;gt;data&amp;lt;/code&amp;gt; (additional data path for that language).&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Data File Structure ==&lt;br /&gt;
&lt;br /&gt;
OpenApoc organises its data in the &amp;lt;code&amp;gt;data/&amp;lt;/code&amp;gt; directory. Understanding this structure is essential for modding.&lt;br /&gt;
&lt;br /&gt;
=== Top-Level Directories ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Directory !! Contents&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/common_patch/&amp;lt;/code&amp;gt; || The core game state patch: XML files defining all game objects (weapons, vehicles, organisations, research, etc.). This is the primary source of moddable game data.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/difficulty0_patch/&amp;lt;/code&amp;gt; through &amp;lt;code&amp;gt;data/difficulty4_patch/&amp;lt;/code&amp;gt; || Difficulty-specific overrides applied on top of the common patch. Each corresponds to a difficulty level (0 = Easiest, 4 = Hardest).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/resource_patch/&amp;lt;/code&amp;gt; || Additional resource patches.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/city/&amp;lt;/code&amp;gt; || City-related image resources (map overlays, UI elements, building indicators).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/battle/&amp;lt;/code&amp;gt; || Battle-related data and resources.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/maps/&amp;lt;/code&amp;gt; || Map data files.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/tilesets/&amp;lt;/code&amp;gt; || Tileset definitions for map rendering.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/forms/&amp;lt;/code&amp;gt; || XML UI form definitions (the layout of menus, screens, and dialogs).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/fonts/&amp;lt;/code&amp;gt; || Font data files.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/imagepacks/&amp;lt;/code&amp;gt; || Sprite and image pack data.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/animationpacks/&amp;lt;/code&amp;gt; || Unit animation pack data.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/bulletsprites/&amp;lt;/code&amp;gt; || Projectile sprite images.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/languages/&amp;lt;/code&amp;gt; || Translation files for localisation.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/scripts/&amp;lt;/code&amp;gt; || Lua scripts loaded by the engine (see [[#Lua Scripting|Lua Scripting]]).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/mods/&amp;lt;/code&amp;gt; || The mods directory, containing all installed mods.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;data/ui/&amp;lt;/code&amp;gt; || UI image resources.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Game State XML Files ===&lt;br /&gt;
&lt;br /&gt;
The game state is defined by a hierarchy of XML files rooted at &amp;lt;code&amp;gt;gamestate.xml&amp;lt;/code&amp;gt;. The root file uses XInclude (&amp;lt;code&amp;gt;xi:include&amp;lt;/code&amp;gt;) to pull in individual data files for each object type. The key files in &amp;lt;code&amp;gt;common_patch/gamestate/&amp;lt;/code&amp;gt; are:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! File !! Contents&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;agent_equipment.xml&amp;lt;/code&amp;gt; || Agent (soldier) weapons, armour, grenades, equipment, and their stats (damage, accuracy, range, weight, etc.).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;agent_types.xml&amp;lt;/code&amp;gt; || Agent type definitions (X-COM agents, aliens, civilians, building security, etc.).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;agent_body_types.xml&amp;lt;/code&amp;gt; || Physical body type definitions for agents.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;agent_generator.xml&amp;lt;/code&amp;gt; || Rules for procedurally generating agents (name lists, stat ranges).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;vehicle_types.xml&amp;lt;/code&amp;gt; || Vehicle type definitions (stats, images, type classification such as Road, Flying, ATV, UFO).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;vehicle_equipment.xml&amp;lt;/code&amp;gt; || Vehicle weapons and modules (lasers, missiles, engines, shields, etc.).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;vehicle_ammo.xml&amp;lt;/code&amp;gt; || Vehicle ammunition definitions (ammo types, capacities, costs).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;organisations.xml&amp;lt;/code&amp;gt; || Organisation definitions (Megapol, Marsec, Cult of Sirius, etc.), including their relationships, guard types, and hireable agent types.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;facility_types.xml&amp;lt;/code&amp;gt; || Base facility definitions (labs, workshops, living quarters, stores, etc.).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;research.xml&amp;lt;/code&amp;gt; || The research tree: topics, dependencies, costs, and what they unlock.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;damage_types.xml&amp;lt;/code&amp;gt; || Damage type definitions and damage modifiers.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;ufopaedia.xml&amp;lt;/code&amp;gt; || UFOpaedia article definitions and categories.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;ufo_growth_lists.xml&amp;lt;/code&amp;gt; || UFO spawning rules per week, controlling the alien invasion progression.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;ufo_incursions.xml&amp;lt;/code&amp;gt; || UFO incursion event definitions.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;ufo_mission_preference.xml&amp;lt;/code&amp;gt; || UFO mission target preferences.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
The root &amp;lt;code&amp;gt;gamestate.xml&amp;lt;/code&amp;gt; also contains inline data for game-wide settings such as:&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;weekly_rating_rules&amp;lt;/code&amp;gt; &amp;amp;mdash; Score thresholds that affect government funding changes&lt;br /&gt;
* &amp;lt;code&amp;gt;agent_salary&amp;lt;/code&amp;gt; &amp;amp;mdash; Weekly salary per agent role (Soldier, Physicist, BioChemist, Engineer)&lt;br /&gt;
* &amp;lt;code&amp;gt;initial_agents&amp;lt;/code&amp;gt; &amp;amp;mdash; Number of agents per role at game start&lt;br /&gt;
* &amp;lt;code&amp;gt;initial_facilities&amp;lt;/code&amp;gt; &amp;amp;mdash; Starting base facilities&lt;br /&gt;
* &amp;lt;code&amp;gt;initial_agent_equipment&amp;lt;/code&amp;gt; &amp;amp;mdash; Equipment loadouts for starting agents&lt;br /&gt;
* &amp;lt;code&amp;gt;initial_vehicles&amp;lt;/code&amp;gt; &amp;amp;mdash; Starting vehicles and their equipment&lt;br /&gt;
* &amp;lt;code&amp;gt;initial_vehicle_equipment&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;initial_vehicle_ammo&amp;lt;/code&amp;gt; &amp;amp;mdash; Spare vehicle equipment and ammo in starting base storage&lt;br /&gt;
&lt;br /&gt;
=== XML Data Format ===&lt;br /&gt;
&lt;br /&gt;
Game state data uses a consistent key/value format. Collections are stored as lists of &amp;lt;code&amp;gt;&amp;lt;entry&amp;gt;&amp;lt;/code&amp;gt; elements, where each entry has a &amp;lt;code&amp;gt;&amp;lt;key&amp;gt;&amp;lt;/code&amp;gt; and a &amp;lt;code&amp;gt;&amp;lt;value&amp;gt;&amp;lt;/code&amp;gt;. The key is a unique string identifier (e.g. &amp;lt;code&amp;gt;VEHICLETYPE_PHOENIX_HOVERCAR&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;AEQUIPMENTTYPE_MEGAPOL_LASER_SNIPER_GUN&amp;lt;/code&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
To override an existing object, you only need to provide the key and the specific fields you want to change. Fields you omit will retain their original values. For example, to change only the manufacturer of the Dimension Probe vehicle:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;vehicle_types&amp;gt;&lt;br /&gt;
  &amp;lt;entry&amp;gt;&lt;br /&gt;
    &amp;lt;key&amp;gt;VEHICLETYPE_DIMENSION_PROBE&amp;lt;/key&amp;gt;&lt;br /&gt;
    &amp;lt;value&amp;gt;&lt;br /&gt;
      &amp;lt;name&amp;gt;Dimension Probe&amp;lt;/name&amp;gt;&lt;br /&gt;
      &amp;lt;manufacturer&amp;gt;ORG_X-COM&amp;lt;/manufacturer&amp;gt;&lt;br /&gt;
    &amp;lt;/value&amp;gt;&lt;br /&gt;
  &amp;lt;/entry&amp;gt;&lt;br /&gt;
&amp;lt;/vehicle_types&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Savegame Editing ==&lt;br /&gt;
&lt;br /&gt;
One of OpenApoc&#039;s key features is its human-readable save game format. All save games are stored as &#039;&#039;&#039;XML files inside a ZIP archive&#039;&#039;&#039; (with a &amp;lt;code&amp;gt;.zip&amp;lt;/code&amp;gt; extension, though they may not have one if unpacked saving is enabled).&lt;br /&gt;
&lt;br /&gt;
=== Save Location ===&lt;br /&gt;
&lt;br /&gt;
By default, saves are stored in the &amp;lt;code&amp;gt;./saves/&amp;lt;/code&amp;gt; directory relative to the OpenApoc installation. This can be changed via the &amp;lt;code&amp;gt;Game.Save.Directory&amp;lt;/code&amp;gt; configuration option.&lt;br /&gt;
&lt;br /&gt;
=== Save Format ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;code&amp;gt;Game.Save.Pack&amp;lt;/code&amp;gt; option (default: &amp;lt;code&amp;gt;true&amp;lt;/code&amp;gt;) controls whether saves are packed into ZIP archives or saved as a directory of loose XML files. When packed:&lt;br /&gt;
&lt;br /&gt;
* The save file is a standard ZIP archive&lt;br /&gt;
* Inside it are multiple XML files following the same structure as the game state data (one XML file per object category)&lt;br /&gt;
* The XML files use the same format as the data patches (described above)&lt;br /&gt;
&lt;br /&gt;
=== Editing a Save ===&lt;br /&gt;
&lt;br /&gt;
To edit a saved game:&lt;br /&gt;
&lt;br /&gt;
# Locate the save file in the saves directory&lt;br /&gt;
# If it is a ZIP file, extract it using any ZIP-compatible tool (7-Zip, WinRAR, the built-in OS extractor, etc.)&lt;br /&gt;
# Edit the desired XML files with a text editor&lt;br /&gt;
# If you extracted a ZIP, re-compress the files back into a ZIP archive with the same name&lt;br /&gt;
# Load the modified save in OpenApoc&lt;br /&gt;
&lt;br /&gt;
Alternatively, you can set &amp;lt;code&amp;gt;Game.Save.Pack&amp;lt;/code&amp;gt; to &amp;lt;code&amp;gt;false&amp;lt;/code&amp;gt; in &amp;lt;code&amp;gt;settings.cfg&amp;lt;/code&amp;gt;. This causes saves to be written as directories of loose XML files, which makes editing easier since you do not need to extract and repack a ZIP.&lt;br /&gt;
&lt;br /&gt;
Common things to edit in saves include:&lt;br /&gt;
&lt;br /&gt;
* Organisation relationships (in the organisations data)&lt;br /&gt;
* Agent stats and equipment&lt;br /&gt;
* Vehicle loadouts and positions&lt;br /&gt;
* Player funds&lt;br /&gt;
* Research progress&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Tip:&#039;&#039;&#039; OpenApoc also supports optional CRC and SHA1 checksums on save files (controlled by &amp;lt;code&amp;gt;Framework.Serialization.CRC&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;Framework.Serialization.SHA1&amp;lt;/code&amp;gt;). If these are enabled, manually editing a save file will invalidate the checksum. By default, both are disabled.&lt;br /&gt;
&lt;br /&gt;
== Lua Scripting ==&lt;br /&gt;
&lt;br /&gt;
OpenApoc integrates &#039;&#039;&#039;Lua&#039;&#039;&#039; (bundled as a dependency) as a scripting language. Lua scripts can hook into game events, modify game state at runtime, and implement complex game logic that would be difficult to express in static XML data.&lt;br /&gt;
&lt;br /&gt;
=== How Scripts Are Loaded ===&lt;br /&gt;
&lt;br /&gt;
Scripts are loaded via the &amp;lt;code&amp;gt;OpenApoc.Mod.ScriptsList&amp;lt;/code&amp;gt; configuration option. This is a &#039;&#039;&#039;semicolon-separated&#039;&#039;&#039; list of Lua script paths (resolved through the virtual filesystem). The default value is:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
scripts/openapoc_base.lua;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When the game state is initialised, each script in this list is executed in order. Scripts can use the standard Lua &amp;lt;code&amp;gt;dofile()&amp;lt;/code&amp;gt; function to include additional scripts.&lt;br /&gt;
&lt;br /&gt;
Additionally, each mod can specify a &amp;lt;code&amp;gt;&amp;lt;modloadscript&amp;gt;&amp;lt;/code&amp;gt; in its &amp;lt;code&amp;gt;modinfo.xml&amp;lt;/code&amp;gt;. This script is executed after the mod&#039;s game state has been loaded and merged.&lt;br /&gt;
&lt;br /&gt;
=== The OpenApoc Lua API ===&lt;br /&gt;
&lt;br /&gt;
Scripts have access to a global &amp;lt;code&amp;gt;OpenApoc&amp;lt;/code&amp;gt; table that provides:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;&amp;lt;code&amp;gt;OpenApoc.GameState&amp;lt;/code&amp;gt;&#039;&#039;&#039; (aliased as &amp;lt;code&amp;gt;GS&amp;lt;/code&amp;gt; in the base script) &amp;amp;mdash; Direct access to the full game state, including:&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.vehicle_types&amp;lt;/code&amp;gt; &amp;amp;mdash; All vehicle type definitions&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.agent_equipment&amp;lt;/code&amp;gt; &amp;amp;mdash; All agent equipment definitions&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.organisations&amp;lt;/code&amp;gt; &amp;amp;mdash; All organisation definitions&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.vehicle_equipment&amp;lt;/code&amp;gt; &amp;amp;mdash; All vehicle equipment definitions&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.vehicle_ammo&amp;lt;/code&amp;gt; &amp;amp;mdash; All vehicle ammo definitions&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.cities&amp;lt;/code&amp;gt; &amp;amp;mdash; City data&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.vehicles&amp;lt;/code&amp;gt; &amp;amp;mdash; Active vehicle instances&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.agents&amp;lt;/code&amp;gt; &amp;amp;mdash; Active agent instances&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.economy&amp;lt;/code&amp;gt; &amp;amp;mdash; Economy data for all items&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.ufo_growth_lists&amp;lt;/code&amp;gt; &amp;amp;mdash; UFO growth/spawning rules&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.gameTime&amp;lt;/code&amp;gt; &amp;amp;mdash; Current game time&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.rng&amp;lt;/code&amp;gt; &amp;amp;mdash; The game&#039;s random number generator&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.player&amp;lt;/code&amp;gt; &amp;amp;mdash; Reference to the player organisation&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.difficulty&amp;lt;/code&amp;gt; &amp;amp;mdash; Current difficulty level (0-4)&lt;br /&gt;
** &amp;lt;code&amp;gt;GS.agent_generator&amp;lt;/code&amp;gt; &amp;amp;mdash; The agent generator (can create new agents)&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;&amp;lt;code&amp;gt;OpenApoc.Framework&amp;lt;/code&amp;gt;&#039;&#039;&#039; (aliased as &amp;lt;code&amp;gt;FW&amp;lt;/code&amp;gt;) &amp;amp;mdash; Framework functions:&lt;br /&gt;
** &amp;lt;code&amp;gt;FW.LogInfo(message)&amp;lt;/code&amp;gt; &amp;amp;mdash; Log an informational message&lt;br /&gt;
** &amp;lt;code&amp;gt;FW.LogWarning(message)&amp;lt;/code&amp;gt; &amp;amp;mdash; Log a warning&lt;br /&gt;
** &amp;lt;code&amp;gt;FW.LogError(message)&amp;lt;/code&amp;gt; &amp;amp;mdash; Log an error&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;&amp;lt;code&amp;gt;OpenApoc.Framework.Config&amp;lt;/code&amp;gt;&#039;&#039;&#039; (aliased as &amp;lt;code&amp;gt;CFG&amp;lt;/code&amp;gt;) &amp;amp;mdash; Configuration access:&lt;br /&gt;
** &amp;lt;code&amp;gt;CFG.getBool(&#039;Section.Key&#039;)&amp;lt;/code&amp;gt; &amp;amp;mdash; Read a boolean config value&lt;br /&gt;
** &amp;lt;code&amp;gt;CFG.getInt(&#039;Section.Key&#039;)&amp;lt;/code&amp;gt; &amp;amp;mdash; Read an integer config value&lt;br /&gt;
** &amp;lt;code&amp;gt;CFG.getString(&#039;Section.Key&#039;)&amp;lt;/code&amp;gt; &amp;amp;mdash; Read a string config value&lt;br /&gt;
** &amp;lt;code&amp;gt;CFG.getFloat(&#039;Section.Key&#039;)&amp;lt;/code&amp;gt; &amp;amp;mdash; Read a float config value&lt;br /&gt;
** &amp;lt;code&amp;gt;CFG.describe(&#039;Section&#039;, &#039;Key&#039;)&amp;lt;/code&amp;gt; &amp;amp;mdash; Get the description of a config option&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;&amp;lt;code&amp;gt;OpenApoc.enum&amp;lt;/code&amp;gt;&#039;&#039;&#039; &amp;amp;mdash; Game enumerations (e.g. &amp;lt;code&amp;gt;OpenApoc.enum.VehicleType.Type.ATV&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;OpenApoc.enum.VehicleType.Type.Road&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;OpenApoc.enum.VehicleType.Type.UFO&amp;lt;/code&amp;gt;)&lt;br /&gt;
&lt;br /&gt;
=== Hooks ===&lt;br /&gt;
&lt;br /&gt;
The scripting system uses a hook-based architecture. Scripts register functions in &amp;lt;code&amp;gt;OpenApoc.hook&amp;lt;/code&amp;gt; that the engine calls at specific points during gameplay. The available hooks are:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Hook Name !! When It Is Called&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;newGame&amp;lt;/code&amp;gt; || When a new game is started (before initial state setup).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;newGamePostInit&amp;lt;/code&amp;gt; || After the new game&#039;s initial state has been fully set up (registered in the base Lua script, not called directly by C++; chained from &amp;lt;code&amp;gt;newGame&amp;lt;/code&amp;gt; flow).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;applyMods&amp;lt;/code&amp;gt; || When mod-related game state changes should be applied (e.g. toggling vehicle types based on config options).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;updateEndOfDay&amp;lt;/code&amp;gt; || At the end of each in-game day.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;updateEndOfWeek&amp;lt;/code&amp;gt; || At the end of each in-game week (used for economy updates and UFO growth).&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Scripts should chain hooks rather than replace them, preserving any previously registered hook:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
local oldHook = OpenApoc.hook.updateEndOfWeek&lt;br /&gt;
OpenApoc.hook.updateEndOfWeek = function()&lt;br /&gt;
    if oldHook then oldHook() end&lt;br /&gt;
    -- your custom logic here&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Base Scripts ===&lt;br /&gt;
&lt;br /&gt;
The default &amp;lt;code&amp;gt;scripts/openapoc_base.lua&amp;lt;/code&amp;gt; script and its included files implement core game mechanics:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;&amp;lt;code&amp;gt;openapoc_base.lua&amp;lt;/code&amp;gt;&#039;&#039;&#039; &amp;amp;mdash; The main script. Provides utility functions (&amp;lt;code&amp;gt;pickRandom&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;math.clamp&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;math.round&amp;lt;/code&amp;gt;), seeds the RNG on new game start, applies mod options (ATV vehicle types, brainsucker launcher sound, crashing vehicles), spawns developer Easter egg agents, and chains weekly update hooks.&lt;br /&gt;
* &#039;&#039;&#039;&amp;lt;code&amp;gt;update_economy.lua&amp;lt;/code&amp;gt;&#039;&#039;&#039; &amp;amp;mdash; Implements the weekly economy update (item stock fluctuation and price changes, based on Wong&#039;s guide).&lt;br /&gt;
* &#039;&#039;&#039;&amp;lt;code&amp;gt;update_ufo_growth.lua&amp;lt;/code&amp;gt;&#039;&#039;&#039; &amp;amp;mdash; Implements weekly UFO growth/spawning in the alien dimension, respecting per-week growth lists and vehicle limits.&lt;br /&gt;
&lt;br /&gt;
=== Mod Load Scripts ===&lt;br /&gt;
&lt;br /&gt;
The base mod&#039;s load script (&amp;lt;code&amp;gt;scripts/org.openapoc.base/onload.lua&amp;lt;/code&amp;gt;) demonstrates how a mod load script works:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
local OA = OpenApoc&lt;br /&gt;
local GS = OpenApoc.GameState&lt;br /&gt;
local FW = OpenApoc.Framework&lt;br /&gt;
&lt;br /&gt;
FW.LogInfo(&amp;quot;On load script called&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
local gamestateString = &amp;quot;submods/org.openapoc.base/difficulty&amp;quot; .. tostring(GS.difficulty)&lt;br /&gt;
FW.LogInfo(&amp;quot;Loading difficulty patch&amp;quot; .. gamestateString)&lt;br /&gt;
&lt;br /&gt;
GS.appendGameState(GS, gamestateString)&lt;br /&gt;
&lt;br /&gt;
FW.LogInfo(&amp;quot;Finished loading difficulty patch&amp;quot;)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This script uses the current difficulty level to load a difficulty-specific game state patch from a submod directory, allowing different difficulty settings to override game data (such as organisation relationships, city layouts, and alien forces).&lt;br /&gt;
&lt;br /&gt;
=== RNG Methods ===&lt;br /&gt;
&lt;br /&gt;
The random number generator (&amp;lt;code&amp;gt;GS.rng&amp;lt;/code&amp;gt;) exposes the following methods for use in Lua scripts:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Method !! Description&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;GS.rng:randBoundsInclusive(min, max)&amp;lt;/code&amp;gt; || Returns a random integer in the range [min, max] (both endpoints included).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;GS.rng:randBoundsExclusive(min, max)&amp;lt;/code&amp;gt; || Returns a random integer in the range [min, max) (max excluded).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;GS.rng:seed(value)&amp;lt;/code&amp;gt; || Seeds the random number generator with the given value.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Example usage from the base scripts:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
-- Pick a random element from a Lua table&lt;br /&gt;
function pickRandom(t)&lt;br /&gt;
    return t[GS.rng:randBoundsInclusive(1, #t)]&lt;br /&gt;
end&lt;br /&gt;
&lt;br /&gt;
-- Seed the RNG on new game start&lt;br /&gt;
GS.rng:seed(os.time())&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== GameTime Methods ===&lt;br /&gt;
&lt;br /&gt;
The game time object (&amp;lt;code&amp;gt;GS.gameTime&amp;lt;/code&amp;gt;) exposes the following read-only methods:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Method !! Returns&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;GS.gameTime:getHours()&amp;lt;/code&amp;gt; || Current hour of the day&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;GS.gameTime:getMinutes()&amp;lt;/code&amp;gt; || Current minute of the hour&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;GS.gameTime:getDay()&amp;lt;/code&amp;gt; || Current day number&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;GS.gameTime:getWeek()&amp;lt;/code&amp;gt; || Current week number&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== GameState and Object Methods ===&lt;br /&gt;
&lt;br /&gt;
Beyond data access, several game objects expose methods that can be called from Lua scripts:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Method !! Description&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;GS:appendGameState(path)&amp;lt;/code&amp;gt; || Load and merge additional game state XML from the given path into the current GameState. Used by the base mod to apply difficulty patches.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;GS:loadGame(path)&amp;lt;/code&amp;gt; || Load a saved game from the given path.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;city:placeVehicle(vehicleType, owner)&amp;lt;/code&amp;gt; || Place a new vehicle of the given type in the city, owned by the specified organisation.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;city:placeVehicleInBuilding(vehicleType, owner, building)&amp;lt;/code&amp;gt; || Place a new vehicle at a specific building.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;city:placeVehicleAtPosition(vehicleType, owner, position, facing)&amp;lt;/code&amp;gt; || Place a new vehicle at specific XYZ coordinates with an optional facing angle.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;agent_generator:createAgent(orgRef, agentTypeRef)&amp;lt;/code&amp;gt; || Create a new agent of the given type, hired by the specified organisation. Returns a StateRef to the new agent.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;agent:enterBuilding(buildingRef)&amp;lt;/code&amp;gt; || Move an agent into the specified building.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== The StateRef Pattern ===&lt;br /&gt;
&lt;br /&gt;
When accessing game objects from Lua, it is important to understand the &#039;&#039;&#039;StateRef&#039;&#039;&#039; pattern. OpenApoc objects exposed to Lua are &#039;&#039;&#039;not&#039;&#039;&#039; standard Lua tables &amp;amp;mdash; they are C++ objects with a custom interface. This has several implications:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Iterating collections:&#039;&#039;&#039; Use &amp;lt;code&amp;gt;pairs()&amp;lt;/code&amp;gt; to iterate game state collections. The loop yields &amp;lt;code&amp;gt;(id_string, object)&amp;lt;/code&amp;gt; pairs:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
for vt_id, vt_object in pairs(GS.vehicle_types) do&lt;br /&gt;
    -- vt_id is the string key (e.g. &#039;VEHICLETYPE_PHOENIX_HOVERCAR&#039;)&lt;br /&gt;
    -- vt_object is the vehicle type object&lt;br /&gt;
    vt_object.type = OA.enum.VehicleType.Type.ATV&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Passing references to C++ functions:&#039;&#039;&#039; StateRefs must be passed as &#039;&#039;&#039;strings&#039;&#039;&#039; (the object&#039;s ID), not as object references:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
-- Correct: pass the string ID&lt;br /&gt;
agent.object:enterBuilding(building.id)&lt;br /&gt;
agent.object.homeBuilding = building.id&lt;br /&gt;
&lt;br /&gt;
-- NOT: agent.object:enterBuilding(building.object)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Debugging:&#039;&#039;&#039; The standard &amp;lt;code&amp;gt;table.dump()&amp;lt;/code&amp;gt; function will not work on OpenApoc objects since they are not actual Lua tables. Use &amp;lt;code&amp;gt;FW.LogInfo()&amp;lt;/code&amp;gt; to print individual fields instead.&lt;br /&gt;
&lt;br /&gt;
=== Utility Functions ===&lt;br /&gt;
&lt;br /&gt;
The base script (&amp;lt;code&amp;gt;openapoc_base.lua&amp;lt;/code&amp;gt;) provides several utility functions that are available to all mod scripts, since it loads first:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Function !! Description&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;pickRandom(table)&amp;lt;/code&amp;gt; || Returns a random element from a Lua table, using the game&#039;s RNG for deterministic replay.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;math.clamp(v, min, max)&amp;lt;/code&amp;gt; || Clamps a value between min and max.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;math.round(v)&amp;lt;/code&amp;gt; || Rounds a number to the nearest integer.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;table.dump(t, nesting)&amp;lt;/code&amp;gt; || Debug function that prints a table&#039;s contents. Note: does &#039;&#039;&#039;not&#039;&#039;&#039; work on OpenApoc objects.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Mod Options ==&lt;br /&gt;
&lt;br /&gt;
OpenApoc provides several configurable options in the &#039;&#039;&#039;More Options&#039;&#039;&#039; menu under the &amp;lt;code&amp;gt;OpenApoc.Mod&amp;lt;/code&amp;gt; section. These are options that can meaningfully change gameplay balance and are considered &amp;quot;mod-like&amp;quot; changes:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Option !! Type !! Default !! Description&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;MaxTileRepair&amp;lt;/code&amp;gt; || Integer || 5 || Maximum number of scenery tiles that Construction Vehicles will repair per night.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;SceneryRepairCostFactor&amp;lt;/code&amp;gt; || Float || 10.0 || Percentage of the original price organisations must pay for scenery tile repairs.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;StunHostileAction&amp;lt;/code&amp;gt; || Boolean || false || Whether stunning an organisation&#039;s units counts as a hostile action (hurts relationships).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;RaidHostileAction&amp;lt;/code&amp;gt; || Boolean || false || Whether initiating a raid on a building counts as a hostile action (hurts relationships).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;BSKLauncherSound&amp;lt;/code&amp;gt; || Boolean || true || Use the original Brainsucker Launcher sound effect (instead of the generic powers sound).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;InvulnerableRoads&amp;lt;/code&amp;gt; || Boolean || false || Makes road scenery tiles indestructible.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;ATVTank&amp;lt;/code&amp;gt; || Boolean || true || Makes the Griffon AFV an All-Terrain Vehicle (can travel on roads and fly).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;ATVAPC&amp;lt;/code&amp;gt; || Boolean || true || Makes the Wolfhound APC an All-Terrain Vehicle.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;CrashingVehicles&amp;lt;/code&amp;gt; || Boolean || false || Vehicles crash when their HP drops below 1/7 of maximum (weapons and modules may be lost).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;ScriptsList&amp;lt;/code&amp;gt; || String || &amp;lt;code&amp;gt;scripts/openapoc_base.lua;&amp;lt;/code&amp;gt; || Semicolon-separated list of Lua scripts to load at game initialisation.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
These options are applied at runtime through the Lua scripting system (in the &amp;lt;code&amp;gt;applyMods&amp;lt;/code&amp;gt; hook), so their effects take place each time a game is loaded or started. This means you can change these options between play sessions without starting a new game.&lt;br /&gt;
&lt;br /&gt;
== Creating a Mod ==&lt;br /&gt;
&lt;br /&gt;
=== Basic Steps ===&lt;br /&gt;
&lt;br /&gt;
# &#039;&#039;&#039;Create a mod directory&#039;&#039;&#039; inside &amp;lt;code&amp;gt;data/mods/&amp;lt;/code&amp;gt;. Choose a descriptive name (e.g. &amp;lt;code&amp;gt;my_balance_mod&amp;lt;/code&amp;gt;).&lt;br /&gt;
# &#039;&#039;&#039;Create a &amp;lt;code&amp;gt;modinfo.xml&amp;lt;/code&amp;gt;&#039;&#039;&#039; file in your mod&#039;s root directory (see the [[#The modinfo.xml File|modinfo.xml reference]] above).&lt;br /&gt;
# &#039;&#039;&#039;Choose a unique ID&#039;&#039;&#039; for your mod using reverse-DNS format: &amp;lt;code&amp;gt;org.openapoc.mod.your_name.mod_name&amp;lt;/code&amp;gt;.&lt;br /&gt;
# &#039;&#039;&#039;Create a data directory&#039;&#039;&#039; (referenced by &amp;lt;code&amp;gt;&amp;lt;datapath&amp;gt;&amp;lt;/code&amp;gt; in your modinfo.xml) for any resource overrides.&lt;br /&gt;
# &#039;&#039;&#039;Create a game state directory&#039;&#039;&#039; (referenced by &amp;lt;code&amp;gt;&amp;lt;statepath&amp;gt;&amp;lt;/code&amp;gt;) containing XML files that override or extend the base game state.&lt;br /&gt;
# &#039;&#039;&#039;Optionally create Lua scripts&#039;&#039;&#039; for dynamic logic (referenced by &amp;lt;code&amp;gt;&amp;lt;modloadscript&amp;gt;&amp;lt;/code&amp;gt;).&lt;br /&gt;
# &#039;&#039;&#039;Enable your mod&#039;&#039;&#039; by adding its directory name to the &amp;lt;code&amp;gt;Game.Mods&amp;lt;/code&amp;gt; option (colon-separated), or by enabling it in the launcher.&lt;br /&gt;
&lt;br /&gt;
=== Mod Directory Structure ===&lt;br /&gt;
&lt;br /&gt;
A typical mod directory might look like this:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
data/mods/my_mod/&lt;br /&gt;
    modinfo.xml                          -- Mod metadata and configuration&lt;br /&gt;
    my_gamestate/                        -- Game state overrides (referenced by &amp;lt;statepath&amp;gt;)&lt;br /&gt;
        gamestate.xml                    -- Root game state file with xi:include references&lt;br /&gt;
        gamestate/&lt;br /&gt;
            agent_equipment.xml          -- Override agent equipment stats&lt;br /&gt;
            vehicle_types.xml            -- Override vehicle stats&lt;br /&gt;
            organisations.xml            -- Override organisation data&lt;br /&gt;
    data/                                -- Data path overrides (referenced by &amp;lt;datapath&amp;gt;)&lt;br /&gt;
        scripts/&lt;br /&gt;
            my_mod/&lt;br /&gt;
                onload.lua               -- Mod load script&lt;br /&gt;
        submods/&lt;br /&gt;
            my_mod/&lt;br /&gt;
                custom_patch/            -- Additional game state that can be loaded by scripts&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Tips ===&lt;br /&gt;
&lt;br /&gt;
* You only need to include the XML fields you want to change. Unspecified fields retain their original values.&lt;br /&gt;
* Use the &amp;lt;code&amp;gt;common_patch/gamestate/&amp;lt;/code&amp;gt; files as a reference for available fields and their expected format.&lt;br /&gt;
* The game state is loaded cumulatively: the base data is loaded first (from the original CD and the extractor), then &amp;lt;code&amp;gt;common_patch&amp;lt;/code&amp;gt;, then difficulty patches, then mods in order. Your mod&#039;s changes are layered on top of all previous data.&lt;br /&gt;
* Files in your mod&#039;s &amp;lt;code&amp;gt;&amp;lt;datapath&amp;gt;&amp;lt;/code&amp;gt; directory override files with the same relative path from earlier in the load order. This lets you replace images, sounds, form definitions, and other resources.&lt;br /&gt;
* Test changes incrementally. Start by modifying a single value (e.g. a weapon&#039;s damage) and verify it works before making larger changes.&lt;br /&gt;
* Keep your mod&#039;s files under a directory named after your mod ID to avoid filename conflicts with other mods.&lt;br /&gt;
&lt;br /&gt;
== Examples ==&lt;br /&gt;
&lt;br /&gt;
=== Changing a Weapon&#039;s Stats ===&lt;br /&gt;
&lt;br /&gt;
To increase the damage of the Megapol Laser Sniper Gun, create a file in your mod&#039;s game state directory:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- agent_equipment.xml --&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;agent_equipment&amp;gt;&lt;br /&gt;
  &amp;lt;entry&amp;gt;&lt;br /&gt;
    &amp;lt;key&amp;gt;AEQUIPMENTTYPE_MEGAPOL_LASER_SNIPER_GUN&amp;lt;/key&amp;gt;&lt;br /&gt;
    &amp;lt;value&amp;gt;&lt;br /&gt;
      &amp;lt;damage&amp;gt;40&amp;lt;/damage&amp;gt;&lt;br /&gt;
      &amp;lt;accuracy&amp;gt;85&amp;lt;/accuracy&amp;gt;&lt;br /&gt;
    &amp;lt;/value&amp;gt;&lt;br /&gt;
  &amp;lt;/entry&amp;gt;&lt;br /&gt;
&amp;lt;/agent_equipment&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Making a Vehicle All-Terrain via Lua ===&lt;br /&gt;
&lt;br /&gt;
The base game already demonstrates this pattern. In your mod&#039;s Lua script:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
local OA = OpenApoc&lt;br /&gt;
local GS = OpenApoc.GameState&lt;br /&gt;
&lt;br /&gt;
local oldApplyMods = OpenApoc.hook.applyMods&lt;br /&gt;
OpenApoc.hook.applyMods = function()&lt;br /&gt;
    if oldApplyMods then oldApplyMods() end&lt;br /&gt;
&lt;br /&gt;
    -- Make the Phoenix Hovercar an ATV&lt;br /&gt;
    GS.vehicle_types[&#039;VEHICLETYPE_PHOENIX_HOVERCAR&#039;].type = OA.enum.VehicleType.Type.ATV&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Modifying Organisation Relationships ===&lt;br /&gt;
&lt;br /&gt;
To change starting organisation data, override the organisations XML:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;lt;!-- organisations.xml --&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;organisations&amp;gt;&lt;br /&gt;
  &amp;lt;entry&amp;gt;&lt;br /&gt;
    &amp;lt;key&amp;gt;ORG_MEGAPOL&amp;lt;/key&amp;gt;&lt;br /&gt;
    &amp;lt;value&amp;gt;&lt;br /&gt;
      &amp;lt;average_guards&amp;gt;15&amp;lt;/average_guards&amp;gt;&lt;br /&gt;
    &amp;lt;/value&amp;gt;&lt;br /&gt;
  &amp;lt;/entry&amp;gt;&lt;br /&gt;
&amp;lt;/organisations&amp;gt;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Adding a Weekly Event via Lua ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
local OA = OpenApoc&lt;br /&gt;
local GS = OpenApoc.GameState&lt;br /&gt;
local FW = OpenApoc.Framework&lt;br /&gt;
&lt;br /&gt;
local oldWeekHook = OpenApoc.hook.updateEndOfWeek&lt;br /&gt;
OpenApoc.hook.updateEndOfWeek = function()&lt;br /&gt;
    if oldWeekHook then oldWeekHook() end&lt;br /&gt;
&lt;br /&gt;
    local week = GS.gameTime:getWeek()&lt;br /&gt;
    FW.LogInfo(&amp;quot;Custom mod: Week &amp;quot; .. tostring(week) .. &amp;quot; has ended!&amp;quot;)&lt;br /&gt;
    -- Add your custom weekly logic here&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Modifying Equipment Sets and Starting Loadouts ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;code&amp;gt;common_patch/gamestate.xml&amp;lt;/code&amp;gt; file defines &amp;lt;code&amp;gt;initial_agent_equipment&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;initial_vehicles&amp;lt;/code&amp;gt;, and &amp;lt;code&amp;gt;initial_vehicle_equipment&amp;lt;/code&amp;gt;. You can override these in your mod to give the player different starting equipment, vehicles, or base facilities.&lt;br /&gt;
&lt;br /&gt;
== The Base Mod ==&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;code&amp;gt;base&amp;lt;/code&amp;gt; mod (&amp;lt;code&amp;gt;data/mods/base/&amp;lt;/code&amp;gt;) is OpenApoc&#039;s foundational mod that ships with the game. It provides:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Game state data&#039;&#039;&#039; in &amp;lt;code&amp;gt;base_gamestate/&amp;lt;/code&amp;gt; (the initial game state loaded on top of the extracted CD data and common patches)&lt;br /&gt;
* &#039;&#039;&#039;Music playlists&#039;&#039;&#039; in &amp;lt;code&amp;gt;data/playlists/&amp;lt;/code&amp;gt; (city, tactical, action, and alien dimension music)&lt;br /&gt;
* &#039;&#039;&#039;Difficulty submods&#039;&#039;&#039; in &amp;lt;code&amp;gt;data/submods/org.openapoc.base/&amp;lt;/code&amp;gt; (difficulty0 through difficulty4, loaded dynamically based on the selected difficulty)&lt;br /&gt;
* &#039;&#039;&#039;A mod load script&#039;&#039;&#039; (&amp;lt;code&amp;gt;data/scripts/org.openapoc.base/onload.lua&amp;lt;/code&amp;gt;) that applies difficulty-specific patches at load time&lt;br /&gt;
* &#039;&#039;&#039;Language support&#039;&#039;&#039; with locale-specific data paths&lt;br /&gt;
&lt;br /&gt;
The base mod should generally always be enabled and listed first in the mod load order, as other mods are designed to layer on top of it.&lt;br /&gt;
&lt;br /&gt;
== Community Research Findings ==&lt;br /&gt;
&lt;br /&gt;
The following sections contain additional modding knowledge gathered from the OpenApoc Discord community. These insights supplement the official documentation above and reflect practical experience from active modders and contributors.&lt;br /&gt;
&lt;br /&gt;
=== Data File Architecture and Load Order ===&lt;br /&gt;
&lt;br /&gt;
The XML data system uses a strict layered loading architecture where order matters:&lt;br /&gt;
&lt;br /&gt;
# &#039;&#039;&#039;Generated data&#039;&#039;&#039; &amp;amp;mdash; Extracted from the original CD ISO by the extractor tools.&lt;br /&gt;
# &#039;&#039;&#039;&amp;lt;code&amp;gt;common_patch&amp;lt;/code&amp;gt;&#039;&#039;&#039; &amp;amp;mdash; Applied on top of generated data, providing OpenApoc&#039;s baseline corrections and additions.&lt;br /&gt;
# &#039;&#039;&#039;Difficulty-specific patch&#039;&#039;&#039; (&amp;lt;code&amp;gt;difficulty0_patch&amp;lt;/code&amp;gt; through &amp;lt;code&amp;gt;difficulty4_patch&amp;lt;/code&amp;gt;) &amp;amp;mdash; Overrides for the selected difficulty level.&lt;br /&gt;
# &#039;&#039;&#039;Mod patches&#039;&#039;&#039; &amp;amp;mdash; Loaded in the order specified by &amp;lt;code&amp;gt;Game.Mods&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Critical caveat&#039;&#039;&#039;: Difficulty patches load AFTER mods in the current architecture. This means mods cannot directly override difficulty-specific values through XML alone. The workaround is to use &#039;&#039;&#039;Lua &amp;lt;code&amp;gt;onload&amp;lt;/code&amp;gt; scripts&#039;&#039;&#039; (as demonstrated by PR #783) which execute at load time and can programmatically apply difficulty-aware changes. The base mod already uses this pattern to load difficulty patches via &amp;lt;code&amp;gt;onload.lua&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== The gamestate_common Archive ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;code&amp;gt;gamestate_common&amp;lt;/code&amp;gt; file is a &#039;&#039;&#039;ZIP archive with no file extension&#039;&#039;&#039;. This catches many new modders off guard. To inspect or edit it, either:&lt;br /&gt;
&lt;br /&gt;
* Open it directly with 7-Zip (which recognises the ZIP signature regardless of extension).&lt;br /&gt;
* Rename it to &amp;lt;code&amp;gt;gamestate_common.zip&amp;lt;/code&amp;gt; and open with any ZIP tool.&lt;br /&gt;
&lt;br /&gt;
The same applies to difficulty-specific archives (e.g., &amp;lt;code&amp;gt;difficulty0_patched&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;difficulty1_patched&amp;lt;/code&amp;gt;, etc.).&lt;br /&gt;
&lt;br /&gt;
=== Key XML Files Reference ===&lt;br /&gt;
&lt;br /&gt;
Beyond the table in the [[#Game State XML Files|Game State XML Files]] section, these files are particularly important for modding:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! File !! Modding Use&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;economy.xml&amp;lt;/code&amp;gt; || Controls the market: item availability, base prices, stock levels, and weekly fluctuation.&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;equipment_sets_by_level.xml&amp;lt;/code&amp;gt; || Defines human tech loadouts per game progression level (what equipment organisations use as the game advances).&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;equipment_sets_by_score.xml&amp;lt;/code&amp;gt; || Defines alien loadouts per difficulty level. Found in the &amp;lt;code&amp;gt;difficulty&#039;&#039;X&#039;&#039;_patched&amp;lt;/code&amp;gt; archives rather than in &amp;lt;code&amp;gt;common_patch&amp;lt;/code&amp;gt;.&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== The modinfo.xml System ===&lt;br /&gt;
&lt;br /&gt;
The mod system (introduced in PR #725) uses &#039;&#039;&#039;additive patching&#039;&#039;&#039;. When creating a mod, your XML files should only include the specific values you want to CHANGE. You do not need to reproduce the entire structure of the file you are patching. Unspecified fields retain their values from the previous layer.&lt;br /&gt;
&lt;br /&gt;
=== Image and Sound Overrides via datapath ===&lt;br /&gt;
&lt;br /&gt;
A mod&#039;s &amp;lt;code&amp;gt;&amp;lt;datapath&amp;gt;&amp;lt;/code&amp;gt; entry in &amp;lt;code&amp;gt;modinfo.xml&amp;lt;/code&amp;gt; adds a directory to the virtual filesystem. Files placed here can override any game resource &amp;amp;mdash; images, sounds, form definitions, etc. &amp;amp;mdash; by mirroring the original ISO&#039;s directory structure. For example, to replace a weapon sprite, place your replacement image at the same relative path the game expects within your mod&#039;s data directory.&lt;br /&gt;
&lt;br /&gt;
=== SerializationTool for Delta Patches ===&lt;br /&gt;
&lt;br /&gt;
The &#039;&#039;&#039;SerializationTool&#039;&#039;&#039; (in the &amp;lt;code&amp;gt;tools/&amp;lt;/code&amp;gt; directory) can generate minimal delta patches between two game states. This is useful for creating mods that only contain the differences from a base state, rather than duplicating entire data files.&lt;br /&gt;
&lt;br /&gt;
=== Sound Format Support ===&lt;br /&gt;
&lt;br /&gt;
OpenApoc supports the following sound formats for modding:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Raw PCM audio&#039;&#039;&#039;: Referenced as &amp;lt;code&amp;gt;RAWSOUND:samplerate:path&amp;lt;/code&amp;gt; (e.g., &amp;lt;code&amp;gt;RAWSOUND:22050:sounds/myeffect.raw&amp;lt;/code&amp;gt;).&lt;br /&gt;
* &#039;&#039;&#039;WAV&#039;&#039;&#039;: Standard WAV files.&lt;br /&gt;
* &#039;&#039;&#039;OGG Vorbis&#039;&#039;&#039;: Compressed audio via libvorbis.&lt;br /&gt;
&lt;br /&gt;
=== Palette System ===&lt;br /&gt;
&lt;br /&gt;
The game uses different palette systems in different contexts:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Cityscape&#039;&#039;&#039;: Uses a 3-palette blend system that transitions between day, twilight, and night palettes based on the time of day.&lt;br /&gt;
* &#039;&#039;&#039;Battlescape&#039;&#039;&#039;: Uses a static palette. A dynamic palette system was planned but ultimately cut from the implementation.&lt;br /&gt;
&lt;br /&gt;
Modders creating custom sprites should be aware of which palette context their assets will be used in.&lt;br /&gt;
&lt;br /&gt;
=== Armour Stat Mapping ===&lt;br /&gt;
&lt;br /&gt;
When modding armour pieces, each armour slot maps to a specific agent stat bonus:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Armour Slot !! Stat Affected&lt;br /&gt;
|-&lt;br /&gt;
| Legs || Speed&lt;br /&gt;
|-&lt;br /&gt;
| Arms || Accuracy&lt;br /&gt;
|-&lt;br /&gt;
| Helmet || Reactions&lt;br /&gt;
|-&lt;br /&gt;
| Chest || Bravery&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Sprite Workflow and Asset Creation ===&lt;br /&gt;
&lt;br /&gt;
Creating a single new weapon item is a significant undertaking. Community estimates suggest approximately &#039;&#039;&#039;12 hours of work&#039;&#039;&#039;, of which only about 15 minutes is XML editing. The remaining time is spent on sprite creation. A complete weapon requires:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Equip screen icon&#039;&#039;&#039; &amp;amp;mdash; The inventory sprite shown in the equipment screen.&lt;br /&gt;
* &#039;&#039;&#039;Dropped/thrown sprites&#039;&#039;&#039; &amp;amp;mdash; Sprites for the item when on the ground or in flight.&lt;br /&gt;
* &#039;&#039;&#039;Shadow sprites&#039;&#039;&#039; &amp;amp;mdash; Corresponding shadow sprites for dropped/thrown states.&lt;br /&gt;
* &#039;&#039;&#039;Handob sprites&#039;&#039;&#039; &amp;amp;mdash; The weapon as held by an agent, requiring sprites for each facing direction.&lt;br /&gt;
* &#039;&#039;&#039;UFOpaedia image&#039;&#039;&#039; &amp;amp;mdash; The full-size reference image displayed in the in-game encyclopedia.&lt;br /&gt;
&lt;br /&gt;
=== Common Modding Pitfalls ===&lt;br /&gt;
&lt;br /&gt;
The following issues are frequently encountered by new modders:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;CRC check errors&#039;&#039;&#039;: If &amp;lt;code&amp;gt;Framework.Serialization.CRC&amp;lt;/code&amp;gt; is enabled, manually editing &amp;lt;code&amp;gt;gamestate_common&amp;lt;/code&amp;gt; or save files will invalidate the checksum. Disable CRC checking in &amp;lt;code&amp;gt;settings.cfg&amp;lt;/code&amp;gt; when modding.&lt;br /&gt;
* &#039;&#039;&#039;Case sensitivity in file paths&#039;&#039;&#039;: Some platforms (especially Linux) are case-sensitive in file path resolution. Ensure your file references match the actual case exactly.&lt;br /&gt;
* &#039;&#039;&#039;&amp;lt;code&amp;gt;op=&#039;delete&#039;&amp;lt;/code&amp;gt; deletes the WHOLE list&#039;&#039;&#039;: The XML &amp;lt;code&amp;gt;op=&#039;delete&#039;&amp;lt;/code&amp;gt; attribute removes the entire list element, not just a single entry. There is currently no mechanism to delete individual entries from a list &amp;amp;mdash; you can only replace the entire list.&lt;br /&gt;
* &#039;&#039;&#039;Duplicate objects from serialization&#039;&#039;&#039;: When creating new objects via mods, ensure unique keys. Duplicate keys can cause the serialization system to create duplicate entries with unpredictable behavior.&lt;br /&gt;
* &#039;&#039;&#039;New game required&#039;&#039;&#039;: Always start a &#039;&#039;&#039;new game&#039;&#039;&#039; when changing mod XML data. Saves embed the game state at save time, so loading an old save will not pick up your XML changes.&lt;br /&gt;
* &#039;&#039;&#039;Mod requires/conflicts not enforced&#039;&#039;&#039;: The &amp;lt;code&amp;gt;&amp;lt;requires&amp;gt;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;&amp;lt;conflicts&amp;gt;&amp;lt;/code&amp;gt; fields in &amp;lt;code&amp;gt;modinfo.xml&amp;lt;/code&amp;gt; are defined in the format but not yet enforced by the engine. Version checking (&amp;lt;code&amp;gt;&amp;lt;minversion&amp;gt;&amp;lt;/code&amp;gt;) is also informational only.&lt;br /&gt;
&lt;br /&gt;
=== Damage Type Limitations ===&lt;br /&gt;
&lt;br /&gt;
Damage types are currently &#039;&#039;&#039;hardcoded&#039;&#039;&#039; in the engine. There is no modding capability for defining custom damage types. The available damage types are those defined in &amp;lt;code&amp;gt;damage_types.xml&amp;lt;/code&amp;gt;, but their underlying behavior (penetration logic, resistance calculations, special effects like fire or stun) is implemented in C++ code.&lt;br /&gt;
&lt;br /&gt;
=== Additional Known Limitations ===&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Physics and radii&#039;&#039;&#039;: Vehicle and projectile physics radii values are not moddable through XML or Lua.&lt;br /&gt;
* &#039;&#039;&#039;Organisation long-term relationships&#039;&#039;&#039;: Only short-term relationship values are exposed in the game state. Long-term relationship tracking is not currently available for modding.&lt;br /&gt;
&lt;br /&gt;
== Map Modding Tools ==&lt;br /&gt;
&lt;br /&gt;
While OpenApoc does not yet include a built-in map editor, several community tools exist for creating and editing maps:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;XME (Xenonaut Map Editor)&#039;&#039;&#039; &amp;amp;mdash; The primary tool for editing cityscape and alien dimension maps. Latest version: 095b1 (beta 1.0).&lt;br /&gt;
* &#039;&#039;&#039;TacEdit&#039;&#039;&#039; &amp;amp;mdash; A tool for validating that tactical maps are correctly structured and will load properly.&lt;br /&gt;
* &#039;&#039;&#039;A-Patcher&#039;&#039;&#039; &amp;amp;mdash; A hex-patching tool that can enable the hidden built-in map editor in the original X-COM: Apocalypse executable. Useful for creating maps compatible with OpenApoc&#039;s map format.&lt;br /&gt;
&lt;br /&gt;
== Community Mods ==&lt;br /&gt;
&lt;br /&gt;
The following mods serve as references for what OpenApoc&#039;s modding system can accomplish:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[https://github.com/OpenApoc/extended_weapons_mod Extended Weapons Mod (EWM)]&#039;&#039;&#039; by filmboy84 &amp;amp;mdash; The primary test platform for OpenApoc&#039;s modding system. Includes weapons ported from UFO: Enemy Unknown and Terror from the Deep, new alien types, over 2,000 additional agent names, and various balance adjustments.&lt;br /&gt;
* &#039;&#039;&#039;[https://github.com/Jarskih/openapoc-balance-mod OpenApoc Balance Mod]&#039;&#039;&#039; by Jarskih &amp;amp;mdash; Difficulty and balance adjustments.&lt;br /&gt;
&lt;br /&gt;
These mods are useful references for modders looking for real-world examples of mod structure, XML patching, and Lua scripting.&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[OpenApoc]] &amp;amp;mdash; Main OpenApoc page&lt;br /&gt;
* [[Differences to X-COM (OpenApoc)]] &amp;amp;mdash; How OpenApoc differs from the original game&lt;br /&gt;
* [[Installing (OpenApoc)]] &amp;amp;mdash; Installation instructions&lt;br /&gt;
* [[Compiling (OpenApoc)]] &amp;amp;mdash; Building from source&lt;br /&gt;
* [[Hidden Features (OpenApoc)]] &amp;amp;mdash; Hidden features and debug commands&lt;br /&gt;
* [[Apocalypse]] &amp;amp;mdash; The original X-COM: Apocalypse&lt;br /&gt;
* [https://github.com/ayrtondenner/OpenApoc-wiki/blob/master/openapoc/modding.md OpenApoc Wiki: Modding] &amp;amp;mdash; Extended modding documentation&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Coding_Style_(OpenApoc)&amp;diff=126344</id>
		<title>Coding Style (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Coding_Style_(OpenApoc)&amp;diff=126344"/>
		<updated>2026-03-01T23:05:58Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Re-add 9 coding conventions from CODE_STYLE.md that were missing: comments style, trivial one-line functions, ownership guidance, static_assert, iterator exception, forward declaration limits, Yoda conditionals, numeric_limits, short variable names&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{DISPLAYTITLE:Coding Style (OpenApoc)}}&lt;br /&gt;
This document specifies the guidelines for writing and formatting the C++ code that forms the core of &#039;&#039;&#039;[[OpenApoc]]&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
OpenApoc uses &#039;&#039;&#039;C++17&#039;&#039;&#039;. This requires reasonably modern compilers (&#039;&#039;&#039;GCC 8+&#039;&#039;&#039;, &#039;&#039;&#039;MSVC 2019+&#039;&#039;&#039;, &#039;&#039;&#039;Clang 7+&#039;&#039;&#039; have been tested). You should avoid using compiler-specific extensions where possible. Exceptions exist, but should be wrapped in an &amp;lt;code&amp;gt;#ifdef&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Code formatting is enforced by &#039;&#039;&#039;[https://clang.llvm.org/docs/ClangFormat.html clang-format]&#039;&#039;&#039; (version &#039;&#039;&#039;18&#039;&#039;&#039;). The configuration file &amp;lt;code&amp;gt;.clang-format&amp;lt;/code&amp;gt; in the root of the OpenApoc source repository defines the project style.&lt;br /&gt;
&lt;br /&gt;
Static analysis is enforced by &#039;&#039;&#039;[https://clang.llvm.org/extra/clang-tidy/ clang-tidy]&#039;&#039;&#039; (version &#039;&#039;&#039;18&#039;&#039;&#039;). The CI pipeline rejects unformatted code and code that fails tidy checks.&lt;br /&gt;
&lt;br /&gt;
It is highly recommended to run &amp;lt;code&amp;gt;clang-format&amp;lt;/code&amp;gt; on all modified files before committing:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;clang-format -i path/to/file.cpp path/to/file.h&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When run from the root of the OpenApoc source repository, it automatically uses the supplied &amp;lt;code&amp;gt;.clang-format&amp;lt;/code&amp;gt; configuration file.&lt;br /&gt;
&lt;br /&gt;
When using the CMake build system, there are dedicated targets:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Format all source files (from build directory)&lt;br /&gt;
cmake --build build -t format-sources&lt;br /&gt;
&lt;br /&gt;
# Run static analysis (from build directory)&lt;br /&gt;
cmake --build build -t tidy&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Indent ==&lt;br /&gt;
&lt;br /&gt;
* Tabs for indenting, spaces for alignment, indenting by 1 tab for each new scope&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
void function()&lt;br /&gt;
{&lt;br /&gt;
	reallyLongFunctionNameWithLotsOfArguments(argOne, argTwo,&lt;br /&gt;
	                                          argThree);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Avoid going over &#039;&#039;&#039;100 columns&#039;&#039;&#039; (at tab width of 4 spaces)&lt;br /&gt;
** If you find yourself going over this, it&#039;s often a hint to try to pull things out of loops / into functions&lt;br /&gt;
** Don&#039;t break strings up to fit this; it looks ugly and makes things harder to read&lt;br /&gt;
* If you have to break, indent the following line by an extra tab&lt;br /&gt;
** When breaking a single statement, break the line &#039;&#039;&#039;before&#039;&#039;&#039; the next operator. Avoid having an operator as the last thing on a line.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
void reallyLongFunctionNameIMeanThisIsReallyBadlyNamed(int parameterOne,&lt;br /&gt;
	int paramTwo, char theThirdOne)&lt;br /&gt;
{&lt;br /&gt;
	if (parameterOne == yetAnotherReallyLongCondition&lt;br /&gt;
		&amp;amp;&amp;amp; youHaveBetterThingsToDo)&lt;br /&gt;
	{&lt;br /&gt;
		doWhatever();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Whitespace ==&lt;br /&gt;
&lt;br /&gt;
* Spaces before and after operators&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	a = b;&lt;br /&gt;
	a &amp;amp;&amp;amp; b;&lt;br /&gt;
	a + b;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Space after &amp;lt;code&amp;gt;if&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;while&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;else&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;for&amp;lt;/code&amp;gt;, space after &amp;lt;code&amp;gt;:&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;;&amp;lt;/code&amp;gt; in &amp;lt;code&amp;gt;for&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	for (auto &amp;amp;a : b)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* No spaces after function name (or function-like keywords like &amp;lt;code&amp;gt;sizeof&amp;lt;/code&amp;gt;), but space after flow control keywords, space after comma for multiple arguments&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	func(a, b);&lt;br /&gt;
	if (a == 0)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* References and pointers: &amp;lt;code&amp;gt;&amp;amp;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;*&amp;lt;/code&amp;gt; align right (to the variable), not to the type&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	float *pointerToFloat;&lt;br /&gt;
	Type &amp;amp;ref;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Scope ==&lt;br /&gt;
&lt;br /&gt;
* Indent 1 tab for each new scope&lt;br /&gt;
* New scope is &#039;&#039;&#039;always&#039;&#039;&#039; surrounded by &amp;lt;code&amp;gt;{}&amp;lt;/code&amp;gt; braces, even for single-statement blocks&lt;br /&gt;
* Opening brace &amp;lt;code&amp;gt;{&amp;lt;/code&amp;gt; goes on the &#039;&#039;&#039;next&#039;&#039;&#039; line at the indent of the enclosing scope (&#039;&#039;&#039;Allman style&#039;&#039;&#039;)&lt;br /&gt;
* Closing brace &amp;lt;code&amp;gt;}&amp;lt;/code&amp;gt; at the same indent as the opening &amp;lt;code&amp;gt;{&amp;lt;/code&amp;gt;&lt;br /&gt;
* New scopes are caused by:&lt;br /&gt;
** Functions&lt;br /&gt;
** Conditional blocks (&amp;lt;code&amp;gt;if&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;else&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;while&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;for&amp;lt;/code&amp;gt;)&lt;br /&gt;
** &amp;lt;code&amp;gt;switch&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;case&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
void functionDefinition()&lt;br /&gt;
{&lt;br /&gt;
	newScopeHere();&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	if (x)&lt;br /&gt;
	{&lt;br /&gt;
		doWhatever();&lt;br /&gt;
	}&lt;br /&gt;
	else if (y)&lt;br /&gt;
	{&lt;br /&gt;
		doWhateverTheSecond();&lt;br /&gt;
	}&lt;br /&gt;
	else&lt;br /&gt;
	{&lt;br /&gt;
		doThatLastThing();&lt;br /&gt;
	}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;switch&amp;lt;/code&amp;gt; always has a &amp;lt;code&amp;gt;default&amp;lt;/code&amp;gt; case unless switching over an &amp;lt;code&amp;gt;enum class&amp;lt;/code&amp;gt; where every value is handled&lt;br /&gt;
* All &amp;lt;code&amp;gt;case&amp;lt;/code&amp;gt; sections should have a &amp;lt;code&amp;gt;break&amp;lt;/code&amp;gt;&lt;br /&gt;
* &amp;lt;code&amp;gt;case&amp;lt;/code&amp;gt; braces &amp;lt;code&amp;gt;{}&amp;lt;/code&amp;gt; are optional, based on whether new stack variables are needed&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	switch (a)&lt;br /&gt;
	{&lt;br /&gt;
		case A:&lt;br /&gt;
			doSomething();&lt;br /&gt;
			break;&lt;br /&gt;
		case B:&lt;br /&gt;
		{&lt;br /&gt;
			auto newVariable = getSomething();&lt;br /&gt;
			useIt(newVariable);&lt;br /&gt;
			break;&lt;br /&gt;
		}&lt;br /&gt;
		default:&lt;br /&gt;
			break;&lt;br /&gt;
	}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Exception&#039;&#039;&#039;: Trivial functions (a single statement fitting within 100 columns) may use the definition and body on one line:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
int getX() const { return x; }&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This is enforced by &amp;lt;code&amp;gt;clang-format&amp;lt;/code&amp;gt; (&amp;lt;code&amp;gt;AllowShortFunctionsOnASingleLine: All&amp;lt;/code&amp;gt;).&lt;br /&gt;
&lt;br /&gt;
== Naming ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Style !! Used For&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;CamelCase&amp;lt;/code&amp;gt; || Classes, enums, &amp;lt;code&amp;gt;enum class&amp;lt;/code&amp;gt; members, namespaces, template parameters&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;camelBack&amp;lt;/code&amp;gt; || Methods, member variables, function parameters, local variables&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;SHOUTY_CAPS&amp;lt;/code&amp;gt; || Constants, macros&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;lower_case&amp;lt;/code&amp;gt; || Labels&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Short variable names (&amp;lt;code&amp;gt;i&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;x&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;y&amp;lt;/code&amp;gt;) are fine when the meaning is obvious from context.&lt;br /&gt;
&lt;br /&gt;
== Types ==&lt;br /&gt;
&lt;br /&gt;
* Use &amp;lt;code&amp;gt;auto&amp;lt;/code&amp;gt; liberally, especially when the type is obvious from the right-hand side. Use &amp;lt;code&amp;gt;auto &amp;amp;&amp;lt;/code&amp;gt; to avoid copies.&lt;br /&gt;
* Use &amp;lt;code&amp;gt;enum class&amp;lt;/code&amp;gt; over plain &amp;lt;code&amp;gt;enum&amp;lt;/code&amp;gt;&lt;br /&gt;
* Use &amp;lt;code&amp;gt;struct&amp;lt;/code&amp;gt; only for data-only types; structs must &#039;&#039;&#039;never&#039;&#039;&#039; use access modifiers&lt;br /&gt;
* No C-style casts &amp;amp;mdash; use &amp;lt;code&amp;gt;static_cast&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;dynamic_cast&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;reinterpret_cast&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
* Prefer &amp;lt;code&amp;gt;{}&amp;lt;/code&amp;gt; brace initialization&lt;br /&gt;
* Prefer &amp;lt;code&amp;gt;std::numeric_limits&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt; over C-style &amp;lt;code&amp;gt;MAX_INT&amp;lt;/code&amp;gt; / &amp;lt;code&amp;gt;INT_MAX&amp;lt;/code&amp;gt; macros&lt;br /&gt;
&lt;br /&gt;
== Smart Pointers ==&lt;br /&gt;
&lt;br /&gt;
OpenApoc provides short aliases in &amp;lt;code&amp;gt;library/sp.h&amp;lt;/code&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Alias !! Equivalent&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;sp&amp;amp;lt;T&amp;amp;gt;&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;std::shared_ptr&amp;amp;lt;T&amp;amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;up&amp;amp;lt;T&amp;amp;gt;&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;std::unique_ptr&amp;amp;lt;T&amp;amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;wp&amp;amp;lt;T&amp;amp;gt;&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;std::weak_ptr&amp;amp;lt;T&amp;amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;mksp&amp;amp;lt;T&amp;amp;gt;(args...)&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;std::make_shared&amp;amp;lt;T&amp;amp;gt;(args...)&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;mkup&amp;amp;lt;T&amp;amp;gt;(args...)&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;std::make_unique&amp;amp;lt;T&amp;amp;gt;(args...)&amp;lt;/code&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;No naked &amp;lt;code&amp;gt;new&amp;lt;/code&amp;gt;&#039;&#039;&#039; &amp;amp;mdash; always wrap in smart pointers immediately&lt;br /&gt;
* Prefer &amp;lt;code&amp;gt;up&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt; (exclusive ownership) over &amp;lt;code&amp;gt;sp&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt; unless shared ownership is genuinely needed&lt;br /&gt;
* Use &amp;lt;code&amp;gt;std::move()&amp;lt;/code&amp;gt; to transfer &amp;lt;code&amp;gt;up&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt; ownership&lt;br /&gt;
* &#039;&#039;&#039;Ownership guideline&#039;&#039;&#039;: If ownership of a member is tied to the class, use a direct member (no pointer). If a reference owned by another object is guaranteed to outlive the class, use a &amp;lt;code&amp;gt;&amp;amp;amp;reference&amp;lt;/code&amp;gt; member. Otherwise use &amp;lt;code&amp;gt;up&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;sp&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt; depending on whether ownership is exclusive or shared.&lt;br /&gt;
&lt;br /&gt;
== Templates ==&lt;br /&gt;
&lt;br /&gt;
* Template type parameters should use &amp;lt;code&amp;gt;CamelCase&amp;lt;/code&amp;gt;&lt;br /&gt;
* Place &amp;lt;code&amp;gt;template&amp;amp;lt;...&amp;amp;gt;&amp;lt;/code&amp;gt; on the line above the function/class declaration&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
template &amp;lt;typename ValueType&amp;gt;&lt;br /&gt;
ValueType doSomething(ValueType input)&lt;br /&gt;
{&lt;br /&gt;
	return input;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Class Declarations ==&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;public:&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;private:&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;protected:&amp;lt;/code&amp;gt; written at class indent level (not indented further)&lt;br /&gt;
* Always explicitly write &amp;lt;code&amp;gt;private:&amp;lt;/code&amp;gt;, even though it is the default&lt;br /&gt;
* &amp;lt;code&amp;gt;virtual&amp;lt;/code&amp;gt; only on the base class; &amp;lt;code&amp;gt;override&amp;lt;/code&amp;gt; on derived classes &amp;amp;mdash; never both together&lt;br /&gt;
* All classes with virtual methods must have a virtual destructor&lt;br /&gt;
* Use &amp;lt;code&amp;gt;= default&amp;lt;/code&amp;gt; instead of empty &amp;lt;code&amp;gt;{}&amp;lt;/code&amp;gt; constructor/destructor bodies&lt;br /&gt;
* Use member initializer lists; initializer order must match declaration order&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class MyClass : public BaseClass&lt;br /&gt;
{&lt;br /&gt;
private:&lt;br /&gt;
	int memberVariable = 0;&lt;br /&gt;
	UString name;&lt;br /&gt;
public:&lt;br /&gt;
	MyClass() = default;&lt;br /&gt;
	~MyClass() override = default;&lt;br /&gt;
&lt;br /&gt;
	void doSomething() override;&lt;br /&gt;
	int getValue() const;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Functions ==&lt;br /&gt;
&lt;br /&gt;
* Functions should be named &amp;lt;code&amp;gt;camelBack&amp;lt;/code&amp;gt;&lt;br /&gt;
* Use &#039;&#039;&#039;early return&#039;&#039;&#039; &amp;amp;mdash; prefer separate &amp;lt;code&amp;gt;if (cond) return;&amp;lt;/code&amp;gt; checks over deeply nested conditionals&lt;br /&gt;
* &#039;&#039;&#039;&amp;lt;code&amp;gt;const&amp;lt;/code&amp;gt; aggressively&#039;&#039;&#039;: const member functions, const parameters, const return types, const local variables&lt;br /&gt;
* Range-for loops: &amp;lt;code&amp;gt;for (auto &amp;amp;element : container)&amp;lt;/code&amp;gt; / &amp;lt;code&amp;gt;for (const auto &amp;amp;element : container)&amp;lt;/code&amp;gt;&lt;br /&gt;
** &#039;&#039;&#039;Exception&#039;&#039;&#039;: When removing elements during iteration, use an iterator-based loop instead of range-for&lt;br /&gt;
* Prefer &amp;lt;code&amp;gt;emplace()&amp;lt;/code&amp;gt; over &amp;lt;code&amp;gt;insert()&amp;lt;/code&amp;gt; in STL containers&lt;br /&gt;
&lt;br /&gt;
== General Code ==&lt;br /&gt;
&lt;br /&gt;
* Use anonymous namespaces instead of &amp;lt;code&amp;gt;static&amp;lt;/code&amp;gt; for file-local functions and classes&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
namespace&lt;br /&gt;
{&lt;br /&gt;
void helperFunction()&lt;br /&gt;
{&lt;br /&gt;
	// file-local helper&lt;br /&gt;
}&lt;br /&gt;
} // anonymous namespace&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* All project code lives in &amp;lt;code&amp;gt;namespace OpenApoc {}&amp;lt;/code&amp;gt;. Namespace content is &#039;&#039;&#039;not&#039;&#039;&#039; indented. Closing brace gets a comment:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
namespace OpenApoc&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
class MyClass&lt;br /&gt;
{&lt;br /&gt;
	// ...&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
} // namespace OpenApoc&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Use &amp;lt;code&amp;gt;static_assert()&amp;lt;/code&amp;gt; to verify assumptions about alignment, packing (e.g., when reading structs from original game files), or template restrictions&lt;br /&gt;
* Avoid Yoda conditionals &amp;amp;mdash; write &amp;lt;code&amp;gt;var == 1&amp;lt;/code&amp;gt;, not &amp;lt;code&amp;gt;1 == var&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Comments ==&lt;br /&gt;
&lt;br /&gt;
* Prefer &amp;lt;code&amp;gt;//&amp;lt;/code&amp;gt; for single-line comments&lt;br /&gt;
* Multi-line &amp;lt;code&amp;gt;/* */&amp;lt;/code&amp;gt; comments: align the &amp;lt;code&amp;gt;*&amp;lt;/code&amp;gt; on each intermediate line&lt;br /&gt;
* Use &amp;lt;code&amp;gt;//TODO:&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;//FIXME:&amp;lt;/code&amp;gt; markers to flag work-in-progress or known issues&lt;br /&gt;
* Do not comment for the sake of it &amp;amp;mdash; if the code can be made clearer, prefer that over adding a comment&lt;br /&gt;
&lt;br /&gt;
== Logging ==&lt;br /&gt;
&lt;br /&gt;
Uses &#039;&#039;&#039;fmt-style format strings&#039;&#039;&#039; with positional &amp;lt;code&amp;gt;{0}&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;{1}&amp;lt;/code&amp;gt; placeholders (&#039;&#039;&#039;not&#039;&#039;&#039; printf-style):&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#include &amp;quot;framework/logger.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
LogInfo(&amp;quot;Loaded mod \&amp;quot;{0}\&amp;quot;&amp;quot;, modName);&lt;br /&gt;
LogWarning(&amp;quot;Value {0} exceeds limit {1}&amp;quot;, value, limit);&lt;br /&gt;
LogError(&amp;quot;Failed to load file \&amp;quot;{0}\&amp;quot;&amp;quot;, path);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;LogInfo&amp;lt;/code&amp;gt; &amp;amp;mdash; general information&lt;br /&gt;
* &amp;lt;code&amp;gt;LogWarning&amp;lt;/code&amp;gt; &amp;amp;mdash; recoverable errors&lt;br /&gt;
* &amp;lt;code&amp;gt;LogError&amp;lt;/code&amp;gt; &amp;amp;mdash; fatal errors&lt;br /&gt;
&lt;br /&gt;
== Strings ==&lt;br /&gt;
&lt;br /&gt;
Use &#039;&#039;&#039;&amp;lt;code&amp;gt;UString&amp;lt;/code&amp;gt;&#039;&#039;&#039; (from &amp;lt;code&amp;gt;library/strings.h&amp;lt;/code&amp;gt;) for all strings. All &amp;lt;code&amp;gt;char*&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;std::string&amp;lt;/code&amp;gt; values are assumed UTF-8.&lt;br /&gt;
&lt;br /&gt;
String formatting uses the &amp;lt;code&amp;gt;fmt&amp;lt;/code&amp;gt; library:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#include &amp;quot;library/strings_format.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
UString result = OpenApoc::format(&amp;quot;Player has {0} credits and {1} agents&amp;quot;, credits, agentCount);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Translation:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
UString translated = tr(&amp;quot;English text to translate&amp;quot;);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Includes and Headers ==&lt;br /&gt;
&lt;br /&gt;
* Use &amp;lt;code&amp;gt;#pragma once&amp;lt;/code&amp;gt; (no traditional include guards)&lt;br /&gt;
* &#039;&#039;&#039;Include order&#039;&#039;&#039;: Local headers first, then system headers. Each block alphabetically sorted.&lt;br /&gt;
* Local headers use paths &#039;&#039;&#039;relative to the OpenApoc root&#039;&#039;&#039;: &amp;lt;code&amp;gt;&amp;quot;framework/logger.h&amp;quot;&amp;lt;/code&amp;gt;, not &amp;lt;code&amp;gt;&amp;quot;../logger.h&amp;quot;&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;&amp;quot;logger.h&amp;quot;&amp;lt;/code&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;Prefer forward declarations&#039;&#039;&#039; over &amp;lt;code&amp;gt;#include&amp;lt;/code&amp;gt; in headers where possible&lt;br /&gt;
** Forward declarations are &#039;&#039;&#039;not possible&#039;&#039;&#039; for templates, non-class types (e.g., &amp;lt;code&amp;gt;enum class&amp;lt;/code&amp;gt;), and superclasses. When in doubt, try building without the include and see what fails.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#pragma once&lt;br /&gt;
&lt;br /&gt;
#include &amp;quot;library/sp.h&amp;quot;&lt;br /&gt;
#include &amp;quot;library/strings.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;vector&amp;gt;&lt;br /&gt;
&lt;br /&gt;
namespace OpenApoc&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
class ForwardDeclaredType;&lt;br /&gt;
&lt;br /&gt;
class MyClass&lt;br /&gt;
{&lt;br /&gt;
private:&lt;br /&gt;
	int member = 0;&lt;br /&gt;
public:&lt;br /&gt;
	void publicFunction();&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
} // namespace OpenApoc&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Key Review Expectations ==&lt;br /&gt;
&lt;br /&gt;
These patterns are consistently enforced during code review:&lt;br /&gt;
&lt;br /&gt;
# &#039;&#039;&#039;const correctness&#039;&#039;&#039; &amp;amp;mdash; if something can be &amp;lt;code&amp;gt;const&amp;lt;/code&amp;gt;, it must be &amp;lt;code&amp;gt;const&amp;lt;/code&amp;gt;&lt;br /&gt;
# &#039;&#039;&#039;Readable conditionals&#039;&#039;&#039; &amp;amp;mdash; avoid embedded comments in complex conditionals; prefer early-exit checks&lt;br /&gt;
# &#039;&#039;&#039;One logical change per PR&#039;&#039;&#039; &amp;amp;mdash; keep changes focused for clean history and bisectability&lt;br /&gt;
# &#039;&#039;&#039;Use &amp;lt;code&amp;gt;auto&amp;lt;/code&amp;gt;&#039;&#039;&#039; &amp;amp;mdash; when the type is already visible on the RHS&lt;br /&gt;
# &#039;&#039;&#039;Prefer exclusive ownership&#039;&#039;&#039; &amp;amp;mdash; use &amp;lt;code&amp;gt;up&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt; over &amp;lt;code&amp;gt;sp&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt; when shared ownership is not required&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[OpenApoc]] &amp;amp;mdash; Main OpenApoc page&lt;br /&gt;
* [[Compiling (OpenApoc)]] &amp;amp;mdash; Build instructions for developers&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc/blob/master/CODE_STYLE.md CODE_STYLE.md] &amp;amp;mdash; Full coding style specification in the repository&lt;br /&gt;
* [https://github.com/ayrtondenner/OpenApoc-wiki/blob/master/development/coding-style.md OpenApoc Wiki: Coding Style] &amp;amp;mdash; Extended coding style documentation&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc OpenApoc on GitHub] &amp;amp;mdash; Source code repository&lt;br /&gt;
* [https://discord.gg/f8Rayre OpenApoc Discord] &amp;amp;mdash; Community discussion and support&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Hidden_Features_(OpenApoc)&amp;diff=126343</id>
		<title>Hidden Features (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Hidden_Features_(OpenApoc)&amp;diff=126343"/>
		<updated>2026-03-01T23:05:23Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Major rewrite: documented full debug mode and cheat system with hotkey tables&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;OpenApoc includes an extensive &#039;&#039;&#039;debug and cheat system&#039;&#039;&#039; not present in the original game. Debug hotkeys are toggled with &#039;&#039;&#039;F1&#039;&#039;&#039; in both the Cityscape and Battlescape. When enabled, various diagnostic and cheat functions become available.&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; The &amp;quot;Show debug commands on screen&amp;quot; option in the More Options menu controls whether debug command buttons are visible in the UI.&lt;br /&gt;
&lt;br /&gt;
== General Debug ==&lt;br /&gt;
&lt;br /&gt;
Press &#039;&#039;&#039;F1&#039;&#039;&#039; to toggle debug mode on/off. When debug mode is active, some normal hotkeys are overridden by debug functions.&lt;br /&gt;
&lt;br /&gt;
== Cityscape Debug ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Alt + Shift + Left Click || Destroy scenery tile at cursor&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Alt + Shift + Right Click || Collapse building at cursor&lt;br /&gt;
|-&lt;br /&gt;
| A || Give every vehicle weapon and ammo to current base&lt;br /&gt;
|-&lt;br /&gt;
| W || Warp to alien dimension and back&lt;br /&gt;
|-&lt;br /&gt;
| R || Repair all scenery in the city (instant, ignores repair rules)&lt;br /&gt;
|-&lt;br /&gt;
| Shift + R || Repair scenery using game repair logic (charges building owners, checks support) without requiring construction vehicles; single repair pass&lt;br /&gt;
|-&lt;br /&gt;
| B || Spawn UFO on base assault mission&lt;br /&gt;
|-&lt;br /&gt;
| U || Spawn three crashed UFOs&lt;br /&gt;
|-&lt;br /&gt;
| X || Crash every vehicle on map&lt;br /&gt;
|-&lt;br /&gt;
| - (Minus) || Destroy all currently selected vehicles (both owned and other)&lt;br /&gt;
|-&lt;br /&gt;
| P || Regenerate dimension gate portals in current city&lt;br /&gt;
|-&lt;br /&gt;
| PgUp / PgDown || Display only one map layer (other layers become transparent)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Diagnostic Overlays ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| F2 || Show road pathfinding map&lt;br /&gt;
|-&lt;br /&gt;
| F3 || Highlight walk mode, collapsing tiles, basement tiles&lt;br /&gt;
|-&lt;br /&gt;
| F4 || Show aliens in buildings on strategy map&lt;br /&gt;
|-&lt;br /&gt;
| F5 || Show vehicle paths (blue = flying, yellow = ground)&lt;br /&gt;
|-&lt;br /&gt;
| F6 || Dump voxelmap for line of sight to tileviewvoxels.png&lt;br /&gt;
|-&lt;br /&gt;
| F7 || Dump voxelmap for line of sight to tileviewvoxels.png (fast mode, 1/4 of points)&lt;br /&gt;
|-&lt;br /&gt;
| F8 || Dump voxelmap for line of fire to tileviewvoxels.png&lt;br /&gt;
|-&lt;br /&gt;
| F9 || Dump voxelmap for line of fire to tileviewvoxels.png (fast mode, 1/4 of points)&lt;br /&gt;
|-&lt;br /&gt;
| F10 || Highlight tubes in city&lt;br /&gt;
|-&lt;br /&gt;
| F11 || Highlight roads in city&lt;br /&gt;
|-&lt;br /&gt;
| F12 || Highlight hills in city&lt;br /&gt;
|-&lt;br /&gt;
| T || Show vehicle target lines (green = X-COM targeting, red = other targeting, yellow = mutual targeting)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Numpad Filters ===&lt;br /&gt;
&lt;br /&gt;
These filters work with the F10/F11/F12 overlays:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Numpad 1, 3, 7, 9 || Show only roads/tubes with an outgoing connection in that direction&lt;br /&gt;
|-&lt;br /&gt;
| Numpad 2 || Show only tubes with an outgoing connection downward&lt;br /&gt;
|-&lt;br /&gt;
| Numpad 8 || Show only tubes with an outgoing connection upward&lt;br /&gt;
|-&lt;br /&gt;
| Numpad 0 || Show all roads/tubes again (reset filter)&lt;br /&gt;
|-&lt;br /&gt;
| Numpad 5 || Toggle display mode:&lt;br /&gt;
* For tubes: switch between tiles with defined tube passability, or also include tiles belonging to buildings&lt;br /&gt;
* For roads: switch between tiles marked as &amp;quot;road&amp;quot;, or also include tiles marked with road direction&lt;br /&gt;
* For hills: switch between tiles marked as &amp;quot;road&amp;quot;, or also include tiles marked with hill direction&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Battlescape Debug ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Middle Click || Activate teleportation mode for selected unit (regardless of whether it holds a charged teleporter)&lt;br /&gt;
|-&lt;br /&gt;
| E || Force end current turn in turn-based mode&lt;br /&gt;
|-&lt;br /&gt;
| R || Reveal whole map and show debug lines for which unit sees which unit&lt;br /&gt;
|-&lt;br /&gt;
| S || Stun unit under cursor&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + S || Stun units in small area around cursor&lt;br /&gt;
|-&lt;br /&gt;
| Shift + S || Stun everything &#039;&#039;&#039;except&#039;&#039;&#039; unit under cursor&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Ctrl + S || Stun everything &#039;&#039;&#039;except&#039;&#039;&#039; units in small area around cursor&lt;br /&gt;
|-&lt;br /&gt;
| K || Remove unit under cursor from map (same modifiers as S — Ctrl for area, Shift for inverse). Units count as retreated.&lt;br /&gt;
|-&lt;br /&gt;
| P || Lower morale of every unit to trigger low morale events&lt;br /&gt;
|-&lt;br /&gt;
| Shift + P || Give every unit 0 psi defense and 100 psi energy/attack&lt;br /&gt;
|-&lt;br /&gt;
| H || Restore stats of every unit, heal stun damage and fatal wounds&lt;br /&gt;
|-&lt;br /&gt;
| T || Restore TU of every player unit&lt;br /&gt;
|-&lt;br /&gt;
| F || Re-link support lines for battlescape map parts&lt;br /&gt;
|-&lt;br /&gt;
| Q || Reset AI movement order for unit at selected tile (forces prone stance change)&lt;br /&gt;
|-&lt;br /&gt;
| Numpad 0 || Spawn vortex mine explosion at cursor&lt;br /&gt;
|-&lt;br /&gt;
| Numpad 1-9 || Spawn a high-damage shot at cursor in specified direction (5 = downward)&lt;br /&gt;
|-&lt;br /&gt;
| F6 || Dump voxelmap for line of sight to tileviewvoxels.png&lt;br /&gt;
|-&lt;br /&gt;
| F7 || Dump voxelmap for line of sight (fast mode, 1/4 of points)&lt;br /&gt;
|-&lt;br /&gt;
| F8 || Dump voxelmap for line of fire to tileviewvoxels.png&lt;br /&gt;
|-&lt;br /&gt;
| F9 || Dump voxelmap for line of fire (fast mode, 1/4 of points)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Base Screen Debug ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| F10 (on Base View) || Instantly finish all facility construction&lt;br /&gt;
|-&lt;br /&gt;
| F10 (on Research Screen) || Set research project to require only 100 more points (effectively completes the project at next update if at least 2 scientists are assigned)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Cheat Menu ==&lt;br /&gt;
&lt;br /&gt;
In addition to debug hotkeys, OpenApoc provides a dedicated &#039;&#039;&#039;Cheat Options&#039;&#039;&#039; screen accessible from the More Options menu:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Option !! Description !! Default&lt;br /&gt;
|-&lt;br /&gt;
| Infinite Ammo || Unlimited ammunition for all X-COM agents and vehicles || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Damage Inflicted Multiplier || Multiplier for damage dealt by X-COM (0x - 5x) || 1.0x&lt;br /&gt;
|-&lt;br /&gt;
| Damage Received Multiplier || Multiplier for damage taken by X-COM (0x - 5x) || 1.0x&lt;br /&gt;
|-&lt;br /&gt;
| Hostiles Multiplier || Multiplier for number of hostile units spawned (0.5x - 3x) || 1.0x&lt;br /&gt;
|-&lt;br /&gt;
| Stat Growth Multiplier || Multiplier for agent stat growth rate (0x - 99.5x) || 1.0x&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Additional cheat buttons available:&lt;br /&gt;
* Give All Research&lt;br /&gt;
* Make All Organizations Friendly / Hostile&lt;br /&gt;
* Make All Organizations Utopia / Chaos&lt;br /&gt;
* Modify Funds&lt;br /&gt;
* Go to End of Day — advance clock to 23:59:59 of current day&lt;br /&gt;
* Go Forward 1 Day — skip exactly 1 day forward&lt;br /&gt;
* Go Forward 1 Week — skip exactly 7 days forward&lt;br /&gt;
* Go to End of Week — advance to last day of current week at 23:59:59&lt;br /&gt;
* Go to End of Month — advance to last day of current month at 23:59:59&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[Controls (OpenApoc)]] — standard (non-debug) controls&lt;br /&gt;
* [[Improvements (OpenApoc)]] — toggle-able gameplay improvements&lt;br /&gt;
* [https://github.com/ayrtondenner/OpenApoc-wiki/blob/master/openapoc/debug-mode.md OpenApoc Wiki: Debug Mode] &amp;amp;mdash; Extended debug and hidden features documentation&lt;br /&gt;
* [[OpenApoc]] — main OpenApoc page&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Controls_(OpenApoc)&amp;diff=126342</id>
		<title>Controls (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Controls_(OpenApoc)&amp;diff=126342"/>
		<updated>2026-03-01T22:48:54Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Expand Space key examples, add Ctrl-additive selection notes, add More Options feature toggle references&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;OpenApoc aims to implement all controls from the original game while introducing new hotkeys to improve interface usability. A key addition is the &#039;&#039;&#039;improved city control scheme&#039;&#039;&#039; — a completely new, consistent control system using modifier keys. This can be disabled via the &amp;quot;Improved city control scheme&amp;quot; option in the More Options menu to restore vanilla behavior.&lt;br /&gt;
&lt;br /&gt;
For debug and cheat hotkeys, see [[Hidden Features (OpenApoc)]].&lt;br /&gt;
&lt;br /&gt;
== General UI Hotkeys ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Mousewheel || Scroll lists&lt;br /&gt;
|-&lt;br /&gt;
| Esc || Go back, close form, &amp;quot;Cancel&amp;quot; option&lt;br /&gt;
|-&lt;br /&gt;
| Enter || Go forward, &amp;quot;Confirm&amp;quot; option, first option (e.g., real-time in briefing)&lt;br /&gt;
|-&lt;br /&gt;
| Space || Skip, second non-cancel option (e.g., &amp;quot;No&amp;quot; in &amp;quot;Yes/No/Cancel&amp;quot; dialogue, equip button in squad assignment, checkbox to pause when event happens again, turn-based in briefing)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== General Hotkeys ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Middle Click || Move camera to location&lt;br /&gt;
|-&lt;br /&gt;
| Arrow Keys || Move camera around&lt;br /&gt;
|-&lt;br /&gt;
| Tab || Toggle map&lt;br /&gt;
|-&lt;br /&gt;
| Space || Pause / Resume time (including turn-based)&lt;br /&gt;
|-&lt;br /&gt;
| Esc || Options menu&lt;br /&gt;
|-&lt;br /&gt;
| C || Toggle follow mode&lt;br /&gt;
|-&lt;br /&gt;
| M || Show message log&lt;br /&gt;
|-&lt;br /&gt;
| Home || Zoom to last event&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Cityscape Controls ==&lt;br /&gt;
&lt;br /&gt;
=== Vanilla Controls Note ===&lt;br /&gt;
&lt;br /&gt;
The original game&#039;s city controls were inconsistent and limited:&lt;br /&gt;
* Right-clicking moved the map in city but not in battle&lt;br /&gt;
* No quick access to frequently used screens (equipment, location, base)&lt;br /&gt;
* Alt/Shift hotkeys acted as if clicking a corresponding button — missing a target changed your selection mode&lt;br /&gt;
&lt;br /&gt;
OpenApoc introduces a new, consistent control scheme explained below. To restore vanilla controls, disable &amp;quot;Improved city control scheme&amp;quot; in the More Options menu. With vanilla controls:&lt;br /&gt;
* Right click moves screen to cursor&lt;br /&gt;
* Alt + Left Click orders vehicle attack&lt;br /&gt;
* Shift + Left Click orders moving to building&lt;br /&gt;
* Left-clicking on building always opens building screen&lt;br /&gt;
* No OpenApoc mouse controls will function&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Mouse (Improved Scheme) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Left Click on building || Open building screen (base screen if it contains a base)&lt;br /&gt;
|-&lt;br /&gt;
| Right Click on building || Open building screen&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Left Click || Order attack vehicle&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Right Click || Order follow vehicle / go to location&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Shift + Left Click || Order attack building&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Shift + Right Click || Order go to building&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Left Click || Open UFOpaedia for object (vehicle type, building function, or projectile source)&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Right Click || Open UFOpaedia for object&#039;s owner (vehicle or building)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Modifier Keys ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Modifier !! Effect&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl (agent move orders) || Force agents to move on foot (never call taxi); allows use of personal teleporter&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl (vehicle move orders) || Allow manual use of city teleporter buildings&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl (attack orders) || Force vehicles to attack target (instead of recovering UFOs or escorting owned vehicles)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; In vanilla, attacking owned vehicles was impossible. OpenApoc enables this via the &amp;lt;code&amp;gt;OpenApoc.NewFeature.AllowAttackingOwnedVehicles&amp;lt;/code&amp;gt; option (on by default).&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Mouse on Vehicle / Agent Icons ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Right Click || Open location screen&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Shift + Right Click || Open equipment screen&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Shift + Right Click || Open equipment screen&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Unit Selection ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Left Click || Select agent/vehicle (as the only object selected)&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Left Click || Add agent/vehicle to selection and make it first in the list&lt;br /&gt;
|-&lt;br /&gt;
| Right Click || Remove agent/vehicle from selection&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; Ctrl makes selection additive.&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Keyboard ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| 0, 1, 2, 3, 4, 5 || Control game speed&lt;br /&gt;
|-&lt;br /&gt;
| N || Manual control (with vanilla scheme: M is manual control and there is no way to open message log)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Vehicle Equipment ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Click || Auto-equip item into first available slot, or auto-remove to base stores&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Agent Equipment ==&lt;br /&gt;
&lt;br /&gt;
Standard selection controls apply, with the option to de-select with right click.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Click || Auto-equip item into first available slot, or auto-remove to base stores / ground&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Click on weapon || Remove clip from weapon&lt;br /&gt;
|-&lt;br /&gt;
| 1 through 0 || Apply saved equipment template to every selected agent&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + 1 through 0 || Remember current agent&#039;s equipment set as a template&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; Equipment templates require the &amp;lt;code&amp;gt;OpenApoc.NewFeature.EnableAgentTemplates&amp;lt;/code&amp;gt; option (enabled by default).&lt;br /&gt;
&lt;br /&gt;
== Battlescape Mouse ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Left Click || Order unit to execute action (move / throw / psi attack / teleport), open probed unit&#039;s screen, use item&lt;br /&gt;
|-&lt;br /&gt;
| Right Click || Turn towards cursor, focus enemy (real-time), use item&#039;s &amp;quot;auto&amp;quot; function (e.g., prime grenade for impact)&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Left Click || Force-fire at target tile, shot moving parallel to ground&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Alt + Left Click || Force-fire at target tile, shot aimed at tile&#039;s ground&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Modifier Keys ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Modifier !! Effect&lt;br /&gt;
|-&lt;br /&gt;
| Alt (movement) || Unit keeps facing the target while moving (strafing or moving backwards)&lt;br /&gt;
|-&lt;br /&gt;
| Alt (firing at tile) || Shot aims at the ground of the tile rather than at the unit&#039;s level&lt;br /&gt;
|-&lt;br /&gt;
| Shift || Turns cursor into attack mode&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Battlescape Unit Selection ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Left Click || Select unit (as the only unit selected)&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Left Click || Add unit to selection and make it first in the list&lt;br /&gt;
|-&lt;br /&gt;
| Right Click || Remove unit from selection&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; Ctrl makes selection additive.&lt;br /&gt;
&lt;br /&gt;
== Battlescape Keyboard ==&lt;br /&gt;
&lt;br /&gt;
=== Movement and Fire Modes ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| PgUp / PgDown || Change map levels&lt;br /&gt;
|-&lt;br /&gt;
| V || Toggle layering&lt;br /&gt;
|-&lt;br /&gt;
| F2 || Prone mode&lt;br /&gt;
|-&lt;br /&gt;
| F3 || Walk mode&lt;br /&gt;
|-&lt;br /&gt;
| F4 || Run mode&lt;br /&gt;
|-&lt;br /&gt;
| F5 || Cease fire mode&lt;br /&gt;
|-&lt;br /&gt;
| F6 || Aimed mode&lt;br /&gt;
|-&lt;br /&gt;
| F7 || Snap mode&lt;br /&gt;
|-&lt;br /&gt;
| F8 || Auto mode&lt;br /&gt;
|-&lt;br /&gt;
| F9 || Evasive mode&lt;br /&gt;
|-&lt;br /&gt;
| F10 || Normal mode&lt;br /&gt;
|-&lt;br /&gt;
| F11 || Aggressive mode&lt;br /&gt;
|-&lt;br /&gt;
| Backspace || Kneel mode&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Squad and Unit Selection ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| 1 through 6 || Select squad&lt;br /&gt;
|-&lt;br /&gt;
| Shift + 1 through 6 || Select unit in current squad (as the only unit selected)&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Ctrl + 1 through 6 || Add unit to selection and make it first in the list&lt;br /&gt;
|-&lt;br /&gt;
| Alt + 1 through 6 || Cycle through spotted enemies of the selected unit&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Actions ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Enter || Open inventory&lt;br /&gt;
|-&lt;br /&gt;
| [ || Throw right hand item&lt;br /&gt;
|-&lt;br /&gt;
| ] || Throw left hand item&lt;br /&gt;
|-&lt;br /&gt;
| &#039; || Drop right hand item&lt;br /&gt;
|-&lt;br /&gt;
| &amp;amp;#92; || Drop left hand item&lt;br /&gt;
|-&lt;br /&gt;
| Y || Confirm priming&lt;br /&gt;
|-&lt;br /&gt;
| N || Cancel priming&lt;br /&gt;
|-&lt;br /&gt;
| E || End your turn (turn-based mode)&lt;br /&gt;
|-&lt;br /&gt;
| S || Open save menu&lt;br /&gt;
|-&lt;br /&gt;
| L || Open load menu&lt;br /&gt;
|-&lt;br /&gt;
| J || Make unit jump (down from a cliff)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Notes ==&lt;br /&gt;
&lt;br /&gt;
Some controls are affected by options in the &#039;&#039;&#039;More Options&#039;&#039;&#039; menu:&lt;br /&gt;
* &amp;lt;code&amp;gt;OpenApoc.NewFeature.BattlescapeVertScroll&amp;lt;/code&amp;gt; &amp;amp;mdash; mousewheel changes vertical level in the battlescape&lt;br /&gt;
* &amp;lt;code&amp;gt;OpenApoc.NewFeature.SingleSquadSelect&amp;lt;/code&amp;gt; &amp;amp;mdash; single-click squad button selects squad (instead of requiring double-click)&lt;br /&gt;
* &amp;lt;code&amp;gt;OpenApoc.NewFeature.LeftClickIconEquip&amp;lt;/code&amp;gt; &amp;amp;mdash; left-clicking a vehicle/agent icon opens the equipment screen&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[Hidden Features (OpenApoc)]] — debug hotkeys and cheat system&lt;br /&gt;
* [[Improvements (OpenApoc)]] — toggle-able gameplay improvements&lt;br /&gt;
* [https://github.com/ayrtondenner/OpenApoc-wiki/blob/master/openapoc/controls.md OpenApoc Wiki: Controls] &amp;amp;mdash; Extended controls documentation&lt;br /&gt;
* [[OpenApoc]] — main OpenApoc page&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Improvements_(OpenApoc)&amp;diff=126341</id>
		<title>Improvements (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Improvements_(OpenApoc)&amp;diff=126341"/>
		<updated>2026-03-01T22:44:01Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Major rewrite: documented all 54+ More Options menu settings with descriptions and defaults&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;OpenApoc introduces dozens of optional gameplay improvements and enhancements beyond the original &#039;&#039;[[Apocalypse|X-COM: Apocalypse]]&#039;&#039;. All of these can be toggled on or off through the &#039;&#039;&#039;More Options&#039;&#039;&#039; menu accessible from the in-game options screen.&lt;br /&gt;
&lt;br /&gt;
For a complete list of differences from the original game (including technical improvements, controls, and bug fixes), see [[Differences to X-COM (OpenApoc)]].&lt;br /&gt;
&lt;br /&gt;
== Cityscape Improvements ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot;&lt;br /&gt;
! Option !! Description !! Default&lt;br /&gt;
|-&lt;br /&gt;
| Improved city control scheme || Completely new control scheme using modifier keys for direct orders, UFOpaedia lookups, and additive selection. See [[Controls (OpenApoc)]] for details. Can be disabled to restore vanilla controls. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Ferry checks relationship when buying || Transtellar checks its relationship with X-COM before providing transport services. In the original, transports were always available regardless of relationship. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Allow manual use of teleporters in city || Players can manually route vehicles through teleporter buildings for quick transport across the city. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Allow manual ferrying of cargo and non-combatants || Manual control over ferry transport of cargo and non-combat personnel. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Allow soldiers to call taxi || Soldiers can use taxis for transport. In the original, only civilians could use taxis. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Allow attacking owned vehicles || X-COM can attack its own vehicles. This was impossible in the original game. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Call existing transport || Reuses existing transport vehicles instead of spawning new ones each time. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Recover dropped equipment || Equipment dropped by agents in the city is automatically recovered and returned to base stores. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Enforce vehicle cargo limits || Strict enforcement of vehicle cargo capacity. When disabled, vehicles can carry unlimited cargo (original behavior was inconsistent). || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Nearby vehicle loot pickup || Nearby X-COM vehicles can collect loot from crash sites and battles, not just the vehicle that initiated the mission. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Building loot deposit || Recovered loot can be deposited inside buildings for later collection. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Armored roads || Roads have damage reduction, making them harder to destroy during city combat. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Ground vehicles crash on lost support || Ground vehicles without road support crash. Weapons and modules may be lost in the crash. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Dimension gate crash || Vehicles incapable of dimensional travel crash when entering dimension gates. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Out of fuel crash || Vehicles crash when their fuel runs out completely. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Collapse raided building || Buildings collapse after a successful raid operation. || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Retaliation on unintentional hit || Any stray shot hitting a hostile building provokes immediate retaliation. || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Market on right || Market stock displayed on the right side of the transaction screen (swap from default left). || ON&lt;br /&gt;
|-&lt;br /&gt;
| Left click icon for equip || Left-clicking a unit&#039;s icon opens the equipment screen directly. || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Skip turbo movement || Performance optimization that skips turbo movement calculations. || OFF&lt;br /&gt;
|-&lt;br /&gt;
| ATV UFO missions || All Terrain Vehicles (Griffon, Wolfhound APC) can initiate UFO recovery missions. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Show current dimension vehicles || Vehicle list filters to show only vehicles in the current dimension (or entering/leaving). || ON&lt;br /&gt;
|-&lt;br /&gt;
| Non-X-COM vehicle prefix || Non-X-COM vehicles are prefixed with * in vehicle lists for easy identification. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Iso-only follow || Disables automatic camera following in strategy (isometric) view. || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Currency formatting || Monetary values displayed with locale-appropriate currency formatting (e.g., $1,234,567). || ON&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Battlescape Improvements ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot;&lt;br /&gt;
! Option !! Description !! Default&lt;br /&gt;
|-&lt;br /&gt;
| Instant explosion damage || Explosions cause damage immediately rather than with a visual delay. || ON&lt;br /&gt;
|-&lt;br /&gt;
| UFO damage model || Uses the &#039;&#039;[[X-COM|UFO: Enemy Unknown]]&#039;&#039; damage randomization model (0-200% of base damage) instead of Apocalypse&#039;s narrower damage range. || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Gravlift sounds || Sound effects play when units enter or exit gravlifts. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Realistic throwing || Units must face the target and be in the correct stance before throwing items. When disabled, throws are instant regardless of facing. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Payload explosion || Carried ammunition detonates when a unit or vehicle is destroyed, causing additional explosions. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Display unit paths || Movement paths are visually displayed during tactical combat, showing where units will move. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Additional unit icons || Extra status icons shown on the unit panel for fatal wounds and psionic effects. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Force-firing parallel || Force-fire mode allows shots aimed parallel to the ground plane (useful for suppression). || ON&lt;br /&gt;
|-&lt;br /&gt;
| LOS for psi maintenance || Psionic attacks require maintained line of sight to the target. When disabled, psi effects persist without LOS. || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Vehicle shield sound || Different sound effect when vehicle shields absorb damage, providing audio feedback. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Run and kneel || Units default to running movement and kneeling stance. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Auto-reload || Weapons automatically reload from carried ammunition when a clip is expended. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Same ammo type reload || Auto-reload only uses the same ammunition type that was previously loaded (won&#039;t switch ammo types). || ON&lt;br /&gt;
|-&lt;br /&gt;
| Mousewheel vertical scroll || Mouse scroll wheel changes the displayed map level in battlescape. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Single squad select || Single-click on squad number buttons selects the entire squad (instead of requiring double-click). || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Disable scroll sounds || Turns off the scrolling sound effect when moving the map. || OFF&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== General Improvements ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot;&lt;br /&gt;
! Option !! Description !! Default&lt;br /&gt;
|-&lt;br /&gt;
| Debug commands visible || Displays debug/cheat command buttons in the interface. See [[Hidden Features (OpenApoc)]] for details. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Advanced inventory controls || Shift+click for auto-equip/remove, Ctrl+click to remove clips from weapons. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Agent equipment templates || Save and load agent equipment loadouts with number keys (Ctrl+1-0 to save, 1-0 to apply to all selected agents). || ON&lt;br /&gt;
|-&lt;br /&gt;
| Seed RNG || Seeds the random number generator at game start for varied gameplay each time. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Mouse capture || Captures the mouse cursor within the game window, preventing it from leaving the window boundary. || OFF&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Mod Options ==&lt;br /&gt;
&lt;br /&gt;
These options modify game balance or add non-standard features:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot;&lt;br /&gt;
! Option !! Description !! Default&lt;br /&gt;
|-&lt;br /&gt;
| Max tile repair per night || Maximum number of scenery tiles construction vehicles repair each night (configurable 0-100). || 5&lt;br /&gt;
|-&lt;br /&gt;
| Scenery repair cost factor || Percentage of original price organizations pay for scenery tile repair (configurable 0-100%). || 10%&lt;br /&gt;
|-&lt;br /&gt;
| Stunning hurts relationships || Stunning units belonging to an organization damages X-COM&#039;s relationship with that organization. || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Raid hurts relationships || Initiating a raid on a building damages the relationship with its owner organization. || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Original BSK Launcher sound || Uses the original game&#039;s Brainsucker Launcher sound effect. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Invulnerable roads || Roads cannot be damaged or destroyed by any weapons. || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Griffon ATV || The Griffon AFV becomes an all-terrain vehicle capable of off-road movement. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Wolfhound ATV || The Wolfhound APC becomes an all-terrain vehicle capable of off-road movement. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Low HP vehicle crash || Vehicles crash when their health drops critically low. Weapons and modules may be lost. || OFF&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Pause Notifications ==&lt;br /&gt;
&lt;br /&gt;
OpenApoc adds a comprehensive &#039;&#039;&#039;configurable notification system&#039;&#039;&#039; that pauses the game when specific events occur. Each notification can be individually toggled in the options. These are not present in the original game.&lt;br /&gt;
&lt;br /&gt;
=== City Notifications ===&lt;br /&gt;
* UFO spotted&lt;br /&gt;
* Vehicle damage (light / moderate / heavy / destroyed)&lt;br /&gt;
* Vehicle escaping (damaged and returning to base)&lt;br /&gt;
* Vehicle out of ammo / low fuel&lt;br /&gt;
* Agent died / arrived at base&lt;br /&gt;
* Cargo / transfer / recovery arrived at base&lt;br /&gt;
* Vehicle repaired / rearmed / refuelled&lt;br /&gt;
* Not enough ammo / fuel&lt;br /&gt;
* Unauthorized vehicle detected&lt;br /&gt;
* X-COM base destroyed&lt;br /&gt;
&lt;br /&gt;
=== Battle Notifications ===&lt;br /&gt;
* Hostile spotted / died&lt;br /&gt;
* Unknown unit died&lt;br /&gt;
* Agent died / brainsucked&lt;br /&gt;
* Agent critically wounded / badly injured / injured&lt;br /&gt;
* Agent under fire / unconscious / left combat zone&lt;br /&gt;
* Agent frozen / berserk / panicked / panic over&lt;br /&gt;
* Psionic attack on unit / unit under psionic control / freed from control&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[Differences to X-COM (OpenApoc)]] — comprehensive differences from the original game&lt;br /&gt;
* [[Controls (OpenApoc)]] — full control scheme reference&lt;br /&gt;
* [[Hidden Features (OpenApoc)]] — debug hotkeys and cheat system&lt;br /&gt;
* [[Modding (OpenApoc)]] — modding documentation&lt;br /&gt;
* [https://github.com/ayrtondenner/OpenApoc-wiki/blob/master/openapoc/new-features.md OpenApoc Wiki: New Features] &amp;amp;mdash; Extended improvements documentation&lt;br /&gt;
* [[OpenApoc]] — main OpenApoc page&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Credits_(OpenApoc)&amp;diff=126340</id>
		<title>Credits (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Credits_(OpenApoc)&amp;diff=126340"/>
		<updated>2026-03-01T22:28:22Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Fix RedRobin84 name: replace HTML entity with UTF-8 character Č&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{DISPLAYTITLE:Credits (OpenApoc)}}&lt;br /&gt;
&#039;&#039;&#039;[[OpenApoc]]&#039;&#039;&#039; is a community-driven open-source project. It is near impossible to adequately credit everyone involved &amp;amp;mdash; this page attempts to recognise the key contributors whose work has shaped the project.&lt;br /&gt;
&lt;br /&gt;
== Project Founder ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:PmProg|PmProg]] - Marq Watkin&#039;&#039;&#039; &amp;amp;mdash; Founded the OpenApoc project in July 2014&lt;br /&gt;
&lt;br /&gt;
== Lead Developer ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:JonnyH|JonnyH]] - Jonathan Hamilton&#039;&#039;&#039; &amp;amp;mdash; Game UI, AI, Cityscape, Battlescape, Framework, rendering engine, serialisation, and overall architecture. By far the largest contributor to the codebase.&lt;br /&gt;
&lt;br /&gt;
== Core Contributors ==&lt;br /&gt;
&lt;br /&gt;
Listed alphabetically. Contributions span code, testing, translation, reverse-engineering, modding, and community management.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Contributor !! Primary Contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Atrosha|Atrosha]] - Panasenko Vasiliy Sergeevich&#039;&#039;&#039; || Many fixes, UI of agent characteristics (Rest In Peace; 1980&amp;amp;ndash;2021)&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Deldonut1|deldonut1]]&#039;&#039;&#039; (Ayrton Denner) || Gameplay improvements, bug fixes, documentation, wiki&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Empty`void|emptyVoid]]&#039;&#039;&#039; || Code contributions, bug fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:FilmBoy84|FilmBoy84]] - Jacob Deuchar&#039;&#039;&#039; || Game archivist, testing, modding (Extended Weapons Mod), original game historian&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:FranciscoDA|FranciscoDA / Flacko]]&#039;&#039;&#039; || UI improvements (hover screens), Win installer, code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Ivan_Shibanov|Shellstorm - Ivan Shibanov]]&#039;&#039;&#039; || Fixes, AI, Economics, Diplomatic Rift&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Istrebitel|Istrebitel]]&#039;&#039;&#039; || Game UI, AI, Battlescape, data extraction, Skirmish Mode, debug system, hotkey set, 40+ improvements and options interface, video making&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Jarskih|Jarskih]] - Jari Hanski&#039;&#039;&#039; || Many fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Kgd192&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Kurtsley&#039;&#039;&#039; || Gameplay bug fixes, code improvements (2024&amp;amp;ndash;2025)&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Luis Camara&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Makus|Makus]]&#039;&#039;&#039; || Community &amp;amp;amp; PR, website hosting, designer, Russian translation, VK group founder, FB page editor, YouTube channel editor&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:PmProg|PmProg]] - Marq Watkin&#039;&#039;&#039; || Framework core, UI framework core, Game UI, FB poster, YouTube channel admin&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Redv|redv]]&#039;&#039;&#039; || Vehicle location screen, drag-and-drop mechanics, many fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Roger|Roger]]&#039;&#039;&#039; || Documentation fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Sfalexrog|sfalexrog]] - Alexey Rogachevskiy&#039;&#039;&#039; || Android core, .cue image loader, audio backend core, fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Skin36|Skin36]]&#039;&#039;&#039; || Reverse engineering (OG disassembly), Russian translation, fire rate and accuracy formula documentation&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:SupSuper|SupSuper]] - Daniel Albano&#039;&#039;&#039; || Base management, tooltips, fixes, Game UI, founder of OpenXcom, Community &amp;amp;amp; PR&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Additional Contributors ==&lt;br /&gt;
&lt;br /&gt;
The following people have also contributed code, translations, bug reports, or other valuable work:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Contributor !! Contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:5thAvenue|5thAvenue]]&#039;&#039;&#039; || Initial French translation&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Andy51&#039;&#039;&#039; (Andrey Isakov) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Anders Sandberg Nordb&amp;amp;oslash;&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Andre Haberle&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;AndreyCreator&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Ashenomo&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Blackwolf-Kuzoku|Blackwolf-Kuzoku]]&#039;&#039;&#039; || Initial German translation&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Dan Church&#039;&#039;&#039; (h3xx) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Dl471&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Dmitry Marakasov&#039;&#039;&#039; (AMDmi3) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Jay_Atkinson|DoxaLogosGit - Jay Atkinson]]&#039;&#039;&#039; || Build instructions fix&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Gnegno84&#039;&#039;&#039; (Marcello Santambrogio) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Johnny Solbu&#039;&#039;&#039; (solbu) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Gsw88&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Hambones82&#039;&#039;&#039; (Josh Hamberger) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Kaja47&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Kammerer|Kammerer]]&#039;&#039;&#039; || Russian translation, fonts, researcher&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Killermosi&#039;&#039;&#039; (Silviu Ghita) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Kirill Mishustin&#039;&#039;&#039; (TreacherousOne) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Kkmic|kkmic]]&#039;&#039;&#039; || Build fixes, readme fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Kovarny&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;NagyAlex96&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Pkubaj&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Przemyslaw_Onak|Przemyslaw Onak]]&#039;&#039;&#039; || Saved game &amp;amp;amp; serialization fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;RedRobin84&#039;&#039;&#039; (Martin Červenka) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;ShadowDancer&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;SiemensSchuckert&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:SolariusScorch|SolariusScorch]]&#039;&#039;&#039; || Small language fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Sonicelo|Sonicelo]] - Gregor Su&amp;amp;scaron;anj&#039;&#039;&#039; || Windows build fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Sparkstar|sparkstar]]&#039;&#039;&#039; || GameUI fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Steve_Schnepp|steveschnepp - Steve Schnepp]]&#039;&#039;&#039; || Vagrant build&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;StewartM&#039;&#039;&#039; (Stewart Matheson) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;SuperUserCode&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Volkov &amp;quot;BabyWolf&amp;quot; Semjon&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Xracer|Xracer]]&#039;&#039;&#039; || Initial Spanish translation&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Zigmar|zigmar / zigmar-ems]] - Pavel Antokolsky&#039;&#039;&#039; || UI Scaling&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Testing ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:FilmBoy84|FilmBoy84]] - Jacob Deuchar&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;Quickmind / Quickmind01&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;Yataka Shimaoka&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[EmperorLol|EmperorLol - Laurie Blake]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;Jigoku-Panzer - Dean Martin&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Modding Structure and Testing ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:JonnyH|JonnyH]] - Jonathan Hamilton&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:FilmBoy84|FilmBoy84]] - Jacob Deuchar&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:Istrebitel|Istrebitel]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;Voiddweller&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:Skin36|Skin36]]&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Reversing and Research ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:Skin36|Skin36]]&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Translation ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:5thAvenue|5thAvenue]]&#039;&#039;&#039; &amp;amp;mdash; Initial French translation&lt;br /&gt;
* &#039;&#039;&#039;[[User:Blackwolf-Kuzoku|Blackwolf-Kuzoku]]&#039;&#039;&#039; &amp;amp;mdash; Initial German translation&lt;br /&gt;
* &#039;&#039;&#039;[[User:Kammerer|Kammerer]]&#039;&#039;&#039; &amp;amp;mdash; Russian translation, Fonts, Researcher&lt;br /&gt;
* &#039;&#039;&#039;[[User:Skin36|Skin36]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:SolariusScorch|SolariusScorch]]&#039;&#039;&#039; &amp;amp;mdash; Small language fixes&lt;br /&gt;
* &#039;&#039;&#039;[[User:Xracer|Xracer]]&#039;&#039;&#039; &amp;amp;mdash; Initial Spanish translation&lt;br /&gt;
&lt;br /&gt;
== Project Coordination, Writing, Video Making and Social Media ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:Istrebitel|Istrebitel]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:Makus|Makus]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:FilmBoy84|FilmBoy84]] - Jacob Deuchar&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Community Administration and Moderation ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:PmProg|PmProg]] - Marq Watkin&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:Makus|Makus]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:SolariusScorch|SolariusScorch]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:FilmBoy84|FilmBoy84]] - Jacob Deuchar&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Art and Design ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:Makus|Makus]]&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Resources and Management ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;GitHub:&#039;&#039;&#039; [[User:JonnyH|JonnyH]], [[User:Istrebitel|Istrebitel]], [[User:FilmBoy84|FilmBoy84]], Quickmind&lt;br /&gt;
* &#039;&#039;&#039;Forum:&#039;&#039;&#039; [[User:JonnyH|JonnyH]] (domain), [[User:Makus|Makus]] (hosting and scripts)&lt;br /&gt;
* &#039;&#039;&#039;Facebook:&#039;&#039;&#039; [[User:JonnyH|JonnyH]] (admin), [[User:FilmBoy84|FilmBoy84]] (editor), [[User:Makus|Makus]] (editor)&lt;br /&gt;
* &#039;&#039;&#039;YouTube:&#039;&#039;&#039; [[User:JonnyH|JonnyH]] (admin), [[User:FilmBoy84|FilmBoy84]] (editor), [[User:Makus|Makus]] (editor)&lt;br /&gt;
* &#039;&#039;&#039;Reddit:&#039;&#039;&#039; [[User:Istrebitel|Istrebitel]] (starter), [[User:Makus|Makus]] (editor), [[User:FilmBoy84|FilmBoy84]] (editor)&lt;br /&gt;
* &#039;&#039;&#039;Vkontakte:&#039;&#039;&#039; [[User:Makus|Makus]] (starter, editor), [[User:Skin36|Skin36]], [[User:Istrebitel|Istrebitel]]&lt;br /&gt;
* &#039;&#039;&#039;Twitter:&#039;&#039;&#039; [[User:Makus|Makus]]&lt;br /&gt;
&lt;br /&gt;
== Additional Community Members ==&lt;br /&gt;
&lt;br /&gt;
It&#039;s near impossible to adequately credit everyone that has laid a hand on an open-source project, so here are the main sources. Rest assured if you helped us, we are thankful for it.&lt;br /&gt;
&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc/graphs/contributors All contributors on GitHub]&lt;br /&gt;
* [https://www.transifex.com/x-com-apocalypse/teams/ All translators on Transifex]&lt;br /&gt;
* [http://openapoc.org/widget-pages/team/ All testers]&lt;br /&gt;
* [http://openapoc.org/ All forum members]&lt;br /&gt;
* All platform porters&lt;br /&gt;
* And the rest of the community at large: Players, fans, press members, let&#039;s players, etc. You know who you are.&lt;br /&gt;
&lt;br /&gt;
== Third-Party Code ==&lt;br /&gt;
&lt;br /&gt;
=== External Dependencies ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Library !! Purpose&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://www.libsdl.org SDL2]&#039;&#039;&#039; || Windowing, input, audio&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://boost.org Boost]&#039;&#039;&#039; (locale, program-options, uuid, crc) || Localisation, settings management, hash functions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://xiph.org/vorbis/ LibVorbis]&#039;&#039;&#039; || Ogg Vorbis music decoding&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://www.qt.io/ Qt]&#039;&#039;&#039; (Qt5 or Qt6 base) || Launcher GUI (optional)&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://nongnu.org/libunwind/download.html libunwind]&#039;&#039;&#039; || Debug backtracing (Linux only)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Bundled Dependencies (Submodules) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Library !! Purpose&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/fmtlib/fmt fmtlib (fmt)]&#039;&#039;&#039; || C++ string formatting library&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://glm.g-truc.net GLM]&#039;&#039;&#039; || Math library (vectors, matrices, etc.)&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://sourceforge.net/projects/libsmacker/ libsmacker]&#039;&#039;&#039; || Decoder for &amp;lt;code&amp;gt;.smk&amp;lt;/code&amp;gt; video files&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/lvandeve/lodepng lodepng]&#039;&#039;&#039; || Reading/writing PNG image files&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://www.lua.org/ Lua]&#039;&#039;&#039; || Scripting language&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/Neargye/magic_enum magic_enum]&#039;&#039;&#039; || Header-only C++17 static reflection for enums&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/richgel999/miniz miniz]&#039;&#039;&#039; || Zlib-compatible compression library&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://icculus.org/physfs/ PhysFS]&#039;&#039;&#039; (patched) || Reading data from &amp;lt;code&amp;gt;.iso&amp;lt;/code&amp;gt; files and directory trees&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://pugixml.org pugixml]&#039;&#039;&#039; || XML library for game data files&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Acknowledgements ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Julian Gollop&#039;&#039;&#039; &amp;amp;mdash; Original designer of X-COM: Apocalypse. Has publicly endorsed the OpenApoc project.&lt;br /&gt;
* &#039;&#039;&#039;MicroProse / Mythos Games&#039;&#039;&#039; &amp;amp;mdash; Original developers of X-COM: Apocalypse (1997)&lt;br /&gt;
* The [https://www.ufopaedia.org/index.php UFOpaedia] community for maintaining comprehensive X-COM documentation&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[OpenApoc]] &amp;amp;mdash; Main OpenApoc page&lt;br /&gt;
* [[Compiling (OpenApoc)]] &amp;amp;mdash; Building from source (for potential contributors)&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc OpenApoc on GitHub] &amp;amp;mdash; Source code and issue tracker&lt;br /&gt;
* [https://github.com/ayrtondenner/OpenApoc-wiki OpenApoc Wiki] &amp;amp;mdash; Extended developer and game mechanics documentation&lt;br /&gt;
* [https://discord.gg/f8Rayre OpenApoc Discord] &amp;amp;mdash; Community discussion&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Differences_to_X-COM_(OpenApoc)&amp;diff=126339</id>
		<title>Differences to X-COM (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Differences_to_X-COM_(OpenApoc)&amp;diff=126339"/>
		<updated>2026-03-01T21:59:45Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Major rewrite: comprehensive comparison between OpenApoc and original game across all systems&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&#039;&#039;&#039;OpenApoc&#039;&#039;&#039; is an open-source C++17 reimplementation of &#039;&#039;[[Apocalypse|X-COM: Apocalypse]]&#039;&#039; (1997). While aiming to faithfully recreate the original game, OpenApoc introduces many improvements, bug fixes, and new features. All new gameplay features are &#039;&#039;&#039;optional&#039;&#039;&#039; and can be toggled through the &#039;&#039;&#039;More Options&#039;&#039;&#039; menu.&lt;br /&gt;
&lt;br /&gt;
This page documents the known differences between OpenApoc and the original game. For general OpenApoc information, see the [[OpenApoc]] main page.&lt;br /&gt;
&lt;br /&gt;
== Technical Improvements ==&lt;br /&gt;
&lt;br /&gt;
OpenApoc runs natively on modern hardware and operating systems, removing the need for DOS emulation:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Platform support&#039;&#039;&#039;: Windows (MSVC 2019+), Linux (GCC 8+/Clang 7+), and macOS (including Apple Silicon)&lt;br /&gt;
* &#039;&#039;&#039;Modern resolutions&#039;&#039;&#039;: Supports any screen resolution and display scaling, with windowed, fullscreen, and borderless modes&lt;br /&gt;
* &#039;&#039;&#039;Performance&#039;&#039;&#039;: Runs at 60 FPS with OpenGL 2.0+ / GLES 3.0 rendering&lt;br /&gt;
* &#039;&#039;&#039;Human-readable save games&#039;&#039;&#039;: Game state is stored as XML in ZIP archives, editable with any text editor&lt;br /&gt;
* &#039;&#039;&#039;Mod support&#039;&#039;&#039;: Full modding via XML data files, Lua scripting, and a configurable mod loading system&lt;br /&gt;
* &#039;&#039;&#039;Multi-monitor support&#039;&#039;&#039;: Can be placed on any display in multi-monitor setups&lt;br /&gt;
* &#039;&#039;&#039;Configurable audio&#039;&#039;&#039;: Separate volume controls for music and sound effects&lt;br /&gt;
&lt;br /&gt;
== New Gameplay Options ==&lt;br /&gt;
&lt;br /&gt;
All new gameplay features are accessible through the &#039;&#039;&#039;More Options&#039;&#039;&#039; menu and can be individually enabled or disabled. Default values are listed — &#039;&#039;&#039;ON&#039;&#039;&#039; means the feature is enabled by default in OpenApoc.&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Options ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot;&lt;br /&gt;
! Option !! Description !! Default&lt;br /&gt;
|-&lt;br /&gt;
| Improved city control scheme || Completely new control scheme with modifier keys (see [[#Improved Controls|Improved Controls]] section). Can be disabled to restore vanilla controls. || ON&lt;br /&gt;
|-&lt;br /&gt;
| Ferry checks relationship when buying || Transtellar checks its relationship with X-COM before providing transport services || ON&lt;br /&gt;
|-&lt;br /&gt;
| Allow manual use of teleporters in city || Players can manually route vehicles through teleporter buildings for quick transport || ON&lt;br /&gt;
|-&lt;br /&gt;
| Allow manual ferrying of cargo and non-combatants || Manual control over ferry transport of cargo and non-combat personnel || ON&lt;br /&gt;
|-&lt;br /&gt;
| Allow soldiers to call taxi || Soldiers can use taxis for transport (restricted to civilians in the original) || ON&lt;br /&gt;
|-&lt;br /&gt;
| Allow attacking owned vehicles || Allows X-COM to attack its own vehicles (impossible in the original game) || ON&lt;br /&gt;
|-&lt;br /&gt;
| Call existing transport instead of spawning them || Reuses existing transport vehicles instead of spawning new ones || ON&lt;br /&gt;
|-&lt;br /&gt;
| Attempt to recover agent equipment dropped in city || Equipment dropped by agents in the city is automatically recovered || ON&lt;br /&gt;
|-&lt;br /&gt;
| Enforce vehicle cargo limits || Strict enforcement of vehicle cargo capacity || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Allow nearby vehicles to pick up loot || Nearby X-COM vehicles can collect loot from crash sites || ON&lt;br /&gt;
|-&lt;br /&gt;
| Allow loot to be stashed in the building || Recovered loot can be deposited in buildings || ON&lt;br /&gt;
|-&lt;br /&gt;
| Armored roads || Roads have damage reduction, making them harder to destroy || ON&lt;br /&gt;
|-&lt;br /&gt;
| Unsupported ground vehicles crash || Ground vehicles without road support will crash (weapons and modules may be lost) || ON&lt;br /&gt;
|-&lt;br /&gt;
| Vehicles crash when entering dimension gates || Vehicles incapable of dimensional travel crash when entering gates || ON&lt;br /&gt;
|-&lt;br /&gt;
| Vehicles crash when out of fuel || Vehicles crash when their fuel runs out || ON&lt;br /&gt;
|-&lt;br /&gt;
| Successful raid collapses building || Buildings collapse after a successful raid || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Any hit on hostile building provokes retaliation || Stray shots hitting hostile buildings trigger retaliation || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Put market stock on the right side || Market stock displayed on the right side of the transaction screen || ON&lt;br /&gt;
|-&lt;br /&gt;
| Left clicking icon opens equip menu || Left-clicking a unit&#039;s icon opens the equipment screen || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Skip turbo movement calculations || Performance optimization that skips turbo movement math || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Allow ATVs to initiate UFO recovery missions || All Terrain Vehicles can start UFO recovery missions || ON&lt;br /&gt;
|-&lt;br /&gt;
| Show vehicles in current dimension only || Vehicle list filters to show only the current dimension || ON&lt;br /&gt;
|-&lt;br /&gt;
| Add prefix to non-X-COM vehicles || Non-X-COM vehicles are prefixed with * in vehicle lists for easy identification || ON&lt;br /&gt;
|-&lt;br /&gt;
| Don&#039;t follow vehicles in strategy view || Disables automatic camera following in strategy (isometric) view || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Use currency formatting || Monetary values displayed with currency formatting (e.g., $1,234,567) || ON&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Other Cityscape differences:&#039;&#039;&#039;&lt;br /&gt;
* Aircraft weapons may be unequipped (not possible in the original game)&lt;br /&gt;
&lt;br /&gt;
=== Battlescape Options ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot;&lt;br /&gt;
! Option !! Description !! Default&lt;br /&gt;
|-&lt;br /&gt;
| Explosions damage instantly || Explosions cause damage immediately rather than with a delay || ON&lt;br /&gt;
|-&lt;br /&gt;
| X-Com 1 (UFO) Damage model (0-200%) || Uses the &#039;&#039;[[X-COM|UFO: Enemy Unknown]]&#039;&#039; damage randomization model (0-200% of base damage) instead of Apocalypse&#039;s model || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Gravlift sounds || Sound effects play when units enter or exit gravlifts || ON&lt;br /&gt;
|-&lt;br /&gt;
| Throwing requires proper facing and pose || Units must face the target and be in the correct stance before throwing || ON&lt;br /&gt;
|-&lt;br /&gt;
| Ammunition explodes when blown up || Carried ammunition detonates when a unit or vehicle is destroyed || ON&lt;br /&gt;
|-&lt;br /&gt;
| Display unit paths in battle || Movement paths are visually displayed during tactical combat || ON&lt;br /&gt;
|-&lt;br /&gt;
| Display additional unit icons (fatal, psi) || Extra status icons shown for fatal wounds and psionic effects || ON&lt;br /&gt;
|-&lt;br /&gt;
| Allow force-firing parallel to the ground || Force-fire mode allows shots aimed parallel to the ground plane || ON&lt;br /&gt;
|-&lt;br /&gt;
| Require LOS to maintain psi attack || Psionic attacks require maintained line of sight to the target || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Hitting vehicle shield produces alternate sound || Different sound effect when vehicle shields absorb damage || ON&lt;br /&gt;
|-&lt;br /&gt;
| All units run and kneel by default || Units default to running movement and kneeling stance || ON&lt;br /&gt;
|-&lt;br /&gt;
| Automatically reload weapons when empty || Weapons auto-reload from carried ammunition when a clip is expended || ON&lt;br /&gt;
|-&lt;br /&gt;
| Weapons autoreload only same ammo type || Auto-reload only uses the same ammunition type that was previously loaded || ON&lt;br /&gt;
|-&lt;br /&gt;
| Mousewheel changes vertical level in battlescape || Mouse scroll wheel changes the displayed map level || ON&lt;br /&gt;
|-&lt;br /&gt;
| Select squad with single click || Single-click squad number buttons to select the entire squad || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Disable scrolling sounds || Turns off the sound effect when scrolling the map || OFF&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== General Options ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot;&lt;br /&gt;
! Option !! Description !! Default&lt;br /&gt;
|-&lt;br /&gt;
| Show debug commands on screen || Displays debug/cheat command buttons in the interface || ON&lt;br /&gt;
|-&lt;br /&gt;
| Allow unloading clips and quick equip || Advanced inventory controls: Shift+click for auto-equip, Ctrl+click to remove clips || ON&lt;br /&gt;
|-&lt;br /&gt;
| Enable agent equipment templates || Save and load agent equipment loadouts with number keys (Ctrl+1-0 to save, 1-0 to apply) || ON&lt;br /&gt;
|-&lt;br /&gt;
| Seed RNG on game start || Seeds the random number generator at game start for varied gameplay || ON&lt;br /&gt;
|-&lt;br /&gt;
| Enable mouse capture for the window || Captures the mouse cursor within the game window || OFF&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Mod Options ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot;&lt;br /&gt;
! Option !! Description !! Default&lt;br /&gt;
|-&lt;br /&gt;
| Max tile repair per night || Maximum number of scenery tiles construction vehicles repair each night (0-100) || 5&lt;br /&gt;
|-&lt;br /&gt;
| Scenery repair cost factor || Percentage of original price organizations pay for scenery repair (0-100%) || 10%&lt;br /&gt;
|-&lt;br /&gt;
| Stunning hurts relationships || Stunning units belonging to an organization damages X-COM&#039;s relationship with them || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Initiating raid hurts relationships || Starting a raid on a building damages the relationship with its owner || OFF&lt;br /&gt;
|-&lt;br /&gt;
| (MOD) Original Brainsucker Launcher SFX || Uses the original game&#039;s Brainsucker Launcher sound effect || ON&lt;br /&gt;
|-&lt;br /&gt;
| (MOD) Invulnerable roads || Roads cannot be damaged or destroyed || OFF&lt;br /&gt;
|-&lt;br /&gt;
| (MOD) Griffon becomes All-Terrain || The Griffon AFV becomes an all-terrain vehicle capable of off-road movement || ON&lt;br /&gt;
|-&lt;br /&gt;
| (MOD) Wolfhound APC becomes All-Terrain || The Wolfhound APC becomes an all-terrain vehicle || ON&lt;br /&gt;
|-&lt;br /&gt;
| Vehicles crash on low HP || Vehicles crash when their health drops critically low (weapons and modules may be lost) || OFF&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cheat Options ===&lt;br /&gt;
&lt;br /&gt;
OpenApoc provides a dedicated cheat menu not present in the original game:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Option !! Description !! Default&lt;br /&gt;
|-&lt;br /&gt;
| Infinite ammo || Unlimited ammunition for all X-COM agents and vehicles || OFF&lt;br /&gt;
|-&lt;br /&gt;
| Damage inflicted multiplier || Multiplier for damage dealt by X-COM (0x - 5x) || 1.0x&lt;br /&gt;
|-&lt;br /&gt;
| Damage received multiplier || Multiplier for damage taken by X-COM (0x - 5x) || 1.0x&lt;br /&gt;
|-&lt;br /&gt;
| Hostiles multiplier || Multiplier for the number of hostile units spawned (0.5x - 3x) || 1.0x&lt;br /&gt;
|-&lt;br /&gt;
| Stat growth multiplier || Multiplier for agent stat growth rate (0x - 99.5x) || 1.0x&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
Additional cheat buttons: Give All Research, Make All Orgs Friendly/Hostile, Make All Orgs Utopia/Chaos, Modify Funds, Set Time Before Midnight, Fast Forward to End of Day/Week/Month.&lt;br /&gt;
&lt;br /&gt;
== Improved Controls ==&lt;br /&gt;
&lt;br /&gt;
The original game&#039;s city controls were inconsistent and limited. OpenApoc introduces a completely new control scheme using modifier keys. This can be disabled via the &amp;quot;Improved city control scheme&amp;quot; option to restore vanilla behavior.&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Mouse Controls ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Left Click on building || Open building screen (base screen if building contains a base)&lt;br /&gt;
|-&lt;br /&gt;
| Right Click on building || Open building screen&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Left Click || Order attack vehicle&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Right Click || Order follow vehicle / go to location&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Shift + Left Click || Order attack building&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Shift + Right Click || Order go to building&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Left Click || Open UFOpaedia for object (vehicle type, building function, projectile source)&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Right Click || Open UFOpaedia for object&#039;s owner&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + move order (agents) || Force agents to move on foot (never call taxi), allows personal teleporter use&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + move order (vehicles) || Allows manual use of city teleporters&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + attack order || Forces vehicles to attack target (instead of UFO recovery or escort)&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Left Click (selection) || Add unit/vehicle to selection (additive selection)&lt;br /&gt;
|-&lt;br /&gt;
| Right Click (selection) || Remove unit/vehicle from selection&lt;br /&gt;
|-&lt;br /&gt;
| Middle Click || Move camera to location&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Mouse on Vehicle/Agent Icons ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Right Click || Open location screen&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Shift + Right Click || Open equipment screen&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Shift + Right Click || Open equipment screen&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Agent Equipment Controls ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Click || Auto-equip item to first available slot, or auto-remove to stores/ground&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Click on weapon || Remove clip from weapon&lt;br /&gt;
|-&lt;br /&gt;
| 1-0 || Apply saved equipment template to all selected agents&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + 1-0 || Save current agent&#039;s equipment set as a template&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Battlescape Mouse Controls ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Left Click || Order unit to execute action (move/throw/psi/teleport), open probed unit screen, use item&lt;br /&gt;
|-&lt;br /&gt;
| Right Click || Turn towards cursor, focus enemy (real-time), use item auto-function (e.g., prime grenade for impact)&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Left Click || Force-fire at target tile, shot parallel to ground&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Alt + Left Click || Force-fire at target tile, shot aimed at tile&#039;s ground&lt;br /&gt;
|-&lt;br /&gt;
| Alt + move order || Unit keeps facing target while moving (strafe/backpedal)&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Left Click || Add unit to selection (additive)&lt;br /&gt;
|-&lt;br /&gt;
| Right Click || Remove unit from selection&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Battlescape Keyboard ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| PgUp / PgDown || Change map levels&lt;br /&gt;
|-&lt;br /&gt;
| V || Toggle layering&lt;br /&gt;
|-&lt;br /&gt;
| F2-F4 || Movement modes: Prone / Walk / Run&lt;br /&gt;
|-&lt;br /&gt;
| F5-F8 || Fire modes: Cease / Aimed / Snap / Auto&lt;br /&gt;
|-&lt;br /&gt;
| F9-F11 || Behavior: Evasive / Normal / Aggressive&lt;br /&gt;
|-&lt;br /&gt;
| Backspace || Toggle kneel&lt;br /&gt;
|-&lt;br /&gt;
| 1-6 || Select squad&lt;br /&gt;
|-&lt;br /&gt;
| Shift + 1-6 || Select specific unit in current squad&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Ctrl + 1-6 || Add unit to selection&lt;br /&gt;
|-&lt;br /&gt;
| Alt + 1-6 || Cycle through spotted enemies of unit&lt;br /&gt;
|-&lt;br /&gt;
| Enter || Open inventory&lt;br /&gt;
|-&lt;br /&gt;
| [ / ] || Throw right / left hand item&lt;br /&gt;
|-&lt;br /&gt;
| &#039; / \ || Drop right / left hand item&lt;br /&gt;
|-&lt;br /&gt;
| E || End turn (turn-based mode)&lt;br /&gt;
|-&lt;br /&gt;
| J || Make unit jump (down from a cliff)&lt;br /&gt;
|-&lt;br /&gt;
| S / L || Open save / load menu&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== General Controls ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Mousewheel || Scroll lists&lt;br /&gt;
|-&lt;br /&gt;
| Esc || Go back, close form, cancel&lt;br /&gt;
|-&lt;br /&gt;
| Enter || Confirm, go forward&lt;br /&gt;
|-&lt;br /&gt;
| Space || Pause/Resume time&lt;br /&gt;
|-&lt;br /&gt;
| Tab || Toggle map&lt;br /&gt;
|-&lt;br /&gt;
| C || Toggle follow mode&lt;br /&gt;
|-&lt;br /&gt;
| M || Show message log&lt;br /&gt;
|-&lt;br /&gt;
| Home || Zoom to last event&lt;br /&gt;
|-&lt;br /&gt;
| Arrows || Move camera&lt;br /&gt;
|-&lt;br /&gt;
| 0-5 (Cityscape) || Control game speed&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Pause Notifications ==&lt;br /&gt;
&lt;br /&gt;
OpenApoc adds a comprehensive &#039;&#039;&#039;configurable notification system&#039;&#039;&#039; that can pause the game when specific events occur. Each notification can be individually toggled. These are not present in the original game.&lt;br /&gt;
&lt;br /&gt;
=== City Notifications ===&lt;br /&gt;
* UFO spotted&lt;br /&gt;
* Vehicle damage (light / moderate / heavy / destroyed)&lt;br /&gt;
* Vehicle escaping (damaged and returning to base)&lt;br /&gt;
* Vehicle out of ammo&lt;br /&gt;
* Vehicle low on fuel&lt;br /&gt;
* Agent died&lt;br /&gt;
* Agent arrived at base&lt;br /&gt;
* Cargo / Transfer / Recovery arrived at base&lt;br /&gt;
* Vehicle repaired / rearmed / refuelled&lt;br /&gt;
* Not enough ammo / fuel&lt;br /&gt;
* Unauthorized vehicle detected&lt;br /&gt;
* X-COM base destroyed&lt;br /&gt;
&lt;br /&gt;
=== Battle Notifications ===&lt;br /&gt;
* Hostile spotted / died&lt;br /&gt;
* Unknown unit died&lt;br /&gt;
* Agent died / brainsucked&lt;br /&gt;
* Agent critically wounded / badly injured / injured&lt;br /&gt;
* Agent under fire&lt;br /&gt;
* Agent unconscious / left combat zone&lt;br /&gt;
* Agent frozen / berserk / panicked / panic over&lt;br /&gt;
* Psionic attack on unit / unit under psionic control / freed from control&lt;br /&gt;
&lt;br /&gt;
== Original Game Bugs Fixed ==&lt;br /&gt;
&lt;br /&gt;
OpenApoc fixes or avoids several [[Known Bugs (Apocalypse)|known bugs]] from the original game:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;UFO speed bug&#039;&#039;&#039;: Fixed alien craft having 0 speed in certain conditions&lt;br /&gt;
* &#039;&#039;&#039;Infiltration screen overflow&#039;&#039;&#039;: Fixed infiltration screen going blank when exceeding 42 days&lt;br /&gt;
* &#039;&#039;&#039;Security Station turrets&#039;&#039;&#039; (partial): In the original turn-based mode, Security Station turrets did not have their TUs refreshed at the start of turns, rendering them mostly useless after the first shot&lt;br /&gt;
* &#039;&#039;&#039;Sound issues&#039;&#039;&#039;: Fixed OGG Vorbis music playback issues that could occur in the original&lt;br /&gt;
* &#039;&#039;&#039;Learning AI&#039;&#039;&#039;: The original game&#039;s advertised &amp;quot;learning AI&amp;quot; was effectively non-functional — it stopped working after saving the game and depended on specific CD-ROM file locations. OpenApoc does not attempt to replicate this broken feature&lt;br /&gt;
* &#039;&#039;&#039;Brainsucker Pod handling&#039;&#039;&#039;: Various fixes for Brainsucker Pod inventory issues, storage space, and alien containment display&lt;br /&gt;
&lt;br /&gt;
== Modding Support ==&lt;br /&gt;
&lt;br /&gt;
Unlike the original game, OpenApoc is designed with modding in mind:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;XML data files&#039;&#039;&#039;: Nearly all game data (units, weapons, vehicles, buildings, organizations) is defined in editable XML files&lt;br /&gt;
* &#039;&#039;&#039;Mod loading system&#039;&#039;&#039;: Mods are loaded from a configurable directory (default: &amp;lt;code&amp;gt;./data/mods&amp;lt;/code&amp;gt;), specified as a colon-separated list&lt;br /&gt;
* &#039;&#039;&#039;Lua scripting&#039;&#039;&#039;: A Lua scripting system allows custom AI and game logic modifications. Scripts are loaded via the &amp;lt;code&amp;gt;OpenApoc.Mod.ScriptsList&amp;lt;/code&amp;gt; configuration option&lt;br /&gt;
* &#039;&#039;&#039;Editable save games&#039;&#039;&#039;: Since saves are XML in ZIP archives, game state can be manually edited&lt;br /&gt;
&lt;br /&gt;
== Features Not Yet Implemented ==&lt;br /&gt;
&lt;br /&gt;
As of early 2026, OpenApoc is in &#039;&#039;&#039;alpha&#039;&#039;&#039; state. The following features from the original game are not yet fully implemented:&lt;br /&gt;
&lt;br /&gt;
=== Core Gameplay ===&lt;br /&gt;
* Victory and defeat screens&lt;br /&gt;
* Alien Takeover screen&lt;br /&gt;
* Full organization diplomacy with dual relationship values (the original tracked two separate relationship scores per organization)&lt;br /&gt;
* Overspawn mechanic&lt;br /&gt;
* Full dynamic action music structure&lt;br /&gt;
* Agent name generator&lt;br /&gt;
&lt;br /&gt;
=== AI and Movement ===&lt;br /&gt;
* Advanced battle AI: cover usage, flanking, grenade throwing, retreat and regrouping behaviors&lt;br /&gt;
* Intelligent alien movement patterns within the city&lt;br /&gt;
* True ground vehicle movement with lanes, highways, and overtaking behavior&lt;br /&gt;
* Evasive/Normal/Aggressive unit AI behavior modes (buttons exist but AI differentiation is incomplete)&lt;br /&gt;
&lt;br /&gt;
=== Other ===&lt;br /&gt;
* Proper portal locations in the Alien Dimension&lt;br /&gt;
* Full graphs and statistics feedback screens&lt;br /&gt;
* Organization vehicle AI (buying, selling, managing their own fleets)&lt;br /&gt;
* Coloured text support in some UI elements&lt;br /&gt;
&lt;br /&gt;
For the full development roadmap, see the [https://github.com/OpenApoc/OpenApoc/issues/263 Playable Alpha], [https://github.com/OpenApoc/OpenApoc/issues/264 Beta], and [https://github.com/OpenApoc/OpenApoc/issues/265 Release 1.0] milestone issues on GitHub.&lt;br /&gt;
&lt;br /&gt;
== Debug Mode ==&lt;br /&gt;
&lt;br /&gt;
OpenApoc includes an extensive debug system not present in the original game. Debug hotkeys are toggled with &#039;&#039;&#039;F1&#039;&#039;&#039; in both the cityscape and battlescape. When enabled, various diagnostic and cheat functions become available:&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Debug ===&lt;br /&gt;
* Ctrl+Alt+Shift+Click: Destroy scenery / collapse building&lt;br /&gt;
* Spawn UFOs, repair scenery, warp to alien dimension&lt;br /&gt;
* Display road pathfinding, walk modes, alien positions, vehicle paths&lt;br /&gt;
* Dump voxel maps for line of sight/fire analysis&lt;br /&gt;
* Highlight tubes, roads, and hills with directional filters&lt;br /&gt;
&lt;br /&gt;
=== Battlescape Debug ===&lt;br /&gt;
* Teleport units, stun/remove units, restore stats&lt;br /&gt;
* Reveal entire map with line-of-sight visualization&lt;br /&gt;
* Modify morale and psionic stats&lt;br /&gt;
* Spawn explosions and directional shots&lt;br /&gt;
* Re-link support lines for map parts&lt;br /&gt;
&lt;br /&gt;
=== Base Screen Debug ===&lt;br /&gt;
* Instantly finish all facility construction&lt;br /&gt;
* Near-instantly complete research projects&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[OpenApoc]] — main OpenApoc page&lt;br /&gt;
* [[Apocalypse]] — original X-COM: Apocalypse game page&lt;br /&gt;
* [[Known Bugs (Apocalypse)]] — bugs in the original game&lt;br /&gt;
* [https://github.com/ayrtondenner/OpenApoc-wiki/blob/master/comparison/differences.md OpenApoc Wiki: Differences] &amp;amp;mdash; Extended comparison documentation&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc OpenApoc on GitHub] — source code and issue tracker&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc/blob/master/README_HOTKEYS.txt README_HOTKEYS.txt] — complete hotkey reference&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Credits_(OpenApoc)&amp;diff=126338</id>
		<title>Credits (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Credits_(OpenApoc)&amp;diff=126338"/>
		<updated>2026-03-01T21:48:39Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Major rewrite: full contributor list from git history with roles; acknowledgements section&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{DISPLAYTITLE:Credits (OpenApoc)}}&lt;br /&gt;
&#039;&#039;&#039;[[OpenApoc]]&#039;&#039;&#039; is a community-driven open-source project. It is near impossible to adequately credit everyone involved &amp;amp;mdash; this page attempts to recognise the key contributors whose work has shaped the project.&lt;br /&gt;
&lt;br /&gt;
== Project Founder ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:PmProg|PmProg]] - Marq Watkin&#039;&#039;&#039; &amp;amp;mdash; Founded the OpenApoc project in July 2014&lt;br /&gt;
&lt;br /&gt;
== Lead Developer ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:JonnyH|JonnyH]] - Jonathan Hamilton&#039;&#039;&#039; &amp;amp;mdash; Game UI, AI, Cityscape, Battlescape, Framework, rendering engine, serialisation, and overall architecture. By far the largest contributor to the codebase.&lt;br /&gt;
&lt;br /&gt;
== Core Contributors ==&lt;br /&gt;
&lt;br /&gt;
Listed alphabetically. Contributions span code, testing, translation, reverse-engineering, modding, and community management.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Contributor !! Primary Contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Atrosha|Atrosha]] - Panasenko Vasiliy Sergeevich&#039;&#039;&#039; || Many fixes, UI of agent characteristics (Rest In Peace; 1980&amp;amp;ndash;2021)&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Deldonut1|deldonut1]]&#039;&#039;&#039; (Ayrton Denner) || Gameplay improvements, bug fixes, documentation, wiki&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Empty`void|emptyVoid]]&#039;&#039;&#039; || Code contributions, bug fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:FilmBoy84|FilmBoy84]] - Jacob Deuchar&#039;&#039;&#039; || Game archivist, testing, modding (Extended Weapons Mod), original game historian&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:FranciscoDA|FranciscoDA / Flacko]]&#039;&#039;&#039; || UI improvements (hover screens), Win installer, code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Ivan_Shibanov|Shellstorm - Ivan Shibanov]]&#039;&#039;&#039; || Fixes, AI, Economics, Diplomatic Rift&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Istrebitel|Istrebitel]]&#039;&#039;&#039; || Game UI, AI, Battlescape, data extraction, Skirmish Mode, debug system, hotkey set, 40+ improvements and options interface, video making&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Jarskih|Jarskih]] - Jari Hanski&#039;&#039;&#039; || Many fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Kgd192&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Kurtsley&#039;&#039;&#039; || Gameplay bug fixes, code improvements (2024&amp;amp;ndash;2025)&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Luis Camara&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Makus|Makus]]&#039;&#039;&#039; || Community &amp;amp;amp; PR, website hosting, designer, Russian translation, VK group founder, FB page editor, YouTube channel editor&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:PmProg|PmProg]] - Marq Watkin&#039;&#039;&#039; || Framework core, UI framework core, Game UI, FB poster, YouTube channel admin&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Redv|redv]]&#039;&#039;&#039; || Vehicle location screen, drag-and-drop mechanics, many fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Roger|Roger]]&#039;&#039;&#039; || Documentation fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Sfalexrog|sfalexrog]] - Alexey Rogachevskiy&#039;&#039;&#039; || Android core, .cue image loader, audio backend core, fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Skin36|Skin36]]&#039;&#039;&#039; || Reverse engineering (OG disassembly), Russian translation, fire rate and accuracy formula documentation&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:SupSuper|SupSuper]] - Daniel Albano&#039;&#039;&#039; || Base management, tooltips, fixes, Game UI, founder of OpenXcom, Community &amp;amp;amp; PR&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Additional Contributors ==&lt;br /&gt;
&lt;br /&gt;
The following people have also contributed code, translations, bug reports, or other valuable work:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable sortable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Contributor !! Contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:5thAvenue|5thAvenue]]&#039;&#039;&#039; || Initial French translation&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Andy51&#039;&#039;&#039; (Andrey Isakov) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Anders Sandberg Nordb&amp;amp;oslash;&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Andre Haberle&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;AndreyCreator&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Ashenomo&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Blackwolf-Kuzoku|Blackwolf-Kuzoku]]&#039;&#039;&#039; || Initial German translation&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Dan Church&#039;&#039;&#039; (h3xx) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Dl471&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Dmitry Marakasov&#039;&#039;&#039; (AMDmi3) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Jay_Atkinson|DoxaLogosGit - Jay Atkinson]]&#039;&#039;&#039; || Build instructions fix&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Gnegno84&#039;&#039;&#039; (Marcello Santambrogio) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Johnny Solbu&#039;&#039;&#039; (solbu) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Gsw88&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Hambones82&#039;&#039;&#039; (Josh Hamberger) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Kaja47&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Kammerer|Kammerer]]&#039;&#039;&#039; || Russian translation, fonts, researcher&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Killermosi&#039;&#039;&#039; (Silviu Ghita) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Kirill Mishustin&#039;&#039;&#039; (TreacherousOne) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Kkmic|kkmic]]&#039;&#039;&#039; || Build fixes, readme fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Kovarny&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;NagyAlex96&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Pkubaj&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Przemyslaw_Onak|Przemyslaw Onak]]&#039;&#039;&#039; || Saved game &amp;amp;amp; serialization fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;RedRobin84&#039;&#039;&#039; (Martin &amp;amp;Ccaron;ervenka) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;ShadowDancer&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;SiemensSchuckert&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:SolariusScorch|SolariusScorch]]&#039;&#039;&#039; || Small language fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Sonicelo|Sonicelo]] - Gregor Su&amp;amp;scaron;anj&#039;&#039;&#039; || Windows build fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Sparkstar|sparkstar]]&#039;&#039;&#039; || GameUI fixes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Steve_Schnepp|steveschnepp - Steve Schnepp]]&#039;&#039;&#039; || Vagrant build&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;StewartM&#039;&#039;&#039; (Stewart Matheson) || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;SuperUserCode&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Volkov &amp;quot;BabyWolf&amp;quot; Semjon&#039;&#039;&#039; || Code contributions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Xracer|Xracer]]&#039;&#039;&#039; || Initial Spanish translation&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[[User:Zigmar|zigmar / zigmar-ems]] - Pavel Antokolsky&#039;&#039;&#039; || UI Scaling&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Testing ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:FilmBoy84|FilmBoy84]] - Jacob Deuchar&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;Quickmind / Quickmind01&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;Yataka Shimaoka&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[EmperorLol|EmperorLol - Laurie Blake]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;Jigoku-Panzer - Dean Martin&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Modding Structure and Testing ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:JonnyH|JonnyH]] - Jonathan Hamilton&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:FilmBoy84|FilmBoy84]] - Jacob Deuchar&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:Istrebitel|Istrebitel]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;Voiddweller&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:Skin36|Skin36]]&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Reversing and Research ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:Skin36|Skin36]]&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Translation ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:5thAvenue|5thAvenue]]&#039;&#039;&#039; &amp;amp;mdash; Initial French translation&lt;br /&gt;
* &#039;&#039;&#039;[[User:Blackwolf-Kuzoku|Blackwolf-Kuzoku]]&#039;&#039;&#039; &amp;amp;mdash; Initial German translation&lt;br /&gt;
* &#039;&#039;&#039;[[User:Kammerer|Kammerer]]&#039;&#039;&#039; &amp;amp;mdash; Russian translation, Fonts, Researcher&lt;br /&gt;
* &#039;&#039;&#039;[[User:Skin36|Skin36]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:SolariusScorch|SolariusScorch]]&#039;&#039;&#039; &amp;amp;mdash; Small language fixes&lt;br /&gt;
* &#039;&#039;&#039;[[User:Xracer|Xracer]]&#039;&#039;&#039; &amp;amp;mdash; Initial Spanish translation&lt;br /&gt;
&lt;br /&gt;
== Project Coordination, Writing, Video Making and Social Media ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:Istrebitel|Istrebitel]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:Makus|Makus]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:FilmBoy84|FilmBoy84]] - Jacob Deuchar&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Community Administration and Moderation ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:PmProg|PmProg]] - Marq Watkin&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:Makus|Makus]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:SolariusScorch|SolariusScorch]]&#039;&#039;&#039;&lt;br /&gt;
* &#039;&#039;&#039;[[User:FilmBoy84|FilmBoy84]] - Jacob Deuchar&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Art and Design ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[[User:Makus|Makus]]&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
== Resources and Management ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;GitHub:&#039;&#039;&#039; [[User:JonnyH|JonnyH]], [[User:Istrebitel|Istrebitel]], [[User:FilmBoy84|FilmBoy84]], Quickmind&lt;br /&gt;
* &#039;&#039;&#039;Forum:&#039;&#039;&#039; [[User:JonnyH|JonnyH]] (domain), [[User:Makus|Makus]] (hosting and scripts)&lt;br /&gt;
* &#039;&#039;&#039;Facebook:&#039;&#039;&#039; [[User:JonnyH|JonnyH]] (admin), [[User:FilmBoy84|FilmBoy84]] (editor), [[User:Makus|Makus]] (editor)&lt;br /&gt;
* &#039;&#039;&#039;YouTube:&#039;&#039;&#039; [[User:JonnyH|JonnyH]] (admin), [[User:FilmBoy84|FilmBoy84]] (editor), [[User:Makus|Makus]] (editor)&lt;br /&gt;
* &#039;&#039;&#039;Reddit:&#039;&#039;&#039; [[User:Istrebitel|Istrebitel]] (starter), [[User:Makus|Makus]] (editor), [[User:FilmBoy84|FilmBoy84]] (editor)&lt;br /&gt;
* &#039;&#039;&#039;Vkontakte:&#039;&#039;&#039; [[User:Makus|Makus]] (starter, editor), [[User:Skin36|Skin36]], [[User:Istrebitel|Istrebitel]]&lt;br /&gt;
* &#039;&#039;&#039;Twitter:&#039;&#039;&#039; [[User:Makus|Makus]]&lt;br /&gt;
&lt;br /&gt;
== Additional Community Members ==&lt;br /&gt;
&lt;br /&gt;
It&#039;s near impossible to adequately credit everyone that has laid a hand on an open-source project, so here are the main sources. Rest assured if you helped us, we are thankful for it.&lt;br /&gt;
&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc/graphs/contributors All contributors on GitHub]&lt;br /&gt;
* [https://www.transifex.com/x-com-apocalypse/teams/ All translators on Transifex]&lt;br /&gt;
* [http://openapoc.org/widget-pages/team/ All testers]&lt;br /&gt;
* [http://openapoc.org/ All forum members]&lt;br /&gt;
* All platform porters&lt;br /&gt;
* And the rest of the community at large: Players, fans, press members, let&#039;s players, etc. You know who you are.&lt;br /&gt;
&lt;br /&gt;
== Third-Party Code ==&lt;br /&gt;
&lt;br /&gt;
=== External Dependencies ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Library !! Purpose&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://www.libsdl.org SDL2]&#039;&#039;&#039; || Windowing, input, audio&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://boost.org Boost]&#039;&#039;&#039; (locale, program-options, uuid, crc) || Localisation, settings management, hash functions&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://xiph.org/vorbis/ LibVorbis]&#039;&#039;&#039; || Ogg Vorbis music decoding&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://www.qt.io/ Qt]&#039;&#039;&#039; (Qt5 or Qt6 base) || Launcher GUI (optional)&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://nongnu.org/libunwind/download.html libunwind]&#039;&#039;&#039; || Debug backtracing (Linux only)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Bundled Dependencies (Submodules) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Library !! Purpose&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/fmtlib/fmt fmtlib (fmt)]&#039;&#039;&#039; || C++ string formatting library&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://glm.g-truc.net GLM]&#039;&#039;&#039; || Math library (vectors, matrices, etc.)&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://sourceforge.net/projects/libsmacker/ libsmacker]&#039;&#039;&#039; || Decoder for &amp;lt;code&amp;gt;.smk&amp;lt;/code&amp;gt; video files&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/lvandeve/lodepng lodepng]&#039;&#039;&#039; || Reading/writing PNG image files&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://www.lua.org/ Lua]&#039;&#039;&#039; || Scripting language&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/Neargye/magic_enum magic_enum]&#039;&#039;&#039; || Header-only C++17 static reflection for enums&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/richgel999/miniz miniz]&#039;&#039;&#039; || Zlib-compatible compression library&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://icculus.org/physfs/ PhysFS]&#039;&#039;&#039; (patched) || Reading data from &amp;lt;code&amp;gt;.iso&amp;lt;/code&amp;gt; files and directory trees&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://pugixml.org pugixml]&#039;&#039;&#039; || XML library for game data files&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Acknowledgements ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Julian Gollop&#039;&#039;&#039; &amp;amp;mdash; Original designer of X-COM: Apocalypse. Has publicly endorsed the OpenApoc project.&lt;br /&gt;
* &#039;&#039;&#039;MicroProse / Mythos Games&#039;&#039;&#039; &amp;amp;mdash; Original developers of X-COM: Apocalypse (1997)&lt;br /&gt;
* The [https://www.ufopaedia.org/index.php UFOpaedia] community for maintaining comprehensive X-COM documentation&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[OpenApoc]] &amp;amp;mdash; Main OpenApoc page&lt;br /&gt;
* [[Compiling (OpenApoc)]] &amp;amp;mdash; Building from source (for potential contributors)&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc OpenApoc on GitHub] &amp;amp;mdash; Source code and issue tracker&lt;br /&gt;
* [https://github.com/ayrtondenner/OpenApoc-wiki OpenApoc Wiki] &amp;amp;mdash; Extended developer and game mechanics documentation&lt;br /&gt;
* [https://discord.gg/f8Rayre OpenApoc Discord] &amp;amp;mdash; Community discussion&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Controls_(OpenApoc)&amp;diff=126337</id>
		<title>Controls (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Controls_(OpenApoc)&amp;diff=126337"/>
		<updated>2026-03-01T21:26:27Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Major rewrite: complete controls reference for v0.0.49+; added Cityscape and Battlescape hotkey tables&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;OpenApoc aims to implement all controls from the original game while introducing new hotkeys to improve interface usability. A key addition is the &#039;&#039;&#039;improved city control scheme&#039;&#039;&#039; — a completely new, consistent control system using modifier keys. This can be disabled via the &amp;quot;Improved city control scheme&amp;quot; option in the More Options menu to restore vanilla behavior.&lt;br /&gt;
&lt;br /&gt;
For debug and cheat hotkeys, see [[Hidden Features (OpenApoc)]].&lt;br /&gt;
&lt;br /&gt;
== General UI Hotkeys ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Mousewheel || Scroll lists&lt;br /&gt;
|-&lt;br /&gt;
| Esc || Go back, close form, &amp;quot;Cancel&amp;quot; option&lt;br /&gt;
|-&lt;br /&gt;
| Enter || Go forward, &amp;quot;Confirm&amp;quot; option, first option (e.g., real-time in briefing)&lt;br /&gt;
|-&lt;br /&gt;
| Space || Skip, second non-cancel option (e.g., turn-based in briefing, equip button in squad assignment)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== General Hotkeys ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Middle Click || Move camera to location&lt;br /&gt;
|-&lt;br /&gt;
| Arrow Keys || Move camera around&lt;br /&gt;
|-&lt;br /&gt;
| Tab || Toggle map&lt;br /&gt;
|-&lt;br /&gt;
| Space || Pause / Resume time (including turn-based)&lt;br /&gt;
|-&lt;br /&gt;
| Esc || Options menu&lt;br /&gt;
|-&lt;br /&gt;
| C || Toggle follow mode&lt;br /&gt;
|-&lt;br /&gt;
| M || Show message log&lt;br /&gt;
|-&lt;br /&gt;
| Home || Zoom to last event&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Cityscape Controls ==&lt;br /&gt;
&lt;br /&gt;
=== Vanilla Controls Note ===&lt;br /&gt;
&lt;br /&gt;
The original game&#039;s city controls were inconsistent and limited:&lt;br /&gt;
* Right-clicking moved the map in city but not in battle&lt;br /&gt;
* No quick access to frequently used screens (equipment, location, base)&lt;br /&gt;
* Alt/Shift hotkeys acted as if clicking a corresponding button — missing a target changed your selection mode&lt;br /&gt;
&lt;br /&gt;
OpenApoc introduces a new, consistent control scheme explained below. To restore vanilla controls, disable &amp;quot;Improved city control scheme&amp;quot; in the More Options menu. With vanilla controls:&lt;br /&gt;
* Right click moves screen to cursor&lt;br /&gt;
* Alt + Left Click orders vehicle attack&lt;br /&gt;
* Shift + Left Click orders moving to building&lt;br /&gt;
* Left-clicking on building always opens building screen&lt;br /&gt;
* No OpenApoc mouse controls will function&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Mouse (Improved Scheme) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Left Click on building || Open building screen (base screen if it contains a base)&lt;br /&gt;
|-&lt;br /&gt;
| Right Click on building || Open building screen&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Left Click || Order attack vehicle&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Right Click || Order follow vehicle / go to location&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Shift + Left Click || Order attack building&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Shift + Right Click || Order go to building&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Left Click || Open UFOpaedia for object (vehicle type, building function, or projectile source)&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Right Click || Open UFOpaedia for object&#039;s owner (vehicle or building)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Modifier Keys ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Modifier !! Effect&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl (agent move orders) || Force agents to move on foot (never call taxi); allows use of personal teleporter&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl (vehicle move orders) || Allow manual use of city teleporter buildings&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl (attack orders) || Force vehicles to attack target (instead of recovering UFOs or escorting owned vehicles)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; In vanilla, attacking owned vehicles was impossible. OpenApoc enables this via the &amp;quot;Allow attacking owned vehicles&amp;quot; toggle (on by default).&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Mouse on Vehicle / Agent Icons ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Right Click || Open location screen&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Shift + Right Click || Open equipment screen&lt;br /&gt;
|-&lt;br /&gt;
| Alt + Shift + Right Click || Open equipment screen&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Unit Selection ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Left Click || Select agent/vehicle (as the only object selected)&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Left Click || Add agent/vehicle to selection and make it first in the list&lt;br /&gt;
|-&lt;br /&gt;
| Right Click || Remove agent/vehicle from selection&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Cityscape Keyboard ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| 0, 1, 2, 3, 4, 5 || Control game speed&lt;br /&gt;
|-&lt;br /&gt;
| N || Manual control (with vanilla scheme: M is manual control and there is no way to open message log)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Vehicle Equipment ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Click || Auto-equip item into first available slot, or auto-remove to base stores&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Agent Equipment ==&lt;br /&gt;
&lt;br /&gt;
Standard selection controls apply, with the option to de-select with right click.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Click || Auto-equip item into first available slot, or auto-remove to base stores / ground&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Click on weapon || Remove clip from weapon&lt;br /&gt;
|-&lt;br /&gt;
| 1 through 0 || Apply saved equipment template to every selected agent&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + 1 through 0 || Remember current agent&#039;s equipment set as a template&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Battlescape Mouse ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Left Click || Order unit to execute action (move / throw / psi attack / teleport), open probed unit&#039;s screen, use item&lt;br /&gt;
|-&lt;br /&gt;
| Right Click || Turn towards cursor, focus enemy (real-time), use item&#039;s &amp;quot;auto&amp;quot; function (e.g., prime grenade for impact)&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Left Click || Force-fire at target tile, shot moving parallel to ground&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Alt + Left Click || Force-fire at target tile, shot aimed at tile&#039;s ground&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==== Modifier Keys ====&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Modifier !! Effect&lt;br /&gt;
|-&lt;br /&gt;
| Alt (movement) || Unit keeps facing the target while moving (strafing or moving backwards)&lt;br /&gt;
|-&lt;br /&gt;
| Alt (firing at tile) || Shot aims at the ground of the tile rather than at the unit&#039;s level&lt;br /&gt;
|-&lt;br /&gt;
| Shift || Turns cursor into attack mode&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Battlescape Unit Selection ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Input !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Left Click || Select unit (as the only unit selected)&lt;br /&gt;
|-&lt;br /&gt;
| Ctrl + Left Click || Add unit to selection and make it first in the list&lt;br /&gt;
|-&lt;br /&gt;
| Right Click || Remove unit from selection&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Battlescape Keyboard ==&lt;br /&gt;
&lt;br /&gt;
=== Movement and Fire Modes ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| PgUp / PgDown || Change map levels&lt;br /&gt;
|-&lt;br /&gt;
| V || Toggle layering&lt;br /&gt;
|-&lt;br /&gt;
| F2 || Prone mode&lt;br /&gt;
|-&lt;br /&gt;
| F3 || Walk mode&lt;br /&gt;
|-&lt;br /&gt;
| F4 || Run mode&lt;br /&gt;
|-&lt;br /&gt;
| F5 || Cease fire mode&lt;br /&gt;
|-&lt;br /&gt;
| F6 || Aimed mode&lt;br /&gt;
|-&lt;br /&gt;
| F7 || Snap mode&lt;br /&gt;
|-&lt;br /&gt;
| F8 || Auto mode&lt;br /&gt;
|-&lt;br /&gt;
| F9 || Evasive mode&lt;br /&gt;
|-&lt;br /&gt;
| F10 || Normal mode&lt;br /&gt;
|-&lt;br /&gt;
| F11 || Aggressive mode&lt;br /&gt;
|-&lt;br /&gt;
| Backspace || Kneel mode&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Squad and Unit Selection ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| 1 through 6 || Select squad&lt;br /&gt;
|-&lt;br /&gt;
| Shift + 1 through 6 || Select unit in current squad (as the only unit selected)&lt;br /&gt;
|-&lt;br /&gt;
| Shift + Ctrl + 1 through 6 || Add unit to selection and make it first in the list&lt;br /&gt;
|-&lt;br /&gt;
| Alt + 1 through 6 || Cycle through spotted enemies of the selected unit&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Actions ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Key !! Action&lt;br /&gt;
|-&lt;br /&gt;
| Enter || Open inventory&lt;br /&gt;
|-&lt;br /&gt;
| [ || Throw right hand item&lt;br /&gt;
|-&lt;br /&gt;
| ] || Throw left hand item&lt;br /&gt;
|-&lt;br /&gt;
| &#039; || Drop right hand item&lt;br /&gt;
|-&lt;br /&gt;
| &amp;amp;#92; || Drop left hand item&lt;br /&gt;
|-&lt;br /&gt;
| Y || Confirm priming&lt;br /&gt;
|-&lt;br /&gt;
| N || Cancel priming&lt;br /&gt;
|-&lt;br /&gt;
| E || End your turn (turn-based mode)&lt;br /&gt;
|-&lt;br /&gt;
| S || Open save menu&lt;br /&gt;
|-&lt;br /&gt;
| L || Open load menu&lt;br /&gt;
|-&lt;br /&gt;
| J || Make unit jump (down from a cliff)&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[Hidden Features (OpenApoc)]] — debug hotkeys and cheat system&lt;br /&gt;
* [[Improvements (OpenApoc)]] — toggle-able gameplay improvements&lt;br /&gt;
* [https://github.com/ayrtondenner/OpenApoc-wiki/blob/master/openapoc/controls.md OpenApoc Wiki: Controls] &amp;amp;mdash; Extended controls documentation&lt;br /&gt;
* [[OpenApoc]] — main OpenApoc page&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Compiling_(OpenApoc)&amp;diff=126336</id>
		<title>Compiling (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Compiling_(OpenApoc)&amp;diff=126336"/>
		<updated>2026-03-01T21:21:45Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Added reference to build documentation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{DISPLAYTITLE:Compiling (OpenApoc)}}&lt;br /&gt;
This page describes how to compile &#039;&#039;&#039;[[OpenApoc]]&#039;&#039;&#039; from source on Windows, Linux, and macOS.&lt;br /&gt;
&lt;br /&gt;
OpenApoc is written in &#039;&#039;&#039;C++17&#039;&#039;&#039; and uses &#039;&#039;&#039;[https://cmake.org CMake]&#039;&#039;&#039; (minimum version &#039;&#039;&#039;3.30&#039;&#039;&#039;) as its build system. It targets GCC 8+, Clang 7+, and MSVC 2019+ (Visual Studio 2017 or later).&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Important:&#039;&#039;&#039; You will need a copy of the original X-COM: Apocalypse CD image (&amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt;) placed in the &amp;lt;code&amp;gt;data/&amp;lt;/code&amp;gt; directory of the source tree. The build process extracts game data tables from this file.&lt;br /&gt;
&lt;br /&gt;
== Prerequisites ==&lt;br /&gt;
&lt;br /&gt;
All platforms require:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[https://git-scm.com Git]&#039;&#039;&#039; &amp;amp;mdash; to clone the repository and fetch submodules&lt;br /&gt;
* &#039;&#039;&#039;[https://cmake.org CMake] 3.30&#039;&#039;&#039; or newer&lt;br /&gt;
* A C++17-capable compiler:&lt;br /&gt;
** &#039;&#039;&#039;GCC 8+&#039;&#039;&#039; (Linux)&lt;br /&gt;
** &#039;&#039;&#039;Clang 7+&#039;&#039;&#039; (Linux / macOS)&lt;br /&gt;
** &#039;&#039;&#039;MSVC 2019+&#039;&#039;&#039; / Visual Studio 2017 or later (Windows)&lt;br /&gt;
* The original &#039;&#039;&#039;X-COM: Apocalypse&#039;&#039;&#039; disc image (&amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt;) &amp;amp;mdash; placed in &amp;lt;code&amp;gt;data/&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== External Dependencies ==&lt;br /&gt;
&lt;br /&gt;
The following libraries must be installed on your system (or via vcpkg on Windows). These are &#039;&#039;&#039;not&#039;&#039;&#039; bundled with the source code:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Library !! Purpose !! Notes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://www.libsdl.org SDL2]&#039;&#039;&#039; || Windowing, input, audio || Required on all platforms&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://boost.org Boost]&#039;&#039;&#039; (locale, program-options, uuid, crc) || Localisation, settings management, hash functions || Only these specific Boost libraries are needed&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://xiph.org/vorbis/ LibVorbis]&#039;&#039;&#039; || Ogg Vorbis music decoding || Required on all platforms&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://www.qt.io/ Qt]&#039;&#039;&#039; (Qt5 or Qt6 base) || Launcher GUI || Optional; can be disabled with &amp;lt;code&amp;gt;BUILD_LAUNCHER=OFF&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://nongnu.org/libunwind/download.html libunwind]&#039;&#039;&#039; || Debug backtracing || Linux only; not needed on Windows or macOS&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; Previous versions of this wiki page incorrectly listed &amp;lt;code&amp;gt;tinyformat&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;libboost-filesystem-dev&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;libboost-system-dev&amp;lt;/code&amp;gt;, and &amp;lt;code&amp;gt;qtdeclarative5-dev&amp;lt;/code&amp;gt; as dependencies. These are &#039;&#039;&#039;not&#039;&#039;&#039; required. The formatting library is &amp;lt;code&amp;gt;fmtlib&amp;lt;/code&amp;gt; (bundled as a submodule), and only &amp;lt;code&amp;gt;boost-locale&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;boost-program-options&amp;lt;/code&amp;gt; (plus &amp;lt;code&amp;gt;boost-uuid&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;boost-crc&amp;lt;/code&amp;gt;) are needed from Boost.&lt;br /&gt;
&lt;br /&gt;
== Bundled Dependencies (Submodules) ==&lt;br /&gt;
&lt;br /&gt;
The following libraries are included as Git submodules in the &amp;lt;code&amp;gt;dependencies/&amp;lt;/code&amp;gt; directory and are built automatically as part of the OpenApoc build. You do &#039;&#039;&#039;not&#039;&#039;&#039; need to install these separately:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Library !! Purpose&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://glm.g-truc.net GLM]&#039;&#039;&#039; || Math library (vectors, matrices, etc.)&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://sourceforge.net/projects/libsmacker/ libsmacker]&#039;&#039;&#039; || Decoder for &amp;lt;code&amp;gt;.smk&amp;lt;/code&amp;gt; video files&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/lvandeve/lodepng lodepng]&#039;&#039;&#039; || Reading/writing PNG image files&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://www.lua.org/ Lua]&#039;&#039;&#039; || Scripting language&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/richgel999/miniz miniz]&#039;&#039;&#039; || Zlib-compatible compression library&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://icculus.org/physfs/ PhysFS]&#039;&#039;&#039; (patched) || Reading data from &amp;lt;code&amp;gt;.iso&amp;lt;/code&amp;gt; files and directory trees&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://pugixml.org pugixml]&#039;&#039;&#039; || XML library for game data files&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/fmtlib/fmt fmtlib (fmt)]&#039;&#039;&#039; || C++ string formatting library&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/Neargye/magic_enum magic_enum]&#039;&#039;&#039; || Header-only C++17 static reflection for enums&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
To fetch or update all submodules, run:&lt;br /&gt;
&lt;br /&gt;
 git submodule update --init --recursive&lt;br /&gt;
&lt;br /&gt;
== Building on Windows ==&lt;br /&gt;
&lt;br /&gt;
=== Requirements ===&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[https://visualstudio.microsoft.com/vs/ Visual Studio]&#039;&#039;&#039; 2017 or later, with the &amp;quot;Desktop Development with C++&amp;quot; workload installed&lt;br /&gt;
* &#039;&#039;&#039;[https://github.com/Microsoft/vcpkg Vcpkg]&#039;&#039;&#039; package manager (for external dependencies)&lt;br /&gt;
&lt;br /&gt;
=== Step-by-step ===&lt;br /&gt;
&lt;br /&gt;
# Install Visual Studio with the &amp;quot;Desktop Development with C++&amp;quot; workload.&lt;br /&gt;
# Install a Git client (e.g. [https://desktop.github.com/ GitHub Desktop]) and clone the OpenApoc repository.&lt;br /&gt;
# Initialize the submodules:&lt;br /&gt;
#: &amp;lt;code&amp;gt;git submodule update --init --recursive&amp;lt;/code&amp;gt;&lt;br /&gt;
# Install [https://github.com/Microsoft/vcpkg Vcpkg] and integrate it with Visual Studio.&lt;br /&gt;
# Install the required dependencies via vcpkg. For &#039;&#039;&#039;x64&#039;&#039;&#039; builds:&lt;br /&gt;
#: &amp;lt;code&amp;gt;vcpkg --triplet x64-windows install sdl2 boost-locale boost-program-options boost-uuid boost-crc qt-base6-dev libvorbis&amp;lt;/code&amp;gt;&lt;br /&gt;
#: For &#039;&#039;&#039;x86&#039;&#039;&#039; builds, replace &amp;lt;code&amp;gt;x64-windows&amp;lt;/code&amp;gt; with &amp;lt;code&amp;gt;x86-windows&amp;lt;/code&amp;gt;.&lt;br /&gt;
#: To see all supported architectures: &amp;lt;code&amp;gt;vcpkg help triplet&amp;lt;/code&amp;gt;&lt;br /&gt;
# Copy your &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt; file into the &amp;lt;code&amp;gt;data/&amp;lt;/code&amp;gt; directory.&lt;br /&gt;
# Open the OpenApoc directory in Visual Studio. If your version of Visual Studio does not have an &amp;quot;Open Folder&amp;quot; option, generate a project using CMake.&lt;br /&gt;
# Set the configuration to &#039;&#039;&#039;x64-Release&#039;&#039;&#039; (or &#039;&#039;&#039;x86-Release&#039;&#039;&#039;) &amp;amp;mdash; must match your vcpkg triplet. Release is recommended because Debug builds are very slow.&lt;br /&gt;
# Visual Studio should automatically detect and configure CMake. If you did not integrate vcpkg globally, set the CMake toolchain file manually:&lt;br /&gt;
#* &#039;&#039;&#039;Visual Studio 2017:&#039;&#039;&#039; Add to your CMake settings JSON:&lt;br /&gt;
#*: &amp;lt;code&amp;gt;&amp;quot;CMAKE_TOOLCHAIN_FILE&amp;quot;: &amp;quot;&amp;amp;lt;path to vcpkg&amp;amp;gt;\\scripts\\buildsystems\\vcpkg.cmake&amp;quot;&amp;lt;/code&amp;gt;&lt;br /&gt;
#* &#039;&#039;&#039;Visual Studio 2019+:&#039;&#039;&#039; Build &amp;amp;rarr; CMake Settings &amp;amp;rarr; Toolchain file &amp;amp;rarr; &amp;lt;code&amp;gt;&amp;lt;path to vcpkg&amp;gt;\scripts\buildsystems\vcpkg.cmake&amp;lt;/code&amp;gt;&lt;br /&gt;
# Build the project. The first build may take a while, especially if vcpkg has not yet built all dependencies.&lt;br /&gt;
&lt;br /&gt;
=== Running ===&lt;br /&gt;
&lt;br /&gt;
When running from Visual Studio, the working directory is set to the project root, so the &amp;lt;code&amp;gt;data/&amp;lt;/code&amp;gt; folder is found automatically. If running outside Visual Studio, copy the entire &amp;lt;code&amp;gt;data/&amp;lt;/code&amp;gt; folder (including &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt;) into the directory containing &amp;lt;code&amp;gt;openapoc.exe&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== Building on Linux ==&lt;br /&gt;
&lt;br /&gt;
=== Ubuntu (22.04 / 24.04) ===&lt;br /&gt;
&lt;br /&gt;
Install the required packages:&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install libsdl2-dev cmake build-essential git libunwind8-dev \&lt;br /&gt;
     libboost-locale-dev libboost-program-options-dev qtbase5-dev libvorbis-dev&lt;br /&gt;
&lt;br /&gt;
Clone the repository and initialize submodules:&lt;br /&gt;
&lt;br /&gt;
 git clone &amp;lt;nowiki&amp;gt;https://github.com/OpenApoc/OpenApoc.git&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
 cd OpenApoc&lt;br /&gt;
 git submodule update --init --recursive&lt;br /&gt;
&lt;br /&gt;
Copy the CD image:&lt;br /&gt;
&lt;br /&gt;
 cp /path/to/cd.iso data/&lt;br /&gt;
&lt;br /&gt;
Configure and build:&lt;br /&gt;
&lt;br /&gt;
 mkdir build&lt;br /&gt;
 cd build&lt;br /&gt;
 cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo ..&lt;br /&gt;
 make -j$(nproc)&lt;br /&gt;
&lt;br /&gt;
Run:&lt;br /&gt;
&lt;br /&gt;
 cd ..&lt;br /&gt;
 ./build/bin/OpenApoc&lt;br /&gt;
&lt;br /&gt;
=== Fedora / Red Hat ===&lt;br /&gt;
&lt;br /&gt;
Install the required packages (as root):&lt;br /&gt;
&lt;br /&gt;
 yum groupinstall &amp;quot;Development Tools&amp;quot; &amp;quot;Development Libraries&amp;quot;&lt;br /&gt;
 yum install git SDL2-devel cmake libunwind-devel qt6-qtbase-devel libvorbis-devel&lt;br /&gt;
&lt;br /&gt;
Then follow the same clone, submodule, configure, and build steps as Ubuntu above.&lt;br /&gt;
&lt;br /&gt;
=== Mageia ===&lt;br /&gt;
&lt;br /&gt;
Install the required packages (as root):&lt;br /&gt;
&lt;br /&gt;
 urpmi &amp;quot;cmake(sdl2)&amp;quot; libstdc++-static-devel boost-devel boost unwind-devel \&lt;br /&gt;
     task-c++-devel cmake git qt6-devel libvorbis-devel&lt;br /&gt;
&lt;br /&gt;
Then follow the same clone, submodule, configure, and build steps as Ubuntu above.&lt;br /&gt;
&lt;br /&gt;
=== Optional CMake flags (all distributions) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Flag !! Default !! Description&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;CMAKE_BUILD_TYPE&amp;lt;/code&amp;gt; || (none) || Set to &amp;lt;code&amp;gt;RelWithDebInfo&amp;lt;/code&amp;gt; for optimized builds with debug symbols, or &amp;lt;code&amp;gt;Release&amp;lt;/code&amp;gt; for maximum optimization&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;BUILD_LAUNCHER&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;ON&amp;lt;/code&amp;gt; || Build the Qt-based launcher GUI; set to &amp;lt;code&amp;gt;OFF&amp;lt;/code&amp;gt; to skip Qt dependency&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;USE_SYSTEM_QT&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;OFF&amp;lt;/code&amp;gt; || Use system-installed Qt instead of the vcpkg package&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;ENABLE_TESTS&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;ON&amp;lt;/code&amp;gt; || Build unit tests (run with &amp;lt;code&amp;gt;ctest&amp;lt;/code&amp;gt; from the build directory)&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;LTO&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;OFF&amp;lt;/code&amp;gt; || Enable link-time optimization&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;EXTRACT_DATA&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;ON&amp;lt;/code&amp;gt; || Run the data extractor as part of the default build target&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;CD_PATH&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;data/cd.iso&amp;lt;/code&amp;gt; || Path to the X-COM: Apocalypse disc image&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Building on macOS ==&lt;br /&gt;
&lt;br /&gt;
Tested on macOS Sequoia 15.6.&lt;br /&gt;
&lt;br /&gt;
=== Requirements ===&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[https://brew.sh Homebrew]&#039;&#039;&#039; package manager&lt;br /&gt;
&lt;br /&gt;
=== Step-by-step ===&lt;br /&gt;
&lt;br /&gt;
# Install Homebrew if not already present:&lt;br /&gt;
#: &amp;lt;code&amp;gt;/bin/bash -c &amp;quot;$(curl -fsSL &amp;lt;nowiki&amp;gt;https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh&amp;lt;/nowiki&amp;gt;)&amp;quot;&amp;lt;/code&amp;gt;&lt;br /&gt;
# Clone the repository and initialize submodules:&lt;br /&gt;
#: &amp;lt;code&amp;gt;git clone &amp;lt;nowiki&amp;gt;https://github.com/OpenApoc/OpenApoc.git&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
#: &amp;lt;code&amp;gt;cd OpenApoc&amp;lt;/code&amp;gt;&lt;br /&gt;
#: &amp;lt;code&amp;gt;git submodule update --init --recursive&amp;lt;/code&amp;gt;&lt;br /&gt;
# Install dependencies via Homebrew:&lt;br /&gt;
#: &amp;lt;code&amp;gt;brew install cmake boost pkg-config sdl2 qt@6 libvorbis&amp;lt;/code&amp;gt;&lt;br /&gt;
# Add Qt to your PATH. If using &#039;&#039;&#039;zsh&#039;&#039;&#039; (default since macOS Catalina):&lt;br /&gt;
#: &amp;lt;code&amp;gt;echo &#039;export PATH=&amp;quot;/opt/homebrew/opt/qt@6/bin:$PATH&amp;quot;&#039; &amp;gt;&amp;gt; ~/.zprofile&amp;lt;/code&amp;gt;&lt;br /&gt;
#: If using &#039;&#039;&#039;bash&#039;&#039;&#039;:&lt;br /&gt;
#: &amp;lt;code&amp;gt;echo &#039;export PATH=&amp;quot;/opt/homebrew/opt/qt@6/bin:$PATH&amp;quot;&#039; &amp;gt;&amp;gt; ~/.bashrc&amp;lt;/code&amp;gt;&lt;br /&gt;
#: Then reload your shell or run &amp;lt;code&amp;gt;source ~/.zprofile&amp;lt;/code&amp;gt; (or &amp;lt;code&amp;gt;source ~/.bashrc&amp;lt;/code&amp;gt;).&lt;br /&gt;
# Copy the CD image:&lt;br /&gt;
#: &amp;lt;code&amp;gt;cp /path/to/cd.iso data/&amp;lt;/code&amp;gt;&lt;br /&gt;
# Configure and build:&lt;br /&gt;
#: &amp;lt;code&amp;gt;mkdir build&amp;lt;/code&amp;gt;&lt;br /&gt;
#: &amp;lt;code&amp;gt;cd build&amp;lt;/code&amp;gt;&lt;br /&gt;
#: &amp;lt;code&amp;gt;cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo ..&amp;lt;/code&amp;gt;&lt;br /&gt;
#: &amp;lt;code&amp;gt;make -j$(sysctl -n hw.ncpu)&amp;lt;/code&amp;gt;&lt;br /&gt;
# Run the application:&lt;br /&gt;
#: &amp;lt;code&amp;gt;cd ..&amp;lt;/code&amp;gt;&lt;br /&gt;
#: &amp;lt;code&amp;gt;open ./build/bin/OpenApoc.app&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Running Tests ==&lt;br /&gt;
&lt;br /&gt;
After building, you can run the unit tests from the build directory:&lt;br /&gt;
&lt;br /&gt;
 cd build&lt;br /&gt;
 ctest&lt;br /&gt;
&lt;br /&gt;
== Common Issues / Troubleshooting ==&lt;br /&gt;
&lt;br /&gt;
=== CMake version too old ===&lt;br /&gt;
&lt;br /&gt;
OpenApoc requires &#039;&#039;&#039;CMake 3.30&#039;&#039;&#039; or newer. If your distribution ships an older version, download the latest from [https://cmake.org/download/ cmake.org] or install via &amp;lt;code&amp;gt;pip install cmake&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Submodule errors / missing dependencies directory ===&lt;br /&gt;
&lt;br /&gt;
If you see errors about missing files in &amp;lt;code&amp;gt;dependencies/&amp;lt;/code&amp;gt;, ensure you have initialized the submodules:&lt;br /&gt;
&lt;br /&gt;
 git submodule update --init --recursive&lt;br /&gt;
&lt;br /&gt;
If you previously cloned without &amp;lt;code&amp;gt;--recursive&amp;lt;/code&amp;gt;, this command will fetch all required submodules.&lt;br /&gt;
&lt;br /&gt;
=== cd.iso not found ===&lt;br /&gt;
&lt;br /&gt;
The build expects the original X-COM: Apocalypse disc image at &amp;lt;code&amp;gt;data/cd.iso&amp;lt;/code&amp;gt; by default. You can change this path with:&lt;br /&gt;
&lt;br /&gt;
 cmake -DCD_PATH=/path/to/cd.iso ..&lt;br /&gt;
&lt;br /&gt;
Supported formats:&lt;br /&gt;
* A standard &amp;lt;code&amp;gt;.iso&amp;lt;/code&amp;gt; file (rename to &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt;)&lt;br /&gt;
* A directory containing extracted CD files (name the directory &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt;)&lt;br /&gt;
* GOG &amp;lt;code&amp;gt;.cue&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;.bin&amp;lt;/code&amp;gt; files: rename the &amp;lt;code&amp;gt;.cue&amp;lt;/code&amp;gt; file to &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt; and place the &amp;lt;code&amp;gt;.bin&amp;lt;/code&amp;gt; file alongside it in &amp;lt;code&amp;gt;data/&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Debug builds are very slow ===&lt;br /&gt;
&lt;br /&gt;
This is expected. Use &amp;lt;code&amp;gt;RelWithDebInfo&amp;lt;/code&amp;gt; for a build that is optimized but still has debug symbols:&lt;br /&gt;
&lt;br /&gt;
 cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo ..&lt;br /&gt;
&lt;br /&gt;
=== Missing Qt / launcher build fails ===&lt;br /&gt;
&lt;br /&gt;
If you do not need the launcher GUI, disable it:&lt;br /&gt;
&lt;br /&gt;
 cmake -DBUILD_LAUNCHER=OFF ..&lt;br /&gt;
&lt;br /&gt;
=== Windows: Visual C++ Runtime errors ===&lt;br /&gt;
&lt;br /&gt;
When running a pre-built binary on Windows, ensure you have the latest [https://docs.microsoft.com/en-US/cpp/windows/latest-supported-vc-redist Visual C++ Redistributable] installed.&lt;br /&gt;
&lt;br /&gt;
=== OpenGL requirements ===&lt;br /&gt;
&lt;br /&gt;
OpenApoc requires &#039;&#039;&#039;OpenGL 2.0&#039;&#039;&#039; capable graphics hardware and drivers.&lt;br /&gt;
&lt;br /&gt;
=== Linux: libunwind not found ===&lt;br /&gt;
&lt;br /&gt;
On Ubuntu/Debian:&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install libunwind8-dev&lt;br /&gt;
&lt;br /&gt;
On Fedora/RHEL:&lt;br /&gt;
&lt;br /&gt;
 sudo yum install libunwind-devel&lt;br /&gt;
&lt;br /&gt;
=== macOS: Qt not found by CMake ===&lt;br /&gt;
&lt;br /&gt;
Ensure Qt is on your PATH. After installing via Homebrew:&lt;br /&gt;
&lt;br /&gt;
 export PATH=&amp;quot;/opt/homebrew/opt/qt@6/bin:$PATH&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Then re-run &amp;lt;code&amp;gt;cmake&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[OpenApoc]] &amp;amp;mdash; Main OpenApoc wiki page&lt;br /&gt;
* [[Coding Style (OpenApoc)]] &amp;amp;mdash; C++ code style guidelines&lt;br /&gt;
* [[Differences to X-COM (OpenApoc)]] &amp;amp;mdash; How OpenApoc differs from the original game&lt;br /&gt;
* [https://github.com/ayrtondenner/OpenApoc-wiki/blob/master/development/building.md OpenApoc Wiki: Building] &amp;amp;mdash; Extended build documentation&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc OpenApoc on GitHub] &amp;amp;mdash; Source code repository&lt;br /&gt;
* [https://discord.gg/d6DAHEb OpenApoc Discord] &amp;amp;mdash; Community discussion and support&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Compiling_(OpenApoc)&amp;diff=126335</id>
		<title>Compiling (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Compiling_(OpenApoc)&amp;diff=126335"/>
		<updated>2026-03-01T21:14:53Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Major rewrite: updated to C++17/CMake 3.30; corrected dependency list; added macOS and troubleshooting sections&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{DISPLAYTITLE:Compiling (OpenApoc)}}&lt;br /&gt;
This page describes how to compile &#039;&#039;&#039;[[OpenApoc]]&#039;&#039;&#039; from source on Windows, Linux, and macOS.&lt;br /&gt;
&lt;br /&gt;
OpenApoc is written in &#039;&#039;&#039;C++17&#039;&#039;&#039; and uses &#039;&#039;&#039;[https://cmake.org CMake]&#039;&#039;&#039; (minimum version &#039;&#039;&#039;3.30&#039;&#039;&#039;) as its build system. It targets GCC 8+, Clang 7+, and MSVC 2019+ (Visual Studio 2017 or later).&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Important:&#039;&#039;&#039; You will need a copy of the original X-COM: Apocalypse CD image (&amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt;) placed in the &amp;lt;code&amp;gt;data/&amp;lt;/code&amp;gt; directory of the source tree. The build process extracts game data tables from this file.&lt;br /&gt;
&lt;br /&gt;
== Prerequisites ==&lt;br /&gt;
&lt;br /&gt;
All platforms require:&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[https://git-scm.com Git]&#039;&#039;&#039; &amp;amp;mdash; to clone the repository and fetch submodules&lt;br /&gt;
* &#039;&#039;&#039;[https://cmake.org CMake] 3.30&#039;&#039;&#039; or newer&lt;br /&gt;
* A C++17-capable compiler:&lt;br /&gt;
** &#039;&#039;&#039;GCC 8+&#039;&#039;&#039; (Linux)&lt;br /&gt;
** &#039;&#039;&#039;Clang 7+&#039;&#039;&#039; (Linux / macOS)&lt;br /&gt;
** &#039;&#039;&#039;MSVC 2019+&#039;&#039;&#039; / Visual Studio 2017 or later (Windows)&lt;br /&gt;
* The original &#039;&#039;&#039;X-COM: Apocalypse&#039;&#039;&#039; disc image (&amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt;) &amp;amp;mdash; placed in &amp;lt;code&amp;gt;data/&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== External Dependencies ==&lt;br /&gt;
&lt;br /&gt;
The following libraries must be installed on your system (or via vcpkg on Windows). These are &#039;&#039;&#039;not&#039;&#039;&#039; bundled with the source code:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Library !! Purpose !! Notes&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://www.libsdl.org SDL2]&#039;&#039;&#039; || Windowing, input, audio || Required on all platforms&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://boost.org Boost]&#039;&#039;&#039; (locale, program-options, uuid, crc) || Localisation, settings management, hash functions || Only these specific Boost libraries are needed&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://xiph.org/vorbis/ LibVorbis]&#039;&#039;&#039; || Ogg Vorbis music decoding || Required on all platforms&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://www.qt.io/ Qt]&#039;&#039;&#039; (Qt5 or Qt6 base) || Launcher GUI || Optional; can be disabled with &amp;lt;code&amp;gt;BUILD_LAUNCHER=OFF&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://nongnu.org/libunwind/download.html libunwind]&#039;&#039;&#039; || Debug backtracing || Linux only; not needed on Windows or macOS&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; Previous versions of this wiki page incorrectly listed &amp;lt;code&amp;gt;tinyformat&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;libboost-filesystem-dev&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;libboost-system-dev&amp;lt;/code&amp;gt;, and &amp;lt;code&amp;gt;qtdeclarative5-dev&amp;lt;/code&amp;gt; as dependencies. These are &#039;&#039;&#039;not&#039;&#039;&#039; required. The formatting library is &amp;lt;code&amp;gt;fmtlib&amp;lt;/code&amp;gt; (bundled as a submodule), and only &amp;lt;code&amp;gt;boost-locale&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;boost-program-options&amp;lt;/code&amp;gt; (plus &amp;lt;code&amp;gt;boost-uuid&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;boost-crc&amp;lt;/code&amp;gt;) are needed from Boost.&lt;br /&gt;
&lt;br /&gt;
== Bundled Dependencies (Submodules) ==&lt;br /&gt;
&lt;br /&gt;
The following libraries are included as Git submodules in the &amp;lt;code&amp;gt;dependencies/&amp;lt;/code&amp;gt; directory and are built automatically as part of the OpenApoc build. You do &#039;&#039;&#039;not&#039;&#039;&#039; need to install these separately:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Library !! Purpose&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://glm.g-truc.net GLM]&#039;&#039;&#039; || Math library (vectors, matrices, etc.)&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://sourceforge.net/projects/libsmacker/ libsmacker]&#039;&#039;&#039; || Decoder for &amp;lt;code&amp;gt;.smk&amp;lt;/code&amp;gt; video files&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/lvandeve/lodepng lodepng]&#039;&#039;&#039; || Reading/writing PNG image files&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://www.lua.org/ Lua]&#039;&#039;&#039; || Scripting language&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/richgel999/miniz miniz]&#039;&#039;&#039; || Zlib-compatible compression library&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://icculus.org/physfs/ PhysFS]&#039;&#039;&#039; (patched) || Reading data from &amp;lt;code&amp;gt;.iso&amp;lt;/code&amp;gt; files and directory trees&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://pugixml.org pugixml]&#039;&#039;&#039; || XML library for game data files&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/fmtlib/fmt fmtlib (fmt)]&#039;&#039;&#039; || C++ string formatting library&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;[https://github.com/Neargye/magic_enum magic_enum]&#039;&#039;&#039; || Header-only C++17 static reflection for enums&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
To fetch or update all submodules, run:&lt;br /&gt;
&lt;br /&gt;
 git submodule update --init --recursive&lt;br /&gt;
&lt;br /&gt;
== Building on Windows ==&lt;br /&gt;
&lt;br /&gt;
=== Requirements ===&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[https://visualstudio.microsoft.com/vs/ Visual Studio]&#039;&#039;&#039; 2017 or later, with the &amp;quot;Desktop Development with C++&amp;quot; workload installed&lt;br /&gt;
* &#039;&#039;&#039;[https://github.com/Microsoft/vcpkg Vcpkg]&#039;&#039;&#039; package manager (for external dependencies)&lt;br /&gt;
&lt;br /&gt;
=== Step-by-step ===&lt;br /&gt;
&lt;br /&gt;
# Install Visual Studio with the &amp;quot;Desktop Development with C++&amp;quot; workload.&lt;br /&gt;
# Install a Git client (e.g. [https://desktop.github.com/ GitHub Desktop]) and clone the OpenApoc repository.&lt;br /&gt;
# Initialize the submodules:&lt;br /&gt;
#: &amp;lt;code&amp;gt;git submodule update --init --recursive&amp;lt;/code&amp;gt;&lt;br /&gt;
# Install [https://github.com/Microsoft/vcpkg Vcpkg] and integrate it with Visual Studio.&lt;br /&gt;
# Install the required dependencies via vcpkg. For &#039;&#039;&#039;x64&#039;&#039;&#039; builds:&lt;br /&gt;
#: &amp;lt;code&amp;gt;vcpkg --triplet x64-windows install sdl2 boost-locale boost-program-options boost-uuid boost-crc qt-base6-dev libvorbis&amp;lt;/code&amp;gt;&lt;br /&gt;
#: For &#039;&#039;&#039;x86&#039;&#039;&#039; builds, replace &amp;lt;code&amp;gt;x64-windows&amp;lt;/code&amp;gt; with &amp;lt;code&amp;gt;x86-windows&amp;lt;/code&amp;gt;.&lt;br /&gt;
#: To see all supported architectures: &amp;lt;code&amp;gt;vcpkg help triplet&amp;lt;/code&amp;gt;&lt;br /&gt;
# Copy your &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt; file into the &amp;lt;code&amp;gt;data/&amp;lt;/code&amp;gt; directory.&lt;br /&gt;
# Open the OpenApoc directory in Visual Studio. If your version of Visual Studio does not have an &amp;quot;Open Folder&amp;quot; option, generate a project using CMake.&lt;br /&gt;
# Set the configuration to &#039;&#039;&#039;x64-Release&#039;&#039;&#039; (or &#039;&#039;&#039;x86-Release&#039;&#039;&#039;) &amp;amp;mdash; must match your vcpkg triplet. Release is recommended because Debug builds are very slow.&lt;br /&gt;
# Visual Studio should automatically detect and configure CMake. If you did not integrate vcpkg globally, set the CMake toolchain file manually:&lt;br /&gt;
#* &#039;&#039;&#039;Visual Studio 2017:&#039;&#039;&#039; Add to your CMake settings JSON:&lt;br /&gt;
#*: &amp;lt;code&amp;gt;&amp;quot;CMAKE_TOOLCHAIN_FILE&amp;quot;: &amp;quot;&amp;amp;lt;path to vcpkg&amp;amp;gt;\\scripts\\buildsystems\\vcpkg.cmake&amp;quot;&amp;lt;/code&amp;gt;&lt;br /&gt;
#* &#039;&#039;&#039;Visual Studio 2019+:&#039;&#039;&#039; Build &amp;amp;rarr; CMake Settings &amp;amp;rarr; Toolchain file &amp;amp;rarr; &amp;lt;code&amp;gt;&amp;lt;path to vcpkg&amp;gt;\scripts\buildsystems\vcpkg.cmake&amp;lt;/code&amp;gt;&lt;br /&gt;
# Build the project. The first build may take a while, especially if vcpkg has not yet built all dependencies.&lt;br /&gt;
&lt;br /&gt;
=== Running ===&lt;br /&gt;
&lt;br /&gt;
When running from Visual Studio, the working directory is set to the project root, so the &amp;lt;code&amp;gt;data/&amp;lt;/code&amp;gt; folder is found automatically. If running outside Visual Studio, copy the entire &amp;lt;code&amp;gt;data/&amp;lt;/code&amp;gt; folder (including &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt;) into the directory containing &amp;lt;code&amp;gt;openapoc.exe&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== Building on Linux ==&lt;br /&gt;
&lt;br /&gt;
=== Ubuntu (22.04 / 24.04) ===&lt;br /&gt;
&lt;br /&gt;
Install the required packages:&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install libsdl2-dev cmake build-essential git libunwind8-dev \&lt;br /&gt;
     libboost-locale-dev libboost-program-options-dev qtbase5-dev libvorbis-dev&lt;br /&gt;
&lt;br /&gt;
Clone the repository and initialize submodules:&lt;br /&gt;
&lt;br /&gt;
 git clone &amp;lt;nowiki&amp;gt;https://github.com/OpenApoc/OpenApoc.git&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
 cd OpenApoc&lt;br /&gt;
 git submodule update --init --recursive&lt;br /&gt;
&lt;br /&gt;
Copy the CD image:&lt;br /&gt;
&lt;br /&gt;
 cp /path/to/cd.iso data/&lt;br /&gt;
&lt;br /&gt;
Configure and build:&lt;br /&gt;
&lt;br /&gt;
 mkdir build&lt;br /&gt;
 cd build&lt;br /&gt;
 cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo ..&lt;br /&gt;
 make -j$(nproc)&lt;br /&gt;
&lt;br /&gt;
Run:&lt;br /&gt;
&lt;br /&gt;
 cd ..&lt;br /&gt;
 ./build/bin/OpenApoc&lt;br /&gt;
&lt;br /&gt;
=== Fedora / Red Hat ===&lt;br /&gt;
&lt;br /&gt;
Install the required packages (as root):&lt;br /&gt;
&lt;br /&gt;
 yum groupinstall &amp;quot;Development Tools&amp;quot; &amp;quot;Development Libraries&amp;quot;&lt;br /&gt;
 yum install git SDL2-devel cmake libunwind-devel qt6-qtbase-devel libvorbis-devel&lt;br /&gt;
&lt;br /&gt;
Then follow the same clone, submodule, configure, and build steps as Ubuntu above.&lt;br /&gt;
&lt;br /&gt;
=== Mageia ===&lt;br /&gt;
&lt;br /&gt;
Install the required packages (as root):&lt;br /&gt;
&lt;br /&gt;
 urpmi &amp;quot;cmake(sdl2)&amp;quot; libstdc++-static-devel boost-devel boost unwind-devel \&lt;br /&gt;
     task-c++-devel cmake git qt6-devel libvorbis-devel&lt;br /&gt;
&lt;br /&gt;
Then follow the same clone, submodule, configure, and build steps as Ubuntu above.&lt;br /&gt;
&lt;br /&gt;
=== Optional CMake flags (all distributions) ===&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Flag !! Default !! Description&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;CMAKE_BUILD_TYPE&amp;lt;/code&amp;gt; || (none) || Set to &amp;lt;code&amp;gt;RelWithDebInfo&amp;lt;/code&amp;gt; for optimized builds with debug symbols, or &amp;lt;code&amp;gt;Release&amp;lt;/code&amp;gt; for maximum optimization&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;BUILD_LAUNCHER&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;ON&amp;lt;/code&amp;gt; || Build the Qt-based launcher GUI; set to &amp;lt;code&amp;gt;OFF&amp;lt;/code&amp;gt; to skip Qt dependency&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;USE_SYSTEM_QT&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;OFF&amp;lt;/code&amp;gt; || Use system-installed Qt instead of the vcpkg package&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;ENABLE_TESTS&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;ON&amp;lt;/code&amp;gt; || Build unit tests (run with &amp;lt;code&amp;gt;ctest&amp;lt;/code&amp;gt; from the build directory)&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;LTO&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;OFF&amp;lt;/code&amp;gt; || Enable link-time optimization&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;EXTRACT_DATA&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;ON&amp;lt;/code&amp;gt; || Run the data extractor as part of the default build target&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;CD_PATH&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;data/cd.iso&amp;lt;/code&amp;gt; || Path to the X-COM: Apocalypse disc image&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Building on macOS ==&lt;br /&gt;
&lt;br /&gt;
Tested on macOS Sequoia 15.6.&lt;br /&gt;
&lt;br /&gt;
=== Requirements ===&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;[https://brew.sh Homebrew]&#039;&#039;&#039; package manager&lt;br /&gt;
&lt;br /&gt;
=== Step-by-step ===&lt;br /&gt;
&lt;br /&gt;
# Install Homebrew if not already present:&lt;br /&gt;
#: &amp;lt;code&amp;gt;/bin/bash -c &amp;quot;$(curl -fsSL &amp;lt;nowiki&amp;gt;https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh&amp;lt;/nowiki&amp;gt;)&amp;quot;&amp;lt;/code&amp;gt;&lt;br /&gt;
# Clone the repository and initialize submodules:&lt;br /&gt;
#: &amp;lt;code&amp;gt;git clone &amp;lt;nowiki&amp;gt;https://github.com/OpenApoc/OpenApoc.git&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
#: &amp;lt;code&amp;gt;cd OpenApoc&amp;lt;/code&amp;gt;&lt;br /&gt;
#: &amp;lt;code&amp;gt;git submodule update --init --recursive&amp;lt;/code&amp;gt;&lt;br /&gt;
# Install dependencies via Homebrew:&lt;br /&gt;
#: &amp;lt;code&amp;gt;brew install cmake boost pkg-config sdl2 qt@6 libvorbis&amp;lt;/code&amp;gt;&lt;br /&gt;
# Add Qt to your PATH. If using &#039;&#039;&#039;zsh&#039;&#039;&#039; (default since macOS Catalina):&lt;br /&gt;
#: &amp;lt;code&amp;gt;echo &#039;export PATH=&amp;quot;/opt/homebrew/opt/qt@6/bin:$PATH&amp;quot;&#039; &amp;gt;&amp;gt; ~/.zprofile&amp;lt;/code&amp;gt;&lt;br /&gt;
#: If using &#039;&#039;&#039;bash&#039;&#039;&#039;:&lt;br /&gt;
#: &amp;lt;code&amp;gt;echo &#039;export PATH=&amp;quot;/opt/homebrew/opt/qt@6/bin:$PATH&amp;quot;&#039; &amp;gt;&amp;gt; ~/.bashrc&amp;lt;/code&amp;gt;&lt;br /&gt;
#: Then reload your shell or run &amp;lt;code&amp;gt;source ~/.zprofile&amp;lt;/code&amp;gt; (or &amp;lt;code&amp;gt;source ~/.bashrc&amp;lt;/code&amp;gt;).&lt;br /&gt;
# Copy the CD image:&lt;br /&gt;
#: &amp;lt;code&amp;gt;cp /path/to/cd.iso data/&amp;lt;/code&amp;gt;&lt;br /&gt;
# Configure and build:&lt;br /&gt;
#: &amp;lt;code&amp;gt;mkdir build&amp;lt;/code&amp;gt;&lt;br /&gt;
#: &amp;lt;code&amp;gt;cd build&amp;lt;/code&amp;gt;&lt;br /&gt;
#: &amp;lt;code&amp;gt;cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo ..&amp;lt;/code&amp;gt;&lt;br /&gt;
#: &amp;lt;code&amp;gt;make -j$(sysctl -n hw.ncpu)&amp;lt;/code&amp;gt;&lt;br /&gt;
# Run the application:&lt;br /&gt;
#: &amp;lt;code&amp;gt;cd ..&amp;lt;/code&amp;gt;&lt;br /&gt;
#: &amp;lt;code&amp;gt;open ./build/bin/OpenApoc.app&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Running Tests ==&lt;br /&gt;
&lt;br /&gt;
After building, you can run the unit tests from the build directory:&lt;br /&gt;
&lt;br /&gt;
 cd build&lt;br /&gt;
 ctest&lt;br /&gt;
&lt;br /&gt;
== Common Issues / Troubleshooting ==&lt;br /&gt;
&lt;br /&gt;
=== CMake version too old ===&lt;br /&gt;
&lt;br /&gt;
OpenApoc requires &#039;&#039;&#039;CMake 3.30&#039;&#039;&#039; or newer. If your distribution ships an older version, download the latest from [https://cmake.org/download/ cmake.org] or install via &amp;lt;code&amp;gt;pip install cmake&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Submodule errors / missing dependencies directory ===&lt;br /&gt;
&lt;br /&gt;
If you see errors about missing files in &amp;lt;code&amp;gt;dependencies/&amp;lt;/code&amp;gt;, ensure you have initialized the submodules:&lt;br /&gt;
&lt;br /&gt;
 git submodule update --init --recursive&lt;br /&gt;
&lt;br /&gt;
If you previously cloned without &amp;lt;code&amp;gt;--recursive&amp;lt;/code&amp;gt;, this command will fetch all required submodules.&lt;br /&gt;
&lt;br /&gt;
=== cd.iso not found ===&lt;br /&gt;
&lt;br /&gt;
The build expects the original X-COM: Apocalypse disc image at &amp;lt;code&amp;gt;data/cd.iso&amp;lt;/code&amp;gt; by default. You can change this path with:&lt;br /&gt;
&lt;br /&gt;
 cmake -DCD_PATH=/path/to/cd.iso ..&lt;br /&gt;
&lt;br /&gt;
Supported formats:&lt;br /&gt;
* A standard &amp;lt;code&amp;gt;.iso&amp;lt;/code&amp;gt; file (rename to &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt;)&lt;br /&gt;
* A directory containing extracted CD files (name the directory &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt;)&lt;br /&gt;
* GOG &amp;lt;code&amp;gt;.cue&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;.bin&amp;lt;/code&amp;gt; files: rename the &amp;lt;code&amp;gt;.cue&amp;lt;/code&amp;gt; file to &amp;lt;code&amp;gt;cd.iso&amp;lt;/code&amp;gt; and place the &amp;lt;code&amp;gt;.bin&amp;lt;/code&amp;gt; file alongside it in &amp;lt;code&amp;gt;data/&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Debug builds are very slow ===&lt;br /&gt;
&lt;br /&gt;
This is expected. Use &amp;lt;code&amp;gt;RelWithDebInfo&amp;lt;/code&amp;gt; for a build that is optimized but still has debug symbols:&lt;br /&gt;
&lt;br /&gt;
 cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo ..&lt;br /&gt;
&lt;br /&gt;
=== Missing Qt / launcher build fails ===&lt;br /&gt;
&lt;br /&gt;
If you do not need the launcher GUI, disable it:&lt;br /&gt;
&lt;br /&gt;
 cmake -DBUILD_LAUNCHER=OFF ..&lt;br /&gt;
&lt;br /&gt;
=== Windows: Visual C++ Runtime errors ===&lt;br /&gt;
&lt;br /&gt;
When running a pre-built binary on Windows, ensure you have the latest [https://docs.microsoft.com/en-US/cpp/windows/latest-supported-vc-redist Visual C++ Redistributable] installed.&lt;br /&gt;
&lt;br /&gt;
=== OpenGL requirements ===&lt;br /&gt;
&lt;br /&gt;
OpenApoc requires &#039;&#039;&#039;OpenGL 2.0&#039;&#039;&#039; capable graphics hardware and drivers.&lt;br /&gt;
&lt;br /&gt;
=== Linux: libunwind not found ===&lt;br /&gt;
&lt;br /&gt;
On Ubuntu/Debian:&lt;br /&gt;
&lt;br /&gt;
 sudo apt-get install libunwind8-dev&lt;br /&gt;
&lt;br /&gt;
On Fedora/RHEL:&lt;br /&gt;
&lt;br /&gt;
 sudo yum install libunwind-devel&lt;br /&gt;
&lt;br /&gt;
=== macOS: Qt not found by CMake ===&lt;br /&gt;
&lt;br /&gt;
Ensure Qt is on your PATH. After installing via Homebrew:&lt;br /&gt;
&lt;br /&gt;
 export PATH=&amp;quot;/opt/homebrew/opt/qt@6/bin:$PATH&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Then re-run &amp;lt;code&amp;gt;cmake&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[OpenApoc]] &amp;amp;mdash; Main OpenApoc wiki page&lt;br /&gt;
* [[Coding Style (OpenApoc)]] &amp;amp;mdash; C++ code style guidelines&lt;br /&gt;
* [[Differences to X-COM (OpenApoc)]] &amp;amp;mdash; How OpenApoc differs from the original game&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc OpenApoc on GitHub] &amp;amp;mdash; Source code repository&lt;br /&gt;
* [https://discord.gg/d6DAHEb OpenApoc Discord] &amp;amp;mdash; Community discussion and support&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=What_it_should_be._Design_doc_(OpenApoc)&amp;diff=126334</id>
		<title>What it should be. Design doc (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=What_it_should_be._Design_doc_(OpenApoc)&amp;diff=126334"/>
		<updated>2026-03-01T21:09:18Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Added See Also section and Category tag, fixed some typos&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[File:Big Apoc Concept Logo.png|right|260px]]&lt;br /&gt;
{{tocrightsticky}}&lt;br /&gt;
&amp;lt;div style=&amp;quot;width:-webkit-calc(100% - 20em);width: -moz-calc(100% - 20em);width: -o-calc(100% - 20em);width: calc(100% - 20em);text-align:justify;&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre style=&amp;quot;background:#121619;color:#939393;font-family: Arial; font-size: 1.2em; border-radius: 5px;&amp;quot;&amp;gt; The purpose of this work is to make OpenApoc more balanced, to provide a variety of interesting gameplay solutions, and to make the game more complex and deep (especially in superhuman and god mode). Balance changes are designed to increase the number of viable strategies in the game, so that one universal set of equipment is not used for each agent and the same tactics in each mission. The document was written without regard to the difficulties of translating such ideas as an attempt to get closer to the ideal. An attempt was also made to develop the theme of the main antagonists of the game. A lot of ideas were borrowed from everywhere, if you find out or want to add your own idea - there is a Discussion. This work is dedicated to fans and developers of OpenApoc and Apoc and all XCom fans in general. &amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre style=&amp;quot;background:#edb500;color:#444444;font-family: Arial; font-size: 1.2em; border-radius: 5px;&amp;quot;&amp;gt; This page is mainly translated from Russian using translator sites and and some parts of the texts is manually edited to make it more clear. Please understand this fact, if you want to correct something, you can write in Discussion&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Big Apoc Concept =&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;This a WIP page, please feel free to add your own ideas here or in [[Talk:What_it_should_be._Design_doc_(OpenApoc)|Discussion]]&#039;&#039;&#039;&lt;br /&gt;
* Ⓜ - big changes in the code that require, most likely, a separate mod&lt;br /&gt;
* Ⓒ - functions that were cut from the original or were in the plans&lt;br /&gt;
* Ⓘ - features that have images in ufopedias and in the game and are already imported into OpenApoc but do not have mechanics&lt;br /&gt;
&lt;br /&gt;
= General provisions =&lt;br /&gt;
&lt;br /&gt;
* I must say that in the future some of the original “problems” of the original could have been considered, of course, if not for the premature release of the game.&lt;br /&gt;
* You need to create a simple intro video or a simple LORE Apo slideshow of factions of various types of sentient beings and the struggle between them.&lt;br /&gt;
* You need to create a simple introductory video or a simple slideshow on the basics of tactical combat for task forces. studopedia.info/2-2651.html&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Menu mechanics =&lt;br /&gt;
&lt;br /&gt;
The ability to arrange vehicles and agents in an order that I choose. I find it ANNOYING that my main team of 18 agents who I hired from the beginning, gets messed up by new hires being inserted between those agents.&lt;br /&gt;
&lt;br /&gt;
=Cityscape gameplay, balance=&lt;br /&gt;
&lt;br /&gt;
# The armor and durability of UFO vehicles must be doubled - UFOs must pose a real threat and this is better than doubling their numbers.&lt;br /&gt;
# The very first types of UFOs should be types 3 and 4, and types 1 and 2 simply escort them in large quantities.&lt;br /&gt;
# Ⓜ XCOM can execute third-party contracts:&lt;br /&gt;
## reflection of the raid on the building of criminals using alien weapons,&lt;br /&gt;
## raid on clearing a building from a gang using alien weapons,&lt;br /&gt;
## raid on the cleaning up laboratory engaged in research and development of alien weapons&lt;br /&gt;
## capture of the leader of the organization that was captured by aliens (100%) after which you can start reducing the percentage of infiltration by aliens by conducting raids,&lt;br /&gt;
## saving the sectoids from research conducted over them to replenish psi recruits (and increase the rating),&lt;br /&gt;
## saving androids enslaved and used as machines (and rating upgrades),&lt;br /&gt;
## reflection of the attacks and raids of the Cult of Sirius on other organizations that they will start when the infiltration reaches 100%&lt;br /&gt;
&lt;br /&gt;
=Battlescape gameplay, balance=&lt;br /&gt;
&lt;br /&gt;
# From the very beginning of the game, agents with high skills but for high salaries should also be available for hire.&lt;br /&gt;
# In the UFO ships from the very beginning of the game there should be random crews from all possible types of aliens, random numbers including Psimorph or Micronoid Aggregate.&lt;br /&gt;
# In each crew of a ship, a UFO must be at least 1-2 Micronoid Aggregate.&lt;br /&gt;
# Psimorph and Micronoid Aggregate should never attack first, and will go into melee only if all the other aliens are dead and there is no way to retreat.&lt;br /&gt;
# If Psimorph or Micronoid Aggregate is present on a mission, all agents should be seriously reduced in morale, as a result of its powerful psy field.&lt;br /&gt;
## Such a field is exhausting, therefore, Stamina and Bravery noticeably sags, first Stamina and after Bravery and Accuracy.&lt;br /&gt;
## Androids are immune to the effects of the psi field — another reason to take them on a mission.&lt;br /&gt;
# All psionics in the game must see the victim in person, or at least through the eyes of another fighter&lt;br /&gt;
# If Stamina drops to zero, then Accuracy should decrease dramatically.&lt;br /&gt;
# Androids should not be under the control of the Brainsackers&lt;br /&gt;
# If 30-50% of the aliens were killed in a collision with X-COM, the rest must leave the battlefield and move to another building.&lt;br /&gt;
&lt;br /&gt;
== Weapons and Technologies ==&lt;br /&gt;
# Anti-alien toxins are extinguished by shield-destroyers.&lt;br /&gt;
# &amp;quot;Toxin A&amp;quot; &amp;quot;Toxin B&amp;quot; &amp;quot;Toxin C&amp;quot; are blocked by shields-destroyers.&lt;br /&gt;
# Personal teleporters cannot be used for agents (only organic can teleport).&lt;br /&gt;
# Ⓜ Criminal gangs should have a lot of old weapons familiar to us (Kalashnikov or M16) which can be picked up from their dead bodies.&lt;br /&gt;
# Ⓜ Criminal groups should very rarely have weapons from the first wars against aliens, but not necessarily cartridges for them, you can pick them up from their dead bodies.&lt;br /&gt;
# Ⓜ The game should just have a black market&lt;br /&gt;
# Ⓜ Hackers. The ability of agents to break open at the beginning of the mission and take control of the building system: close doors and elevators, isolate aliens in separate rooms, only agents can use doors and elevators.&lt;br /&gt;
## Aliens will not be able to escape from the mission or the chance to escape will be reduced in proportion to the number of hackers.&lt;br /&gt;
## For this, you may need a hacker set in the form of a device like a laptop that the agent will hold in his hand for the hacking effect to work.&lt;br /&gt;
## The fastest hacking androids - another reason to take them on a mission.&lt;br /&gt;
## People crack the system longer but the chance for the aliens is less&lt;br /&gt;
&lt;br /&gt;
=Diversity on UFO crash missions=&lt;br /&gt;
or &#039;&#039;&#039;[MOD concept] Diversity: UFO crash missions&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Ⓜ Crash clearing missions can be random timers and triggers that can stop the timer. For instance:&lt;br /&gt;
&lt;br /&gt;
There may be several timers and some hidden ones, and some timers will need a trigger for it to appear.&lt;br /&gt;
# Kill all aliens&lt;br /&gt;
# Kill all Psimorph or Micronoid Aggregate or both because they increase the strength of the psi field (the psi field exhausts and lowers morale so Stamina and Bravery noticeably sag, first Stamina and then Bravery and Accuracy.)&lt;br /&gt;
# Capture the UFO control room and Destroy the UFO control system.&lt;br /&gt;
# At least 3 agents must penetrate the first level of UFOs and hold it.&lt;br /&gt;
# If the timer does not stop the mission will be:&lt;br /&gt;
## failed and the UFO will fly away.&lt;br /&gt;
## The strength of the psi alien field intensify&lt;br /&gt;
## Aliens will begin a massive assault.&lt;br /&gt;
## is complicated by the arriving gangs of marauders.&lt;br /&gt;
## complicated by the arising cultists of Sirius.&lt;br /&gt;
#Types of missions UFO crash should be more diverse, for example:&lt;br /&gt;
# Landing a damaged ship is a very difficult task and sometimes a UFO can simply explode without coping with the landing (leaving nothing).&lt;br /&gt;
# A damaged UFO that has landed can be destroyed by the organization’s ship next to which the UFO fell.&lt;br /&gt;
# After an air battle and an emergency landing, the corpses of aliens who died during the air battle and landing scattered inside the UFO should remain (most aliens are alive).&lt;br /&gt;
# Ⓜ It may happen that a UFO will be visually badly damaged, and all that you find is a couple of units of unconscious survivors and a lot of corpses, or all will be dead.&lt;br /&gt;
# It may happen that it will be impossible to recover the UFO and the aliens will scatter into the nearest buildings, the UFO will remain empty or there will be only a few spitters and multiworms.&lt;br /&gt;
# Ⓜ Arriving on a mission to crash UFOs in slums, we can meet a team of numerous marauders of gang members (who will take aliens in number and leave a lot of corpses) who have already joined the battle from criminal organizations wishing to get alien technology, they can already be outside UFOs and kill several aliens, or already inside the UFOs and kill all aliens and share the prey (Use the weapons of aliens). It&#039;s up to you to either kill them or fly away.&lt;br /&gt;
# Ⓜ 2 criminal gangs fighting among themselves or a police squad pursuing a criminal gang may also encounter. Gang members attack in groups of 8-20 - Osiron groups are the largest, Psyke groups are the smallest.&lt;br /&gt;
# Ⓜ If a UFO crashed near an important public building on a mission, you will find the Security Guard squad holding back the alien forces from spreading.&lt;br /&gt;
# Ⓜ Arriving on a mission, we can meet the members of the Cult of Sirius who flew in hoping to make contact and help the aliens. It&#039;s not for nothing that UFOpaedia says &amp;quot;This represents a significant threat to X-COM because the cultists will do anything to assist the Aliens in their purpose, whatever that might be.&amp;quot; Aliens will infect micronoids and supply the cultists with their weapons and will use them as cannon fodder. Cult members fight in groups of around 10.&lt;br /&gt;
# Ⓜ On a downed UFO, there may be sectoids for the rescue of which points will be awarded.&lt;br /&gt;
# Ⓜ On a downed UFO, there may be people captured from neighboring buildings for food and for the salvation of which points will be awarded.&lt;br /&gt;
# Ⓜ On the mission, there may simply be armed civilians belonging to some unregistered movements and not part of any corporations that are fighting against the total control of corporations (as private organizations, elevating a person over a person).&lt;br /&gt;
# Next to the crashed UFO may appear a mission where aliens from UFO storm the building and security reflects the attack.&lt;br /&gt;
# Around the crashed UFO can form dangerous abnormal zones (fire tornadoes, poison clouds, smoke, explosions) due to incorrect operation of the damaged ship.&lt;br /&gt;
# UFO casing can be home to small insect-like creatures (eg Skincrawlers  or Swarm) that mend the casing and can be dangerous to humans by eating or replacing flesh.&lt;br /&gt;
# Each crew of a UFO ship (types 3-7) can have 1-2 Micronoid Aggregate.&lt;br /&gt;
# Each UFO crew (types 3-7) can have 2-6 Micronoid Headwrappers or Micronoid Mentor.&lt;br /&gt;
# Micronoid Headwrappers or Micronoid Mentor are 1/6 Micronoid Aggregate which are located on the head of other aliens and can carry out psi control of both agents and their carriers.&lt;br /&gt;
# A combination of different types of the above changes.&lt;br /&gt;
&lt;br /&gt;
=Immersion in the game on missions=&lt;br /&gt;
or &#039;&#039;&#039;[MOD concept] Immersion: Missions&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
Immersion in the game will also help **quick pop up phrases** that agents or other characters will pronounce when they get into some kind of situation or interacting by clicking on the cursor as is done in fallout 2.&lt;br /&gt;
&lt;br /&gt;
[[File:OpenApoc_Concept_Spot.png|200px]] [[File:OpenApoc_Concept_Fog.png|200px]] [[File:OpenApoc_Concept_Battle.png|200px]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Quick Phrases&#039;&#039;&#039; - This mod will help the player plunge into the atmosphere of the game even more with the help of **additional effects and sounds**. &lt;br /&gt;
&lt;br /&gt;
The game has the disadvantage that agents are completely speechless like dolls. Immersion in the game will be helped by quick phrases that agents or other characters will utter when they get into a situation or interact by clicking with the cursor, for example, as done in Fallout 2.&lt;br /&gt;
&lt;br /&gt;
* The content and mood of the phrases may depend on the nature of the agent and its type (hybrid, human, android, alien), this requires a separate mod with the agent&#039;s biography ...&lt;br /&gt;
* &#039;&#039;&#039;Random phrases of civilians when agents are close&#039;&#039;&#039; about aliens, about X-Com, about the situation in the city, about personal problems, about politics, shouts, questions, complaints, regrets, ridicule (due to species, race, etc.), admiration at PM celebrities, show off or show off, offer trade exchanges at PM prohibited,&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;The formula for a random phrase can be, for example, this (depending on the situation):&#039;&#039;&#039;&lt;br /&gt;
&lt;br /&gt;
&amp;gt; &#039;&#039;&#039; Hold positions &#039;&#039;&#039;&lt;br /&gt;
&amp;gt; (White): Shout (Chance 0%) + Swear word (Chance 50%) + Phrase (Chance 50%) + Stating 75% + * minor action (сhance 50%)&lt;br /&gt;
&lt;br /&gt;
&amp;gt; &#039;&#039;&#039; Search &#039;&#039;&#039;&lt;br /&gt;
&amp;gt; (White): Shout (50% chance) + Swear word (50% chance) + Phrase (100% chance) + Stating 25% + * minor action (50% chance)&lt;br /&gt;
&lt;br /&gt;
&amp;gt; &#039;&#039;&#039; Combat and Spot &#039;&#039;&#039;&lt;br /&gt;
&amp;gt; (Red): Shout (75% Chance) + Swear word (100% Chance) + Phrase (50% Chance) + Statement 100% + * Minor Action (100% Chance)&lt;br /&gt;
&lt;br /&gt;
&amp;gt; &#039;&#039;&#039; Panic &#039;&#039;&#039;&lt;br /&gt;
&amp;gt; (Blue): Shout (100% chance) + Swear word (75% chance) + Phrase (75% chance) + Stating 0% + * minor action (100% chance)&lt;br /&gt;
&lt;br /&gt;
&amp;gt; &#039;&#039;&#039;Example of a phrase in battle:&#039;&#039;&#039; Aaahmm, + fuck, + I knew it, + I was wounded in my left arm + * presses the wound with my right hand&lt;br /&gt;
&lt;br /&gt;
# Quick phrase color can show mood and intonation of pronunciation:&lt;br /&gt;
## White neutral mood&lt;br /&gt;
## Green good mood&lt;br /&gt;
## Orange enemy detection, alarm&lt;br /&gt;
## Red fight with the enemy, aggression&lt;br /&gt;
## Blue fear, panic&lt;br /&gt;
## Purple phrases under psi control&lt;br /&gt;
# Shout (Shout, shout, shout, shout, shout, click, whoop, shout, shout, chuckle)&lt;br /&gt;
# Swearing (usually one word depending on the situation)&lt;br /&gt;
# Phrase (statement, opinion of a being about a situation)&lt;br /&gt;
# Statement / report (short statement of what happened)&lt;br /&gt;
# There can also be minor actions from a third person, separately or added to phrases like:(they can also be unique depending on the type of creature (hybrid, human, android))&lt;br /&gt;
## Spitting (if without a helmet)&lt;br /&gt;
## Scratching&lt;br /&gt;
## Correction of armor or item&lt;br /&gt;
## Recharge&lt;br /&gt;
## Interception of weapons by hand&lt;br /&gt;
## Head gazing&lt;br /&gt;
## Humming or whistling motive&lt;br /&gt;
## Anecdote&lt;br /&gt;
## Clever quote from authors or bible&lt;br /&gt;
## Funny phrase (these psimorphs were fucking howling)&lt;br /&gt;
## Wish (now would be a beer)&lt;br /&gt;
...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Triggers for phrases can be (some triggers can be executed with a 50% chance, others 75% and 100%):&#039;&#039;&#039;&lt;br /&gt;
# 100% chance:&lt;br /&gt;
## Alien detection (different random set of phrases for a specific type of alien)&lt;br /&gt;
## Detection of a hostile person (a different random set of phrases for a specific type of person and his organization)&lt;br /&gt;
## Killing an alien (a different random set of phrases for a specific type of alien)&lt;br /&gt;
## Wounding the agent (a different random set of phrases for a specific place of injury or who wounded him, a request for help or anger and threats)&lt;br /&gt;
## Murder of a civilian by an agent&lt;br /&gt;
## Killing a civilian by an alien&lt;br /&gt;
## Killing a civilian by a hostile person&lt;br /&gt;
## Killing a hostile person (different random set of phrases for a specific target)&lt;br /&gt;
## Phrases of hostile people after detection, injury, killing of agents (a different random set of phrases for a specific type of agent (hybrid, human, android, alien))&lt;br /&gt;
## The agent runs out of ammo&lt;br /&gt;
## Agent hitting the target and wounding (a different random set of phrases for a specific type of creature and its organization)&lt;br /&gt;
## Agent hitting target protected by energy shield. Chance 70%&lt;br /&gt;
## Agent hitting a smoke screen&lt;br /&gt;
## Agent hitting a paralyzing veil&lt;br /&gt;
## Agent hitting a burning zone&lt;br /&gt;
## Hitting the agent by an entropy projectile of aliens&lt;br /&gt;
## Poisoning an agent with something&lt;br /&gt;
# Chance 50%:&lt;br /&gt;
## Capture an agent under psi control (a different random set of phrases for a specific type of target)&lt;br /&gt;
## Capture an alien agent under psi control (a different random set of phrases for a specific type of target)&lt;br /&gt;
## Capture by an agent of a hostile person under psi control (a different random set of phrases for a specific type of person and his organization)&lt;br /&gt;
## An agent who came under the control of a brainsucker (micronoids having access to human knowledge can speak)&lt;br /&gt;
## Throwing grenades by agent&lt;br /&gt;
## Throwing a grenade by an enemy at an agent that falls within a radius around the agent&lt;br /&gt;
## Explosion of a grenade harming the agent&lt;br /&gt;
## Grenade explosion nearby when the explosion touched the agent but did not harm&lt;br /&gt;
## Fall of the agent from a height after the destruction of the floor&lt;br /&gt;
## The agent picking up the found item&lt;br /&gt;
## Agent whose panic has passed&lt;br /&gt;
## Agent panicked&lt;br /&gt;
## An agent who woke up after falling into unconsciousness&lt;br /&gt;
# 70% chance:&lt;br /&gt;
## Long running agent&lt;br /&gt;
## Long sitting in one place&lt;br /&gt;
## Long stay of the agent in a particular position&lt;br /&gt;
## Long stay of the agent in a particular fashion&lt;br /&gt;
## A hostile person who woke up after falling into unconsciousness&lt;br /&gt;
## Agent after taking off&lt;br /&gt;
## Hostile people don&#039;t use flying armor ??&lt;br /&gt;
## Hostile person after taking off&lt;br /&gt;
## Switch to no shoot mode&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
In the UFO crash mission (not only here but also on the city map), you can add meteorological and other phenomena taking into account the post-apocalyptic state of the earth’s atmosphere and to diversify the game:&lt;br /&gt;
&lt;br /&gt;
# Fog - will affect visibility and accuracy. Motion scanners come in handy here.&lt;br /&gt;
# Rain - affects the speed of movement and accuracy, the agent can also slip and fall. Adding rain sounds and sometimes thunder sounds.&lt;br /&gt;
# A strong wind, will have its overlay with an animated sprite, will greatly affect the accuracy of shooting. Add the sounds of the wind.&lt;br /&gt;
# Storm - rain and heavy rain, thunderstorm, lack of lighting and visibility due to heavy cloud cover. Adding sounds of rain, strong wind and thunder.&lt;br /&gt;
# Add sounds of a living city (sounds of cars, sirens, gunfights, and working factories).&lt;br /&gt;
# Add the occasional sounds of a damaged UFO similar to creature moans.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Additional weather conditions:&lt;br /&gt;
# Snow (falling or falling, or both) the accuracy increases if the snow does not fall. Add snow sounds for step&lt;br /&gt;
# Icing (frozen snow after warming) movement is very limited and the risk for the agent to fall.&lt;br /&gt;
# Large hail&lt;br /&gt;
# Solar radiation or storms.&lt;br /&gt;
# Emissions of radiation (local)&lt;br /&gt;
&lt;br /&gt;
Nothing plunges more into the game than the sight of suffering and pain. A fight is never so clean. Aliens and people should not always die immediately, and sometimes shoot back with reduced accuracy (and you will have to finish them off so that they do not shoot or shut up). The wounded can moan for a long time, bleed and move a little, people can scream and call for help or swear using quick phrases. Puddles of blood under them can be added to corpses and wounded. When a bullet enters the body, add a small effect of tearing and scattering of blood and pieces of meat and clothing...&lt;br /&gt;
&lt;br /&gt;
=Final game and Alien dimension=&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=Interesting extracts from the real history=&lt;br /&gt;
&lt;br /&gt;
* Brief extracts from the history of the world, theory and speculation may stir up the interest of the reader&lt;br /&gt;
** [[Background_ (Apocalypse) | The briefing page for Commander]] Tells us that Megaprime has long been doing something that is not clear and that our main task is to investigate this difficult situation and take action, including the activities of cults. [[X-COM_Timeline | The X-Com Timeline]] page and Phoenix Point history that I want to associate with Apoca [[https://www.youtube.com/watch?v=P4F_8zw0n1s PandoraVirus]] and [[https://phoenixpoint.info/stories/ Phoenix Point stories]] may help to look deeper into the situation in MegaPrime.&lt;br /&gt;
** From the story we learn that perhaps [[Cult of Sirius | The cult of Sirius]], [[Hypernews Network (Interceptor) #cultsiriusfound | founded in 2040]]., Has long been influenced by micronoids who were able to escape after the explosion of the city of T&#039;letch. Perhaps the Cult of Sirius is a project whose goal is to overcome the overtone window, the framework of the permissible spectrum of opinions about aliens in public statements from the point of view of public morality, perhaps using new techniques and technologies to influence the subconscious, (alien) technologies.&lt;br /&gt;
** The history also preserved information about a variety of other secret, hidden organizations (from ancient priests of Egypt to modern intelligence services), family clans (oligarchies of Egypt, Carthage, Rome, Venice, etc.), genetic lines of people who influenced humanity over the centuries and which are indirectly possibly associated with micronoids.&lt;br /&gt;
** According to some information, micronoids are capable of preserving the body of their carrier for thousands of years and it is not clear how much remains from a person in such a being, but not everyone can survive the transformation of their body. Just imagine that such a person can, take a place at the very top of the pyramid of human society, using the psionic capabilities of micronoids, directing and implementing your plans for thousands of years, relentlessly dictating your will to millions of people, without managing conflicts and financial sphere ...&lt;br /&gt;
** There is information that micronoids have mutagenic abilities, and perhaps those micronoids that remained on the earth after landing T&#039;letch, guided the evolution of the biosphere and terraformed the Earth’s atmosphere all this time ... No one knows what these organisms are capable of and what forms take under the influence of various conditions. maybe&lt;br /&gt;
** Perhaps after the activation of T&#039;letch, the awakened micronoids and micronoids on the earth, preserved for millions of years, united and their activity intensified ...&lt;br /&gt;
** Perhaps the city woke up cyclically, changing the face of the earth from time to time ... spreading various forms of life for thousands of years, doing hybridization and experiments, and then, perhaps, collecting the necessary information to improve and adjust their goals. technologies &amp;quot;nullified&amp;quot; the land in the next catastrophe. According to geological and archaeological data, the last known cataclysm was about 12-10 thousand years ago, which carried away a developed civilization, conventionally, the &amp;quot;Atlants&amp;quot;, sweeping away the remnants of humanity and ancient knowledge, but thousands and thousands of ruins from megalithic and cyclopean clutches, hundreds of pyramids and giant statues throughout the land as the brightest evidence and witnesses of those times.&lt;br /&gt;
*** [[http://www.egyptology.ru/antiq/platon-1.htm Ancient authors described]] those times, the Egyptian priest in a conversation with Solon: &amp;lt;i&amp;gt; &amp;quot;Ah, Solon, Solon! You, the Greeks , always remain children, and there is no elder among the Greeks! &amp;quot; &amp;quot;Why do you say that?&amp;quot; - Solon asked. “All of you are young with your mind,” he replied, “because your minds do not retain in themselves any tradition, which passed from family to family, and any teaching that has turned gray from time. The reason is the same. There have been and will be multiple and different cases of death of people and, moreover, the most terrible - because of fire and water, and others, less significant - because of thousands of other disasters.From here and the story you have about the Phaeton, son of Helios, who allegedly once harnessed his chariot, but he could not direct it along his father’s path, and therefore he burned everything on three mle, and he died, Incinerate Lightning &amp;quot;... So, you store memory only about one flood, and in fact there were many before; &amp;lt;/i&amp;gt;&lt;br /&gt;
*** In the Necronomicon, a semi-mythical book, other dimensions and various creatures that live there are mentioned. In addition, various creatures and races that inhabited the Earth in previous eras are described. The author of the book spent the decade of the Arabian desert Dahna. According to ancient Arabic belief, it is in Dahna that the entrance to the mysterious city of Irem is hidden, where the knowledge of the Ancients was kept. In addition, on the pages of the manuscript, you can find a detailed description of the process of enslavement of human souls and instructions for creating a psychotronic weapon.&lt;br /&gt;
*** The books are not included in the Bible and other sources said that all knowledge was transferred to people by gods or angels. The bible says: “Dead things are formed from under the waters, and the living equations” or “Rephaim tremble under the waters, and those who dwell in them” (Rephaim are giants later called dead, spirits) (Torah Job 26: 5, Job Chapter 26: 5). The Ethiopian Book of Enoch. The third section. XVI Thanks to the knowledge inherited from the guards, the rephaim gained tremendous power over nature: they were able to &amp;quot;cover the firmament, contributing to the reduction of rain&amp;quot; (Breshit slave, 26, 17; Sotah, 34b). They were also engaged in the fact that in the surviving fragments of the Giant Book they are called the calculus of the whole earth: &amp;quot;Let them number all [the earth ...], let them calculate with the help of various calculations&amp;quot; (Giant Book). &amp;quot;[they] were born on earth [and grew up, and matured, and began to devour] (works of hard) labor of all sons of men, and [people] were unable to [feed themselves. And the giants] planned to destroy people [and devour them. And they began to sin and ...] against all the birds and beasts of the earth, [and the reptiles crawling on the earth and animals) in the water] and in the heavens, and sea fishes, and devour each other&#039;s flesh and drink blood] &amp;quot; (translation of the Aramaic fragments of the Book of Enoch from Qumran. Fragment 4QЕna ar 1iii 1-23).&lt;br /&gt;
*** Rulers and gods enlighteners with reptiloid, amphibian features that brought all knowledge to people at the beginning of foreseeable times (perhaps representatives of the antediluvian races that were used by micronoids during the floods):&lt;br /&gt;
**** [https://ru.wikipedia.org/wiki/%D0%9E%D0%B0%D0%BD%D0%BD Oann] - The first of Abgallu who taught the Sumerians&lt;br /&gt;
**** [https://ru.wikipedia.org/wiki/%D0%94%D0%B0%D0%B3%D0%BE%D0%BD Dagon] - perhaps one of Abgallu, the god of the Philistines, after they were settled Canaan&lt;br /&gt;
**** [https://en.wikipedia.org/wiki/Me_(mythology) Me Mystical Power] and attribute of all the gods of Mesopotamia (perhaps there is a connection with Micronoids)&lt;br /&gt;
**** [https://ru.wikipedia.org/wiki/%D0%90%D0%B1%D0%B7%D1%83 Abzu] - the world&#039;s ocean of underground fresh water, gods and clay were conceived in it Abzu was created man, the divine &amp;quot;me&amp;quot; was kept there and the assistants of Enki sages Abgallu worked.&lt;br /&gt;
**** [https://ru.wikipedia.org/wiki/%D0%90%D0%B1%D0%B3%D0%B0%D0%BB%D0%BB%D1%83 Abgallu] - seven wise men -the helpers of the god of wisdom Enki, created by him, the founders of the seven first Sumerian cities, who taught people everything, they did not eat food, which every night went into the depths of the sea.&lt;br /&gt;
**** [https://ru.wikipedia.org/wiki/%D0%AD%D0%B0_(%D0%B1%D0%BE%D0%B3) Enki or Ea] - Son of Enlil, Deity of Wisdom, groundwater (fresh) and underground world, cultural inventions, the creator of the Tigris River; Had epithets &amp;quot;cunning, powerful, intelligent, Mind Extensive.&amp;quot; The name Enki means &amp;quot;Lord of the Earth&amp;quot;, &amp;quot;Lord of the Bottom&amp;quot;&lt;br /&gt;
**** [https://lah.ru/wp-content/uploads/2014/10/E-engura_v2_article.pdf E-engura - Enki submarine] Which was made of metal, made a roar, its walls could give advice , swam to Abzu, &amp;quot;was under a divine ME&amp;quot;, &amp;quot;In your heart, a high throne is erected, your door jamb is a sacred heavenly shutter.&amp;quot; E-Engure was the abode of the god Enki and his inner circle. Enki did not allow anyone into his abode, including other gods.&lt;br /&gt;
**** [https://ru.wikipedia.org/wiki/%D0%9E%D1%81%D0%B8%D1%80%D0%B8%D1%81 Osiris] - the god of Egypt who brought knowledge to people, with green skin or scales.&lt;br /&gt;
**** [https://ru.wikipedia.org/wiki/%D0%A4%D1%83_%D0%A1%D0%B8 Fu Xi] is the first emperor of China and his sister-wife who ruled from the depths of the sea .&lt;br /&gt;
**** Nagas of India - It is believed that the serpent-nag was a totem of one of the powerful ancient tribes, whose representatives were called Nagas. It is argued that the naga kept the truth secret until people were ripe for understanding.&lt;br /&gt;
**** [https://ru.wikipedia.org/wiki/%D0%9A%D0%B5%D0%BA%D1%80%D0%BE%D0%BF%D1%81_(%D1%D1%8B%D0%BD_%D0%93%D0%B5%D0%B8) Tsar Kekrops] is the founder and first king of Attica and Athens, while Phaeton was killed during his death and Devkalion deluge occurred.&lt;br /&gt;
**** The symbol of Jesus was a fish&lt;br /&gt;
**** [[:File:Vatican-mitre.png | The Pope wears]] to this day, Mithra (infula) and the soutane and very much resemble the Sumerian priests of the demigods Abgallu.&lt;br /&gt;
**** [https://en.wikipedia.org/wiki/Nommo Hero Nommo] from the Dogon tribe (Mali, Africa) who flew from Sirius on his ark in which he brought all the ways of being, he is now on the ground and is waiting for a certain time to appear.&lt;br /&gt;
**** [https://ru.wikipedia.org/wiki/%D0%9A%D0%B5%D1%82%D1%86%D0%B0%D0%BB%D1%8C%D0%BA%D0%BE%D0%B0%D1%82%D0%BB%D1%8C Quetzalcoatl] - one of the main gods of the Aztec pantheon and pantheons of other civilizations of Central America. According to legends, Quetzalcoatl rules in Tula for more than 20 years, after which it sailed to East. The great ruler taught the people mathematics, medicine, astronomy, writing, jewelry, weaving. Associated with his name, the introduction of the calendar with a cycle of 52 years, the invention of the canons of music and dance. His syncretic and pacifist doctrine of the &amp;quot;tolkokoyotly&amp;quot; provided for the prohibition of human sacrifice, which was not strictly accepted by the priestly tip.&lt;br /&gt;
**** [https://tar-s.livejournal.com/1007079.html The goddess Api from the Scythians] - the Goddess of fertility, is the same among the Greeks&lt;br /&gt;
** Perhaps they are all these years, centuries or millennia ?, infiltrated various organizations, corporations and governments and have a wide network of agents of influence and incredible access to resources and knowledge.&lt;br /&gt;
** Perhaps MegaPrime was their project, for themselves, perhaps it was they using earth technologies, and maybe gaining access to dormant ancient technologies, bases or satellites, associated with another dimension and are the reason why the Gate between Dimensions opened above MegaPrim. And no one can say for sure that the gate did not open ever in the past ..&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[OpenApoc]] &amp;amp;mdash; Main OpenApoc page&lt;br /&gt;
* [[Improvements (OpenApoc)]] &amp;amp;mdash; Currently implemented optional gameplay improvements&lt;br /&gt;
* [[Differences to X-COM (OpenApoc)]] &amp;amp;mdash; How OpenApoc differs from the original game&lt;br /&gt;
* [[Modding (OpenApoc)]] &amp;amp;mdash; Creating mods (some ideas from this page could be implemented as mods)&lt;br /&gt;
* [https://github.com/ayrtondenner/OpenApoc-wiki/blob/master/openapoc/roadmap.md OpenApoc Wiki: Development Roadmap] &amp;amp;mdash; Official development milestones and progress&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc OpenApoc on GitHub] &amp;amp;mdash; Source code and issue tracker&lt;br /&gt;
* [https://discord.gg/f8Rayre OpenApoc Discord] &amp;amp;mdash; Community discussion&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=Coding_Style_(OpenApoc)&amp;diff=126333</id>
		<title>Coding Style (OpenApoc)</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=Coding_Style_(OpenApoc)&amp;diff=126333"/>
		<updated>2026-03-01T21:01:43Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Major rewrite: updated to C++17/clang-format-18; added smart pointers; logging; strings; review expectations&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{DISPLAYTITLE:Coding Style (OpenApoc)}}&lt;br /&gt;
This document specifies the guidelines for writing and formatting the C++ code that forms the core of &#039;&#039;&#039;[[OpenApoc]]&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
OpenApoc uses &#039;&#039;&#039;C++17&#039;&#039;&#039;. This requires reasonably modern compilers (&#039;&#039;&#039;GCC 8+&#039;&#039;&#039;, &#039;&#039;&#039;MSVC 2019+&#039;&#039;&#039;, &#039;&#039;&#039;Clang 7+&#039;&#039;&#039; have been tested). You should avoid using compiler-specific extensions where possible. Exceptions exist, but should be wrapped in an &amp;lt;code&amp;gt;#ifdef&amp;lt;/code&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Code formatting is enforced by &#039;&#039;&#039;[https://clang.llvm.org/docs/ClangFormat.html clang-format]&#039;&#039;&#039; (version &#039;&#039;&#039;18&#039;&#039;&#039;). The configuration file &amp;lt;code&amp;gt;.clang-format&amp;lt;/code&amp;gt; in the root of the OpenApoc source repository defines the project style.&lt;br /&gt;
&lt;br /&gt;
Static analysis is enforced by &#039;&#039;&#039;[https://clang.llvm.org/extra/clang-tidy/ clang-tidy]&#039;&#039;&#039; (version &#039;&#039;&#039;18&#039;&#039;&#039;). The CI pipeline rejects unformatted code and code that fails tidy checks.&lt;br /&gt;
&lt;br /&gt;
It is highly recommended to run &amp;lt;code&amp;gt;clang-format&amp;lt;/code&amp;gt; on all modified files before committing:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;clang-format -i path/to/file.cpp path/to/file.h&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When run from the root of the OpenApoc source repository, it automatically uses the supplied &amp;lt;code&amp;gt;.clang-format&amp;lt;/code&amp;gt; configuration file.&lt;br /&gt;
&lt;br /&gt;
When using the CMake build system, there are dedicated targets:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
# Format all source files (from build directory)&lt;br /&gt;
cmake --build build -t format-sources&lt;br /&gt;
&lt;br /&gt;
# Run static analysis (from build directory)&lt;br /&gt;
cmake --build build -t tidy&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Indent ==&lt;br /&gt;
&lt;br /&gt;
* Tabs for indenting, spaces for alignment, indenting by 1 tab for each new scope&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
void function()&lt;br /&gt;
{&lt;br /&gt;
	reallyLongFunctionNameWithLotsOfArguments(argOne, argTwo,&lt;br /&gt;
	                                          argThree);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Avoid going over &#039;&#039;&#039;100 columns&#039;&#039;&#039; (at tab width of 4 spaces)&lt;br /&gt;
** If you find yourself going over this, it&#039;s often a hint to try to pull things out of loops / into functions&lt;br /&gt;
** Don&#039;t break strings up to fit this; it looks ugly and makes things harder to read&lt;br /&gt;
* If you have to break, indent the following line by an extra tab&lt;br /&gt;
** When breaking a single statement, break the line &#039;&#039;&#039;before&#039;&#039;&#039; the next operator. Avoid having an operator as the last thing on a line.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
void reallyLongFunctionNameIMeanThisIsReallyBadlyNamed(int parameterOne,&lt;br /&gt;
	int paramTwo, char theThirdOne)&lt;br /&gt;
{&lt;br /&gt;
	if (parameterOne == yetAnotherReallyLongCondition&lt;br /&gt;
		&amp;amp;&amp;amp; youHaveBetterThingsToDo)&lt;br /&gt;
	{&lt;br /&gt;
		doWhatever();&lt;br /&gt;
	}&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Whitespace ==&lt;br /&gt;
&lt;br /&gt;
* Spaces before and after operators&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	a = b;&lt;br /&gt;
	a &amp;amp;&amp;amp; b;&lt;br /&gt;
	a + b;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* Space after &amp;lt;code&amp;gt;if&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;while&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;else&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;for&amp;lt;/code&amp;gt;, space after &amp;lt;code&amp;gt;:&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;;&amp;lt;/code&amp;gt; in &amp;lt;code&amp;gt;for&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	for (auto &amp;amp;a : b)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* No spaces after function name (or function-like keywords like &amp;lt;code&amp;gt;sizeof&amp;lt;/code&amp;gt;), but space after flow control keywords, space after comma for multiple arguments&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	func(a, b);&lt;br /&gt;
	if (a == 0)&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* References and pointers: &amp;lt;code&amp;gt;&amp;amp;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;*&amp;lt;/code&amp;gt; align right (to the variable), not to the type&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	float *pointerToFloat;&lt;br /&gt;
	Type &amp;amp;ref;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Scope ==&lt;br /&gt;
&lt;br /&gt;
* Indent 1 tab for each new scope&lt;br /&gt;
* New scope is &#039;&#039;&#039;always&#039;&#039;&#039; surrounded by &amp;lt;code&amp;gt;{}&amp;lt;/code&amp;gt; braces, even for single-statement blocks&lt;br /&gt;
* Opening brace &amp;lt;code&amp;gt;{&amp;lt;/code&amp;gt; goes on the &#039;&#039;&#039;next&#039;&#039;&#039; line at the indent of the enclosing scope (&#039;&#039;&#039;Allman style&#039;&#039;&#039;)&lt;br /&gt;
* Closing brace &amp;lt;code&amp;gt;}&amp;lt;/code&amp;gt; at the same indent as the opening &amp;lt;code&amp;gt;{&amp;lt;/code&amp;gt;&lt;br /&gt;
* New scopes are caused by:&lt;br /&gt;
** Functions&lt;br /&gt;
** Conditional blocks (&amp;lt;code&amp;gt;if&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;else&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;while&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;for&amp;lt;/code&amp;gt;)&lt;br /&gt;
** &amp;lt;code&amp;gt;switch&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;case&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
void functionDefinition()&lt;br /&gt;
{&lt;br /&gt;
	newScopeHere();&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	if (x)&lt;br /&gt;
	{&lt;br /&gt;
		doWhatever();&lt;br /&gt;
	}&lt;br /&gt;
	else if (y)&lt;br /&gt;
	{&lt;br /&gt;
		doWhateverTheSecond();&lt;br /&gt;
	}&lt;br /&gt;
	else&lt;br /&gt;
	{&lt;br /&gt;
		doThatLastThing();&lt;br /&gt;
	}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;switch&amp;lt;/code&amp;gt; always has a &amp;lt;code&amp;gt;default&amp;lt;/code&amp;gt; case unless switching over an &amp;lt;code&amp;gt;enum class&amp;lt;/code&amp;gt; where every value is handled&lt;br /&gt;
* All &amp;lt;code&amp;gt;case&amp;lt;/code&amp;gt; sections should have a &amp;lt;code&amp;gt;break&amp;lt;/code&amp;gt;&lt;br /&gt;
* &amp;lt;code&amp;gt;case&amp;lt;/code&amp;gt; braces &amp;lt;code&amp;gt;{}&amp;lt;/code&amp;gt; are optional, based on whether new stack variables are needed&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
	switch (a)&lt;br /&gt;
	{&lt;br /&gt;
		case A:&lt;br /&gt;
			doSomething();&lt;br /&gt;
			break;&lt;br /&gt;
		case B:&lt;br /&gt;
		{&lt;br /&gt;
			auto newVariable = getSomething();&lt;br /&gt;
			useIt(newVariable);&lt;br /&gt;
			break;&lt;br /&gt;
		}&lt;br /&gt;
		default:&lt;br /&gt;
			break;&lt;br /&gt;
	}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Naming ==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Style !! Used For&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;CamelCase&amp;lt;/code&amp;gt; || Classes, enums, &amp;lt;code&amp;gt;enum class&amp;lt;/code&amp;gt; members, namespaces, template parameters&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;camelBack&amp;lt;/code&amp;gt; || Methods, member variables, function parameters, local variables&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;SHOUTY_CAPS&amp;lt;/code&amp;gt; || Constants, macros&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;lower_case&amp;lt;/code&amp;gt; || Labels&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== Types ==&lt;br /&gt;
&lt;br /&gt;
* Use &amp;lt;code&amp;gt;auto&amp;lt;/code&amp;gt; liberally, especially when the type is obvious from the right-hand side. Use &amp;lt;code&amp;gt;auto &amp;amp;&amp;lt;/code&amp;gt; to avoid copies.&lt;br /&gt;
* Use &amp;lt;code&amp;gt;enum class&amp;lt;/code&amp;gt; over plain &amp;lt;code&amp;gt;enum&amp;lt;/code&amp;gt;&lt;br /&gt;
* Use &amp;lt;code&amp;gt;struct&amp;lt;/code&amp;gt; only for data-only types; structs must &#039;&#039;&#039;never&#039;&#039;&#039; use access modifiers&lt;br /&gt;
* No C-style casts &amp;amp;mdash; use &amp;lt;code&amp;gt;static_cast&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;dynamic_cast&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;reinterpret_cast&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
* Prefer &amp;lt;code&amp;gt;{}&amp;lt;/code&amp;gt; brace initialization&lt;br /&gt;
&lt;br /&gt;
== Smart Pointers ==&lt;br /&gt;
&lt;br /&gt;
OpenApoc provides short aliases in &amp;lt;code&amp;gt;library/sp.h&amp;lt;/code&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
! Alias !! Equivalent&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;sp&amp;amp;lt;T&amp;amp;gt;&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;std::shared_ptr&amp;amp;lt;T&amp;amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;up&amp;amp;lt;T&amp;amp;gt;&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;std::unique_ptr&amp;amp;lt;T&amp;amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;wp&amp;amp;lt;T&amp;amp;gt;&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;std::weak_ptr&amp;amp;lt;T&amp;amp;gt;&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;mksp&amp;amp;lt;T&amp;amp;gt;(args...)&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;std::make_shared&amp;amp;lt;T&amp;amp;gt;(args...)&amp;lt;/code&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| &amp;lt;code&amp;gt;mkup&amp;amp;lt;T&amp;amp;gt;(args...)&amp;lt;/code&amp;gt; || &amp;lt;code&amp;gt;std::make_unique&amp;amp;lt;T&amp;amp;gt;(args...)&amp;lt;/code&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;No naked &amp;lt;code&amp;gt;new&amp;lt;/code&amp;gt;&#039;&#039;&#039; &amp;amp;mdash; always wrap in smart pointers immediately&lt;br /&gt;
* Prefer &amp;lt;code&amp;gt;up&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt; (exclusive ownership) over &amp;lt;code&amp;gt;sp&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt; unless shared ownership is genuinely needed&lt;br /&gt;
* Use &amp;lt;code&amp;gt;std::move()&amp;lt;/code&amp;gt; to transfer &amp;lt;code&amp;gt;up&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt; ownership&lt;br /&gt;
&lt;br /&gt;
== Templates ==&lt;br /&gt;
&lt;br /&gt;
* Template type parameters should use &amp;lt;code&amp;gt;CamelCase&amp;lt;/code&amp;gt;&lt;br /&gt;
* Place &amp;lt;code&amp;gt;template&amp;amp;lt;...&amp;amp;gt;&amp;lt;/code&amp;gt; on the line above the function/class declaration&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
template &amp;lt;typename ValueType&amp;gt;&lt;br /&gt;
ValueType doSomething(ValueType input)&lt;br /&gt;
{&lt;br /&gt;
	return input;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Class Declarations ==&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;public:&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;private:&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;protected:&amp;lt;/code&amp;gt; written at class indent level (not indented further)&lt;br /&gt;
* Always explicitly write &amp;lt;code&amp;gt;private:&amp;lt;/code&amp;gt;, even though it is the default&lt;br /&gt;
* &amp;lt;code&amp;gt;virtual&amp;lt;/code&amp;gt; only on the base class; &amp;lt;code&amp;gt;override&amp;lt;/code&amp;gt; on derived classes &amp;amp;mdash; never both together&lt;br /&gt;
* All classes with virtual methods must have a virtual destructor&lt;br /&gt;
* Use &amp;lt;code&amp;gt;= default&amp;lt;/code&amp;gt; instead of empty &amp;lt;code&amp;gt;{}&amp;lt;/code&amp;gt; constructor/destructor bodies&lt;br /&gt;
* Use member initializer lists; initializer order must match declaration order&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
class MyClass : public BaseClass&lt;br /&gt;
{&lt;br /&gt;
private:&lt;br /&gt;
	int memberVariable = 0;&lt;br /&gt;
	UString name;&lt;br /&gt;
public:&lt;br /&gt;
	MyClass() = default;&lt;br /&gt;
	~MyClass() override = default;&lt;br /&gt;
&lt;br /&gt;
	void doSomething() override;&lt;br /&gt;
	int getValue() const;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Functions ==&lt;br /&gt;
&lt;br /&gt;
* Functions should be named &amp;lt;code&amp;gt;camelBack&amp;lt;/code&amp;gt;&lt;br /&gt;
* Use &#039;&#039;&#039;early return&#039;&#039;&#039; &amp;amp;mdash; prefer separate &amp;lt;code&amp;gt;if (cond) return;&amp;lt;/code&amp;gt; checks over deeply nested conditionals&lt;br /&gt;
* &#039;&#039;&#039;&amp;lt;code&amp;gt;const&amp;lt;/code&amp;gt; aggressively&#039;&#039;&#039;: const member functions, const parameters, const return types, const local variables&lt;br /&gt;
* Range-for loops: &amp;lt;code&amp;gt;for (auto &amp;amp;element : container)&amp;lt;/code&amp;gt; / &amp;lt;code&amp;gt;for (const auto &amp;amp;element : container)&amp;lt;/code&amp;gt;&lt;br /&gt;
* Prefer &amp;lt;code&amp;gt;emplace()&amp;lt;/code&amp;gt; over &amp;lt;code&amp;gt;insert()&amp;lt;/code&amp;gt; in STL containers&lt;br /&gt;
&lt;br /&gt;
== General Code ==&lt;br /&gt;
&lt;br /&gt;
* Use anonymous namespaces instead of &amp;lt;code&amp;gt;static&amp;lt;/code&amp;gt; for file-local functions and classes&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
namespace&lt;br /&gt;
{&lt;br /&gt;
void helperFunction()&lt;br /&gt;
{&lt;br /&gt;
	// file-local helper&lt;br /&gt;
}&lt;br /&gt;
} // anonymous namespace&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* All project code lives in &amp;lt;code&amp;gt;namespace OpenApoc {}&amp;lt;/code&amp;gt;. Namespace content is &#039;&#039;&#039;not&#039;&#039;&#039; indented. Closing brace gets a comment:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
namespace OpenApoc&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
class MyClass&lt;br /&gt;
{&lt;br /&gt;
	// ...&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
} // namespace OpenApoc&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Logging ==&lt;br /&gt;
&lt;br /&gt;
Uses &#039;&#039;&#039;fmt-style format strings&#039;&#039;&#039; with positional &amp;lt;code&amp;gt;{0}&amp;lt;/code&amp;gt;, &amp;lt;code&amp;gt;{1}&amp;lt;/code&amp;gt; placeholders (&#039;&#039;&#039;not&#039;&#039;&#039; printf-style):&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#include &amp;quot;framework/logger.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
LogInfo(&amp;quot;Loaded mod \&amp;quot;{0}\&amp;quot;&amp;quot;, modName);&lt;br /&gt;
LogWarning(&amp;quot;Value {0} exceeds limit {1}&amp;quot;, value, limit);&lt;br /&gt;
LogError(&amp;quot;Failed to load file \&amp;quot;{0}\&amp;quot;&amp;quot;, path);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;code&amp;gt;LogInfo&amp;lt;/code&amp;gt; &amp;amp;mdash; general information&lt;br /&gt;
* &amp;lt;code&amp;gt;LogWarning&amp;lt;/code&amp;gt; &amp;amp;mdash; recoverable errors&lt;br /&gt;
* &amp;lt;code&amp;gt;LogError&amp;lt;/code&amp;gt; &amp;amp;mdash; fatal errors&lt;br /&gt;
&lt;br /&gt;
== Strings ==&lt;br /&gt;
&lt;br /&gt;
Use &#039;&#039;&#039;&amp;lt;code&amp;gt;UString&amp;lt;/code&amp;gt;&#039;&#039;&#039; (from &amp;lt;code&amp;gt;library/strings.h&amp;lt;/code&amp;gt;) for all strings. All &amp;lt;code&amp;gt;char*&amp;lt;/code&amp;gt;/&amp;lt;code&amp;gt;std::string&amp;lt;/code&amp;gt; values are assumed UTF-8.&lt;br /&gt;
&lt;br /&gt;
String formatting uses the &amp;lt;code&amp;gt;fmt&amp;lt;/code&amp;gt; library:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#include &amp;quot;library/strings_format.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
UString result = OpenApoc::format(&amp;quot;Player has {0} credits and {1} agents&amp;quot;, credits, agentCount);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Translation:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
UString translated = tr(&amp;quot;English text to translate&amp;quot;);&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Includes and Headers ==&lt;br /&gt;
&lt;br /&gt;
* Use &amp;lt;code&amp;gt;#pragma once&amp;lt;/code&amp;gt; (no traditional include guards)&lt;br /&gt;
* &#039;&#039;&#039;Include order&#039;&#039;&#039;: Local headers first, then system headers. Each block alphabetically sorted.&lt;br /&gt;
* Local headers use paths &#039;&#039;&#039;relative to the OpenApoc root&#039;&#039;&#039;: &amp;lt;code&amp;gt;&amp;quot;framework/logger.h&amp;quot;&amp;lt;/code&amp;gt;, not &amp;lt;code&amp;gt;&amp;quot;../logger.h&amp;quot;&amp;lt;/code&amp;gt; or &amp;lt;code&amp;gt;&amp;quot;logger.h&amp;quot;&amp;lt;/code&amp;gt;&lt;br /&gt;
* &#039;&#039;&#039;Prefer forward declarations&#039;&#039;&#039; over &amp;lt;code&amp;gt;#include&amp;lt;/code&amp;gt; in headers where possible&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#pragma once&lt;br /&gt;
&lt;br /&gt;
#include &amp;quot;library/sp.h&amp;quot;&lt;br /&gt;
#include &amp;quot;library/strings.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;vector&amp;gt;&lt;br /&gt;
&lt;br /&gt;
namespace OpenApoc&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
class ForwardDeclaredType;&lt;br /&gt;
&lt;br /&gt;
class MyClass&lt;br /&gt;
{&lt;br /&gt;
private:&lt;br /&gt;
	int member = 0;&lt;br /&gt;
public:&lt;br /&gt;
	void publicFunction();&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
} // namespace OpenApoc&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Key Review Expectations ==&lt;br /&gt;
&lt;br /&gt;
These patterns are consistently enforced during code review:&lt;br /&gt;
&lt;br /&gt;
# &#039;&#039;&#039;const correctness&#039;&#039;&#039; &amp;amp;mdash; if something can be &amp;lt;code&amp;gt;const&amp;lt;/code&amp;gt;, it must be &amp;lt;code&amp;gt;const&amp;lt;/code&amp;gt;&lt;br /&gt;
# &#039;&#039;&#039;Readable conditionals&#039;&#039;&#039; &amp;amp;mdash; avoid embedded comments in complex conditionals; prefer early-exit checks&lt;br /&gt;
# &#039;&#039;&#039;One logical change per PR&#039;&#039;&#039; &amp;amp;mdash; keep changes focused for clean history and bisectability&lt;br /&gt;
# &#039;&#039;&#039;Use &amp;lt;code&amp;gt;auto&amp;lt;/code&amp;gt;&#039;&#039;&#039; &amp;amp;mdash; when the type is already visible on the RHS&lt;br /&gt;
# &#039;&#039;&#039;Prefer exclusive ownership&#039;&#039;&#039; &amp;amp;mdash; use &amp;lt;code&amp;gt;up&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt; over &amp;lt;code&amp;gt;sp&amp;amp;lt;&amp;amp;gt;&amp;lt;/code&amp;gt; when shared ownership is not required&lt;br /&gt;
&lt;br /&gt;
== See Also ==&lt;br /&gt;
&lt;br /&gt;
* [[OpenApoc]] &amp;amp;mdash; Main OpenApoc page&lt;br /&gt;
* [[Compiling (OpenApoc)]] &amp;amp;mdash; Build instructions for developers&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc/blob/master/CODE_STYLE.md CODE_STYLE.md] &amp;amp;mdash; Full coding style specification in the repository&lt;br /&gt;
* [https://github.com/ayrtondenner/OpenApoc-wiki/blob/master/development/coding-style.md OpenApoc Wiki: Coding Style] &amp;amp;mdash; Extended coding style documentation&lt;br /&gt;
* [https://github.com/OpenApoc/OpenApoc OpenApoc on GitHub] &amp;amp;mdash; Source code repository&lt;br /&gt;
* [https://discord.gg/f8Rayre OpenApoc Discord] &amp;amp;mdash; Community discussion and support&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
	<entry>
		<id>https://temp.ufopaedia.org/index.php?title=User:Deldonut1&amp;diff=126332</id>
		<title>User:Deldonut1</title>
		<link rel="alternate" type="text/html" href="https://temp.ufopaedia.org/index.php?title=User:Deldonut1&amp;diff=126332"/>
		<updated>2026-03-01T20:29:18Z</updated>

		<summary type="html">&lt;p&gt;Deldonut1: Created page with &amp;quot;Hello! I&amp;#039;m &amp;#039;&amp;#039;&amp;#039;Ayrton Denner&amp;#039;&amp;#039;&amp;#039;, a contributor to &amp;#039;&amp;#039;&amp;#039;OpenApoc&amp;#039;&amp;#039;&amp;#039; and maintainer of the [https://github.com/ayrtondenner/OpenApoc-wiki OpenApoc Wiki].  == About ==  I&amp;#039;m a so...&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Hello! I&#039;m &#039;&#039;&#039;Ayrton Denner&#039;&#039;&#039;, a contributor to &#039;&#039;&#039;[[OpenApoc]]&#039;&#039;&#039; and maintainer of the [https://github.com/ayrtondenner/OpenApoc-wiki OpenApoc Wiki].&lt;br /&gt;
&lt;br /&gt;
== About ==&lt;br /&gt;
&lt;br /&gt;
I&#039;m a software developer, data scientist, AI/ML engineer, and X-COM fan. I contribute to OpenApoc through gameplay improvements, bug fixes, documentation, and community knowledge preservation.&lt;br /&gt;
&lt;br /&gt;
My main focus has been on building comprehensive documentation for the project &amp;amp;mdash; both developer-facing (architecture, coding style, build guides) and player-facing (game mechanics, features, comparisons with the original game).&lt;br /&gt;
&lt;br /&gt;
== OpenApoc Contributions ==&lt;br /&gt;
&lt;br /&gt;
* &#039;&#039;&#039;Gameplay improvements and bug fixes&#039;&#039;&#039; &amp;amp;mdash; Code contributions to the [https://github.com/OpenApoc/OpenApoc OpenApoc] project&lt;br /&gt;
* &#039;&#039;&#039;[https://github.com/ayrtondenner/OpenApoc-wiki OpenApoc Wiki]&#039;&#039;&#039; &amp;amp;mdash; 30+ pages covering original game mechanics, OpenApoc features, development guides, and comparison documentation. Maintained as a git submodule in the OpenApoc repository.&lt;br /&gt;
* &#039;&#039;&#039;UFOpaedia wiki updates&#039;&#039;&#039; &amp;amp;mdash; Updating and expanding the OpenApoc pages here on UFOpaedia&lt;br /&gt;
* &#039;&#039;&#039;Community research&#039;&#039;&#039; &amp;amp;mdash; Discord knowledge mining (77,000+ messages), reverse-engineering findings documentation, project status assessments&lt;br /&gt;
&lt;br /&gt;
== UFOpaedia Contributions ==&lt;br /&gt;
&lt;br /&gt;
Pages I&#039;ve created or significantly updated:&lt;br /&gt;
&lt;br /&gt;
* [[OpenApoc]] &amp;amp;mdash; Main project page&lt;br /&gt;
* [[Installing (OpenApoc)]] &amp;amp;mdash; Installation guide&lt;br /&gt;
* [[Compiling (OpenApoc)]] &amp;amp;mdash; Build instructions&lt;br /&gt;
* [[Controls (OpenApoc)]] &amp;amp;mdash; Controls reference&lt;br /&gt;
* [[Improvements (OpenApoc)]] &amp;amp;mdash; Gameplay improvements&lt;br /&gt;
* [[Differences to X-COM (OpenApoc)]] &amp;amp;mdash; Comparison with the original&lt;br /&gt;
* [[Hidden Features (OpenApoc)]] &amp;amp;mdash; Debug and cheat system&lt;br /&gt;
* [[Modding (OpenApoc)]] &amp;amp;mdash; Modding guide&lt;br /&gt;
* [[Coding Style (OpenApoc)]] &amp;amp;mdash; Code style guidelines&lt;br /&gt;
* [[Info (OpenApoc)]] &amp;amp;mdash; Project information&lt;br /&gt;
* [[Credits (OpenApoc)]] &amp;amp;mdash; Contributors list&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
* [https://github.com/ayrtondenner GitHub &amp;amp;mdash; ayrtondenner]&lt;br /&gt;
* [https://github.com/ayrtondenner/OpenApoc-wiki OpenApoc Wiki]&lt;br /&gt;
* [https://www.linkedin.com/in/ayrton-denner/ LinkedIn]&lt;br /&gt;
&lt;br /&gt;
[[Category:OpenApoc]]&lt;/div&gt;</summary>
		<author><name>Deldonut1</name></author>
	</entry>
</feed>