Get started

Note: The content on this page pertains to Game Server Hosting (Multiplay) available on the Unity Dashboard. If you’re using Game Server Hosting (Clanforge), see the Game Server Hosting (Clanforge) documentation.

This guide walks you through setting up Game Server Hosting as your project's game server orchestration platform. You’ll learn how to:

Note: See Guides if you’ve already set up Game Server Hosting and want to learn how to perform a specific task.

Prerequisites

Before you start, make sure you meet the following prerequisites:

Integrate your game server

The first step in the process of setting up Game Server Hosting is to integrate your game server executable. Game Server Hosting also refers to this executable as the build executable.

  1. Select your game engine
  2. Link your Unity project
  3. Install the Game Server Hosting package

Select your game engine

Select the game engine your game server executable supports. Game Server Hosting is engine-agnostic, meaning you can use Unity, Unreal, or a custom engine.

Select the engine, then select Next to continue.

Link a Unity project

Before you continue, you must link your project with the Unity Dashboard using the Unity Editor. Note: You can skip this step if you’ve already linked your project in the Unity Editor.

  1. Sign in to the Editor before linking the project to the Dashboard.
  2. Select File > Project Settings > Services.
  3. If you already have a Unity project, select Use an existing Unity project ID. To create a project from the Unity Editor, select your Organization, then Create project ID.

  4. Select Link project ID.

  5. You should see a message stating, “Project was linked successfully.”

Once you’ve linked your project in the Unity Editor, select Next in the Unity Dashboard.

Tip: See the Game Server SDK for Unity documentation to learn how to integrate your game with the Game Server SDK.

Link an Unreal project

Coming soon.

Link a custom project

Coming soon.

Install the Game Server Hosting package

Once you’ve linked your project to the Unity Dashboard, you can install the latest version of the Game Server Hosting package.

Use the Unity Package Manager to import the Game Server Hosting package in the Unity Editor:

  1. In Unity, navigate to Window > Package Manager.
  2. In the Package Manager, select the plus icon (+) with the down arrow next to it.
  3. Select Add package by name...
  4. Paste the following text snippet into the Name field, then select Add.

  5. Copy
    com.unity.services.multiplay
  6. After importing the Game Server Hosting package in the Unity Editor, select Finish in the Unity Dashboard.

Create a build

This guide walks you through creating your first build and supplements the embedded guide on the Unity Dashboard.

There are three ways to make a build:

Warning: Builds created with the direct file upload process does not support symbolic links. If you want to use symbolic links, you must use a Container build.
Warning: There’s a 4 GB limit per file uploaded directly through the Unity Dashboard interface. You can avoid this limit by using the Game Server Hosting API.

Fill in the build details

  1. Name the build.
  2. Select the operating system.
  3. Select the Upload method. You can upload the build files directly through the Unity Dashboard or add the build file files using a container image.
  4. Select Next.

Upload files

You can upload the build files directly through the Unity Dashboard or add the build files using a container image.

Note: If you’re using a Unity build, make sure you upload the *.so files, the *.x86_64 file, and the *_Data folder.

Upload directly through the Unity Dashboard

  1. Add the files required to run your game or application. The files should be in a loose, unzipped folder. At a minimum, the build files must contain an executable form of your gameClosedA build executable is the executable file within a build. or application.
  2. Select Upload Files.

  3. Once the files finish uploading, select Next.

Upload with a container

You can upload your build with a container by adding the container to the Game Server Hosting registry.

Add to registry

Follow the below instructions to add your pre-built container image to the Game Server Hosting registry.

  1. Log into the Game Server Hosting container registry.
  2. Push your container image to the Game Server Hosting registry.
  3. Select Next.
Select container image
  1. Choose the method you want to add the container to the Game Server Hosting registry. You can use the Unity Dashboard interface or the Game Server Hosting CLI.

  2. Find the container image by typing its name in the Container image field.
  3. Select Finish.

Create a release

Select Finish to create the first release automatically. Game Server Hosting can’t run a build on a server unless the build has at least one release.

You now have a new build. Before using the build, you need to create (and link) a build configurationClosedA build configuration manages how a build is run by dictating the query protocol, the application executable path, the application executable path, the configuration variables, and the launch parameters. and a fleetClosedA fleet is a collection of servers that host a game or application in specific regions. Accounts can have one or more fleets, each with its own regions, builds, build configurations, and settings..

Create a build configuration

