Local Environment Setup
Legion Studios enforces a specific development environment setup to ensure consistency and ease of development across all addons. This document outlines the steps to set up your local environment for addon development.
Steps
Prerequisites
Before you begin, ensure you have the following installed:
Git (Version Control System) or some other Git client I.E (GitHub Desktop) or GitKraken
Arma 3 Tools (available on Steam)
Visual Studio Code or another code editor of your choice
Mikero's Tools (download the AIO)
Hemtt Install via
winget install BrettMayson.HEMTT
Setting Up the Repository
Setup P Drive (Windows Only)**:
Create a folder on your system where you want to store the Legion Studios addons, e.g.,
C:\ArmaWorkBench.Launch the Arma 3 Tools and set the P Drive to point to this folder.
Preferences -> Path to your P drive -> Set it to
C:\ArmaWorkBenchCheck Mount P Drive on startup if you want it to automatically mount when you start the Arma 3 Tools. This will create a popup whenever you start your machine to mount the P Drive.
Click "Mount P Drive" to mount it immediately. This will create a virtual drive (P:) that points to the folder you specified.
Ensure that the P Drive is mounted before proceeding with the next steps.
Mikeros P Drive Setup:
In Arma 3 Tools go to
External->Mikero's Tools.Click on
Arma3P.cmdIn the dialog that appears enter the following parameters:
"enter drive to extract to E..Z" -
P"full extraction including layers, dubbing, and missions (base addons only)? [Y/N]" -
N
Create a Legion Studios Folder: Inside your P Drive, create a folder named
lsto store all Legion Studios addons.mkdir P:\lsYou can do this using the command line or through your file explorer.
Clone the Repository: Open a terminal and run the following command to clone the Legion Studios repository into the
lsfolder:cd P:\lsgit clone https://github.com/Legion-Studios/Core.git coreThis will create a folder named
corein your current directory containing the Legion Studios addons.Submodules: If the repository contains submodules, initialize and update them by running the following command in the
coredirectory:cd core git submodule update --init --recursiveThis will only be applicable once the
translationssubmodule is added.
Open the Workspace in Visual Studio Code
In file explorer, navigate to the
P:\ls\coredirectory.Double click on the
LegionCore.code-workspacefile to open it in Visual Studio Code.When prompted, install the recommended extensions for the workspace. This is highly recommended.
Using HEMTT
To build the mod using HEMTT, follow these steps:
Open a terminal in the
P:\ls\coredirectory.Run the following command to build the mod:
hemtt buildIf you want to build a specific addon, you can specify it like this:
hemtt build --just <folder_name>
Last updated