Website/docs/md/tutorials/development-environment-setup.md
2023-03-02 21:09:33 -05:00

4.6 KiB

Requirements

:::warning Make sure to follow all the steps below before asking help. Carefully read everything. :::

1. Installing dependencies

1.1 Visual Studio 2019

  1. Download the Community edition of Visual Studio 2019.
  2. Run the installer, and install it with the .NET Desktop (C#) workload.

1.2 NodeJS

  1. Download the NodeJS v12.16.3 installer.
  2. Run the installer.
  3. Make sure to select Add to PATH.
  4. Deselect installation of chocolatey.
  5. Install.

For rest of the requirements install with the default settings.

2. Obtaining required files

  1. Create a folder and name it something like EFT-0.12.6.8026 (preferably somewhere on your fastest drive). This folder will be referenced to as the prep folder.
  2. Inside this folder, create a Client folder.
  3. Find your official game client install folder (by default, C:\Battlestate Games\EFT (live)\) and copy all of its contents into the Client folder from before.
  4. Remove the following unnecessary files from the Client folder:
    • BattleEye/
    • Logs/
    • ConsistencyInfo
    • EscapeFromTarkov_BE.exe
    • Uninstall.exe
    • UnityCrashHandler64.exe
    • WinPixEventRuntime.dll

2.2 Obtaining the server

Go with either steps, but take note that 2.2.1 will take a lot longer.

2.2.1 With git

  1. Open a PowerShell window inside the prep folder.
  2. Run git clone --depth 1 https://dev.offline-tarkov.com/sp-tarkov/Server.git (this will take a while).
  3. Verify that it has created a folder called Server.

2.2.2 As .zip

  1. Open https://dev.offline-tarkov.com/sp-tarkov/Server in your browser.
  2. Right above the file list, there should be buttons saying HTTPS/SSH, to the very right of that box will be a download icon. Click it and then download as ZIP.
  3. Extract the downloaded file and move the server folder inside the prep folder. Rename it to Server (capital S).

2.3 Obtaining the modules

Go with either steps.

2.3.1 With git

  1. Open a PowerShell window inside the prep folder.
  2. Run git clone --depth 1 https://dev.offline-tarkov.com/sp-tarkov/Modules.git.
  3. Verify that it has created a folder called Modules.

2.3.2 As .zip

  1. Open https://dev.offline-tarkov.com/sp-tarkov/Modules in your browser.
  2. Right above the file list, there should be buttons saying HTTPS/SSH, to the very right of that box will be a download icon. Click it and then download as ZIP.
  3. Extract the downloaded file and move the modules folder inside the prep folder. Rename it to Modules (capital M).

3. Building required files

3.1 Building the server

Go with either steps.

3.1.1 Through CLI

  1. Open a PowerShell window inside the Server\project\ folder (inside prep).
  2. Install the project dependencies using npm install.
  3. Build the project using npm run build.
  4. A file called SP-Tarkov-Server.exe should appear. This is the built server file.

3.1.2 Through Visual Studio Code/VSCodium

  1. Open the Server\project folder in Visual Studio Code/VSCodium.
  2. Install the project dependencies using Menu Bar => Terminal => Run Task... => npm => npm: install.
  3. Build the project using Menu Bar => Terminal => Run Build Task....
  4. A file called SP-Tarkov-Server.exe should appear. This is the built server file.

3.2 Building the modules

  1. Open the Modules\Modules.sln file with Visual Studio 2019.
  2. Build the solution using Menu Bar => Build => Rebuild Solution.
  3. Copy the contents of Modules\Build to your Client folder (from step 2.1), and OVERWRITE any files.

4. Finished

You have successfully built SP-Tarkov from source.

Run the server by running the SP-Tarkov-Server.exe file that should now be in your Server\project folder. Play SP-Tarkov by launching the SP-Tarkov-Launcher.exe file that should now be in your Client folder.

If you encounter an error, consult the FAQ before asking on the Guilded.

Thanks

Tutorial made by: Senko-San

Revisions

  1. added instructions for assembly-charp, slight wording change
  2. changed the instruction to reflect the new build procedure
  3. rewrote the tutorial to match latest changes

Guilded link: https://www.guilded.gg/senkospub