Get SpatialOS

Sites

Menu

The Example Project

1: Set up

To run the GDK and the Example Project, you need to:

  • Sign up for a SpatialOS account (or make sure you are logged in)
  • Clone the Example Project and GDK repositories
  • Build and launch the Example Project

Step 1: Sign up or log in

If you have not signed up for a SpatialOS account, you can do this here.
If you have already signed up, make sure you are logged into Improbable.io. If you are logged in, you should see your picture in the top right of this page; if you are not logged in, select Sign in at the top of this page and follow the instructions.

Step 2: Clone the Example Project repository

TIP: Clone the Example project into your root directory to avoid file path length errors. For example: C:\GitHub\UnrealGDKExampleProject.

Step 3: Clone the GDK

Next, you need to clone the GDK into your project. To do this:

  1. In File Explorer, navigate to the UnrealGDKExampleProject\Game directory and create a Plugins folder in this directory.
  2. In a terminal window, navigate to the UnrealGDKExampleProject\Game\Plugins directory and clone the GDK for Unreal repository by running either:
HTTPS git clone https://github.com/spatialos/UnrealGDK.git
SSH git clone git@github.com:spatialos/UnrealGDK.git

Step 4: Build the dependencies and launch the project

To use the Example project, you must build the GDK for Unreal module dependencies. To do this:

  1. Open File Explorer, navigate to the root directory of the GDK for Unreal repository (UnrealGDKExampleProject\Game\Plugins\UnrealGDK\...), and double-click Setup.bat. If you haven’t already signed into your SpatialOS account, the SpatialOS developer website may prompt you to sign in.
  2. In File Explorer, navigate to your UnrealGDKExampleProject\Game directory.
  3. Right-click on GDKShooter.uproject and select Switch Unreal Engine Version then select the Unreal Engine you cloned earlier.
    img
    Image: The Select Unreal Engine Version window

  4. Right-click GDKShooter.uproject and select Generate Visual Studio Project files.
  5. In the same directory, double-click GDKShooter.sln to open it with Visual Studio.
  6. In the Solution Explorer window, right-click on GDKShooter and select Build.
  7. When Visual Studio has finished building your project, right-click on GDKShooter and select Set as StartUp Project.
  8. Build and open your project in the Unreal Editor. To do this: Either press F5 on your keyboard or, in the Visual Studio toolbar, select Local Windows Debugger. Visual Studio toolbar
    Image: The Visual Studio toolbar
    Note: Ensure that your Visual Studio Solution Configuration is set to Development Editor.


    img
    Image: The Example Project in the Unreal Editor

> Next: 2: Launch a local deployment


——
2019-05-21 Page added with editorial review

Search results

Was this page helpful?

Thanks for letting us know!

Thanks for your feedback

Need more help? Ask on the forums