Plugin Setup - HeliosOrg/SimpleDataIntegration GitHub Wiki

Installation Notes

The instructions below are written for the pre-built binary of the plugin. If you want to build the plugin from source code you need to be running UE4 from source. Assuming you're doing that, clone https://github.com/HeliosOrg/SimpleDataIntegrationPlugin into the YOUR_PROJECT/Plugins directory (create the Plugins directory if it's not already there) and follow the instructions below.

1) Download and setup the plugin

  1. Download the pre-built binary of the plugin.

  2. Copy the Plugins folder into the folder titled with your project name which we will refer to as the YOUR_PROJECT directory from now on. If there already exists a Plugins folder, copy the SimpleDataIntegration directory into it. The final file tree should be as follows: YOUR_PROJECT/Plugins/SimpleDataIntegration.

  3. If your UE4 is a Blueprints-only project (i.e. you haven't added any C++ classes yet), you need to convert it to a C++ project. To do this, add an empty C++ class to your UE4 project by going to File > New C++ Class. It doesn't matter what the class is called and you can choose None as your parent class. This will automatically add a number of necessary files and folders to your project folder.

  4. We will now add the plugin to your dependencies which will tell UE4 that the plugin should be linked to your project. Open up the YOUR_PROJECT.Build.cs file located in YOUR_PROJECT/Source/YOUR_PROJECT. Inside this file, add "SimpleDataIntegration" to the following line: PrivateDependencyModuleNames.AddRange(new string[] { "SimpleDataIntegration" }); For example, if our project name was HeliosFinal, we would open HeliosFinal.Build.cs: HeliosFinal.Build.cs And in HeliosFinal.Build.cs, we would add "SimpleDataIntegration" as follows: Adding "SimpleDataIntegration"

  5. Now, we will turn on the plugin. Open DefaultEngine.ini in the project's Config folder and add +EnabledPlugins=SimpleDataIntegration to the [Plugins]. For example: default_engine

2) Setup the JSON file

The Simple Data Integration nodes in both the client (UE4) and the server are generated from an input.json file. Note that the input.json file should be the same on the client and the server.

  1. In the input.json file inside the SimpleDataIntegrationPlugin directory, specify the name (in upper camel case) and type (one of int, bool, FString, or float) of each variable you want to create a simple interface for in UE4. These names will correspond to both your server endpoints as well as the node headers in your Blueprints client.
  2. Add the URL of your own server to the start of input.json. For example, in the sample below, your server URL would replace http://ec2-54-100-240-19.us-west-1.compute.amazonaws.com/helios/.
  3. IMPORTANT Make sure the input.json file in UE4 is the exact same as the one on the server.
\\\ Sample input.json

{
  "server_url": "http://ec2-54-100-240-19.us-west-1.compute.amazonaws.com/helios/",
  "single_instance_variables": [
    {
      "name": "IsLightOn",
      "type":"bool" 
    },
    {
      "name": "NumKills",
      "type":"int"
    },
    {
      "name": "UserName",
      "type": "FString"
    },
    {
      "name": "WinPercentage",
      "type": "float"
    }
  ]
}

3) Use the plugin!

  1. Restart UE4.
  2. Check out the plugin usage article.