doc/unreal/en/install.md
Clone the repository:
git clone https://github.com/Tencent/puerts.git
Copy the Puerts directory from puerts/unreal to your project's Plugins directory.
Install an appropriate script backend following the guide below.
Enjoy the functionality of Puerts!
When it comes to selecting a JavaScript backend, its important to identify whats appropriate for your requirements.
Download V8:
Extract the downloaded V8 backend folder into YourProject/Plugins/Puerts/ThirdParty.
Change the UseV8Version setting in Puerts/Source/JsEnv/JsEnv.build.cs according to the version you downloaded.
Download NodeJS backend from the latest Unreal Engine release. Nodejs Download
Copy the "nodejs" folder from the downloaded release puerts_nodejs/Puerts/ThirdParty/nodejs_xx into the puerts inside of your project YourProject/Plugins/Puerts/ThirdParty.
Change the boolean UseNodeJs setting in Puerts/Source/JsEnv/JsEnv.build.cs to true.
Download QuickJS backend from the latest Unreal Engine release. QuickJS Download
Copy the "quickjs" folder from the downloaded release puerts_quickjs/Puerts/ThirdParty/quickjs into the puerts inside of your project YourProject/Plugins/Puerts/ThirdParty.
Change the boolean UseQuickJs setting in Puerts/Source/JsEnv/JsEnv.build.cs to true.
Navigate to the releases page and download the version that matches your UE version.
Extract the downloaded puerts folder into your project YourProject/Plugins/.
Enjoy the functionality of Puerts!
Note: The releases page also includes packages for Unity. Unreal Engine versions will start with "Unreal_vx.x.x".
Mac Users: If you encounter the "Move to Trash" issue, execute the following commands:
cd Plugins/Puerts/ThirdParty
find . -name "*.dylib" | xargs sudo xattr -r -d com.apple.quarantine
Blueprint-Only Projects: If you see the error "Plugin 'Puerts' failed to load because module 'JsEnv' could not be found,” it’s because pure Blueprint projects do not automatically compile plugins. Since Puerts includes C++ source code, you need to convert your Blueprint project to a C++ project by adding a C++ class. Alternatively, you can compile the UE engine with Puerts included during the compilation.
Once puerts has been successfully installed, it's time to set up a working TypeScript development environment.