Create a build configuration for the build you created in the previous step. See the Build configuration documentation to learn more.

  1. Define the usage settings:
    1. Select Custom.
    2. Set the CPU speed to value. The CPU speed defines the CPU frequency in megahertz (MHz).
    3. Set the Memory value. The memory defines the amount of RAM (random access memory) in megabytes (MB).
  2. Select Finish.

Set the build configuration details

The first steps are to name the build configuration, link it to a specific buildClosedA build contains the files necessary to run your game or application on a server., and define any additional details about the build configuratioClosedA build configuration manages how a build is run by dictating the query protocol, the application executable path, the application executable path, the configuration variables, and the launch parameters.n.

  1. Select Create a build configuration.
  2. Fill in the build configuration details.
    1. Name the build configuration.
    2. Select the build you created in the previous step.
    3. Select the build executableClosedA build executable is the executable file within a build..
    4. Select the Query type. Unity recommends using SQP as the query protocol.
    5. If you plan to use custom launch parameters, enable Custom launch parameters, then use the edit field to set the launch parameters.
  3. Select Next.

Define any configuration variables

The next step is to add configuration variables. Add each configuration variable you want to track in this build configuration, then select Next.

If you’re unsure or don’t want to track any additional parameters here, you can continue to the next step without making any changes.

Define the usage settings

Once you’ve set up all the configuration variables you want, it’s time to define the usage settings for this build configuration.

The usage settings defined in a build configuration tell Game Server Hosting how many resources each server has access to when running this build using this build configuration.

You can use the default recommended usage settings by leaving Default selected, then selecting Next.

If you know the resource requirements of your game serverClosedA server, also known as a game server, is an instance of a build executable running on a machine within a fleet., you can also specify custom usage settings. See Calculate usage settings to learn how to calculate usage settings.

To define custom usage settings:

  1. Select Custom.
  2. Set the CPU speed to value. CPU speed defines the CPU frequency in megahertz (MHz).
  3. Set the Memory value. Memory defines the amount of RAM (random access memory) in megabytes (MB).

  4. Select Finish.

You now have a new buildClosedA build contains the files necessary to run your game or application on a server. and build configurationClosedA build configuration manages how a build is run by dictating the query protocol, the application executable path, the application executable path, the configuration variables, and the launch parameters..

Create a fleet

This guide walks you through creating your first build and supplements the embedded guide on the Unity Dashboard.

  1. Define the fleet details.
  2. Define the fleet scaling settings.

Define the fleet details

The first step in creating a fleet is defining the fleet details, such as the name, the operating system, and the build configurationsClosedA build configuration manages how a build is run by dictating the query protocol, the application executable path, the application executable path, the configuration variables, and the launch parameters..

  1. Provide a name for the fleet.
  2. Select the operating system. Note: You cannot change the operating system later.
  3. Select the build configuration you created in the previous step. You can link more build configurations later.

  4. Select Next.

Define the fleet scaling settings

One of the most important considerations of a fleet is the scaling settings. The scaling settings of a fleet are composed of a Min available servers value and a Max servers value for each regionClosedA region is a geographical locations in which a fleet can host servers. Each fleet can have access to one or more regions and each region within a fleet has independent scaling settings. within the fleet.

  1. Add a region to the fleet. You can add as many regions as you need, each with distinct scaling settingsClosedScaling settings allow you to manage how your fleet scales per region. There are two scaling settings available per region: the minimum available servers and the maximum servers..
  2. Specify the Min available servers value for the region.
  3. Specify the Max servers value for the region.

  4. Select Finish.

You now have a fleetClosedA fleet is a collection of servers that host a game or application in specific regions. Accounts can have one or more fleets, each with its own regions, builds, build configurations, and settings., a build configurationClosedA build configuration manages how a build is run by dictating the query protocol, the application executable path, the application executable path, the configuration variables, and the launch parameters., and a buildClosedA build contains the files necessary to run your game or application on a server. configured and ready. To see the servers for this fleet, go to Game Server Hosting > Servers.

Create a test allocation

Create a test allocation to make sure everything’s working correctly. See the Test allocation documentation for help.

  1. Select Create a test allocation.
  2. Select the Fleet, the Region, and the Build configuration.
  3. Select Next.
  4. Select Run test.
  5. Wait for the test to complete.
  6. Select Finish.

Next steps

Congratulations! You’ve successfully set up Game Server Hosting. You can continue to the Game Server Hosting Dashboard to:

You can also configure other Unity services, such as Matchmaker, Analytics, or Cloud Code.