Get SpatialOS

Sites

Menu
You are viewing the docs for 11.0, an old version of SpatialOS. 12.0 is the newest →

The Unity SpatialOS window is currently experimental. We're very open to feedback - don't hesitate to get in touch on the forums if you have any thoughts.

The Unity SpatialOS window

The SpatialOS Unity window is an easy way to run spatial command-line tool commands from inside Unity. It also lets you manage aspects of SpatialOS projects.

Opening the SpatialOS window

To open the SpatialOS window:

  1. In the Unity editor, use the menu Window > SpatialOS.

    SpatialOS window

  2. At the top of the window are your project’s name and SpatialOS SDK version.

    • Click Build to open the Build tab.
    • Click Settings to open the Settings tab.
    • Click Support for quick links to the forums and documentation.

Building from the SpatialOS window

From the Build tab, you can run the following build tasks:

  • Generate code from your schema (and clean generated code)

    SpatialOS window: codegen

  • Build entity prefabs (and clean them)

    SpatialOS window: prefabs

  • Build worker code (and clean it)

    SpatialOS window: worker build

To choose which target you’re building for, use the drop-down menu and checkboxes at the top of the build tab:

SpatialOS window: choose target

For local deployments, select Development. For cloud deployments, select Deployment.

Similarly, select the checkbox for whichever worker code you’ve made changes to.

Interacting with deployments

From the Build tab, you can:

  • Run a local deployment. Click default_launch.json to change which launch configuration the deployment uses.

    SpatialOS window: run locally

  • Upload an assembly of this project (the full set of binaries for all your workers and their assets). Enter a name to use as a label for the assembly.

    SpatialOS window: upload an assembly

  • Connect a client to a running cloud deployment.

    For instructions on how to run a deployment, see the Deploying to the cloud page.

    SpatialOS window: connect worker

Settings

From the Settings tab, you can:

  • Under Spatial CLI location, set the location of the spatial CLI tool.

    On Windows: If the spatial CLI cannot be found, enter the path to spatial.exe here.

    On macOS: You’ll need to set the path to spatial from the Unity SpatialOS editor window:

    1. In the window, click Settings.
    2. In the Spatial location field, enter the path to where spatial is installed on your machine.

      If you used brew cask install spatial to install spatial, the path should be /usr/local/bin/spatial.

  • Update spatial to the latest version by clicking Update. We recommend doing this frequently.

SpatialOS Settings window

Was this page helpful?

Thanks for letting us know!

Thanks for your feedback

Need more help? Ask on the forums