Toolbars
There are two toolbars you can use in the Unreal Editor: the main Unreal toolbar, and the SpatialOS GDK toolbar. Once enabled, the GDK toolbar sits alongside the main Unreal toolbar:
Definitions:
<ProjectRoot>
- The root folder of your Unreal project.
<GameRoot>
- The folder containing your project’s .uproject
and source folder (for example, <ProjectRoot>\ShooterGame\
).
Unreal toolbar
Alongside the standard functionality, we’ve added some extra capabilities to the Unreal toolbar under the Play drop-down menu to help with debugging your game:
- The Unreal<->SpatialOS networking switch
- The “Number of Servers” multiplayer option
- The “SpatialOS Settings” menu item which opens the SpatialOS settings
Switching between native Unreal networking and SpatialOS networking
To switch from using Unreal networking to using SpatialOS networking, open the Play drop-down menu and check two checkboxes:
- Run Dedicated Server
- Spatial Networking
These settings are valid for Editor and command-line builds. They’re stored in your project’s Unreal config file, <GameRoot>\Config\DefaultGame.ini
, under \Script\EngineSettings.GeneralProjectSettings
.
You can switch back by unchecking the boxes.
Warning: As the GDK is in alpha, switching back to Unreal default networking mode can be a useful way to debug and so speed up your development iteration. However, you lose access to the multiserver features of the GDK in Unreal default networking mode which may lead to erratic behavior.
Auto-generated launch config for PIE server-worker types
You can launch multiple servers at the same time from within the Unreal Editor in PIE (Unreal documentation) configuration. To configure the number of servers launched, open the Play drop-down menu and use the slider Number of Servers
within the Multiplayer Options
section.
If you want to connect multiple server-worker instances to SpatialOS, you need to tell SpatialOS how many instances to connect. You do this in the load balancing section of the launch configuration file (
This uses the rectangle_grid
strategy with 1 column and 1 row. To connect 2 servers, change this to 1 column and 2 rows (or vice-versa). Read more about the different kinds of load balancing strategies here.
SpatialOS GDK for Unreal toolbar
The GDK toolbar provides several functions required for building and launching your client and server-workers from inside the Unreal Editor.
Note: follow the Get Started guide to install the GDK toolbar.
Buttons
The GDK toolbar has five features mapped to individual buttons and is displayed in the main editor toolbar to the right of the Launch
button:
You can also access these from the Window menu:
Button | Description |
---|---|
Snapshot | Generates a SpatialOS snapshot. |
Schema | Creates schema for your Unreal project. |
Start | Runs spatial worker build build-config to build worker configs and runs spatial local launch with the launch configuration specified in the settings (see the SpatialOS Editor Settings documentation). |
Stop | Stops spatial local launch . |
Inspector | Opens the Inspector in a browser. |
Deploy | Opens the Cloud Deployment dialog box. |
Settings
Visit the SpatialOS Editor Settings panel page to learn more about the GDK toolbar’s settings.
————
2019-07-31 Page updated with limited editorial review
2019-06-27 Page updated with limited editorial review