Set Up the Unreal SDK #
Create a new project (optional) #
Confirm correct SDK generation type #
In your pragma-engine/platform/pragma-cli.ini file, ensure the sdk type is set to unreal:
company = mycompany
decrypter = passthrough
mvn_version_prefix = MNV_VERSION_PREFIX
project = myproject
project_dir_prefix = myproject
project_lib = myproject-lib
sdk = unreal
Set up PragmaSDK for Unreal #
Create a
Pluginsfolder in the root of your Unreal project.Copy the
update-pragma-sdk.shfile frompragma-engine/sdk/unreal4/to thePluginsfolder you just created.Modify the copied
update-pragma-sdk.shscript as follows:
Uncomment
SOURCE_ENGINE_RELATIVE_FOLDERand change the value to point to yourpragma-enginerepo.Uncomment
TARGET_PRAGMA_SDK_DIRand change the value toPragmaSDK. This creates a PragmaSDK folder under the current directory (Plugins).
- Run
update-pragma-sdk.shin Git Bash from the directory where you copied the script. Confirm that thePragmaSDKfolder now exists in yourPluginsdirectory.
Update PragmaSDK for Unreal #
Whenever you make changes to Pragma Engine or update the code, you’ll want to update the PragmaSDK Unreal plugin folder. Re-run the update script command from your Unreal Plugins directory:
update-pragma-sdk.sh
Configure the Pragma SDK #
From your Unreal project base folder, open
Source/[UNREAL_PROJECT]/[UNREAL_PROJECT].Build.csand addPragmaSDKandPragmaSDKAuxto thePublicDependencyModuleNamesarray:PublicDependencyModuleNames.AddRange(new string[] { ..., "PragmaSDK", "PragmaSDKAux" });From your Unreal project base folder, open
Config/DefaultGame.iniand add the following configuration information to the bottom. For example, this config points to the Player Game Backend.
[/Script/PragmaSDK.PragmaSdkConfig]
BackendAddress="http://127.0.0.1:10000"
GameClientVersion="DefaultGameClientVersion"
(Optional) Add the following to Config/DefaultEngine.ini to enable logs for every inbound and outbound RPC with payloads.
[Core.Log]
LogPragma=Verbose




