Skip to main content

Adding Elympics to your game

info

Minimal supported Unity version is 2021.3.

Download the SDK and add it to your project

First, you need to download the Elympics SDK to your Unity Project. To do that, open Package Manager (in Window). Then press Add package from git URL, and download Elympics Unity SDK from this repository: https://github.com/Elympics/Unity-SDK.git

Download Elympics SDK

If all goes well and the project compiles, you should have some new items in the menu bar. ParrelSync and Tools (with Elympics hidden inside).

For Visual Studio users

For a better experience with Elympics SDK in Visual Studio (in-built method documentation), you should enable Git packages in Unity Preferences -> External Tools and then click Regenerate project files button.

Create the game

The next step is to configure a game in Elympics Cloud, so that we can connect our game instance to the cloud object and correctly synchronize it. To do that, login in Elympics web panel at https://console.elympics.ai/ by creating a new account, or using credentials provided. Create a new game, selecting an appropriate server fleet. We'll be using premium fleet in this tutorial.

info

Your game ID will be unique. Do not copy IDs from this tutorial, as they are only valid for specific accounts.

Panel game settings

Login to Elympics in Unity

Now it's time to create the config in your Unity game! Get back to unity and go to Tools -> Elympics -> Manage games in Elympics and log in with your Elympics credentials.

Unity log in

After a successful login you should be able to see more configuration:

Unity logged in

Press the Synchronize button in order to fetch your game configurations:

Unity syncrhonized

info

This is a game that you've previously created in the web panel! You should be able to see it in Unity!

Local game config

We've successfully fetched network config for the game. Now we can create a local game config, that your game instance will use in runtime. To do that press Create first game config! button.

Unity config new

A local game config has been created (those are assets inside your project now). Now just copy the game name and game id from the ones fetched from the network into the local settings. Also, select your gameplay scene. This will be the scene that Elympics will open when players are connected to the match. Also this is the scene that will be run on the game server instance.

Unity config done

Add Elympics to your scene

In order to use Elympics during gameplay, we need to add main Elympics object (prefab) to our gameplay scene. To do that, right-click in your scene hierarchy and select ElympicsSystem.

Elympics System

That's it! 🎉 You're all done with the game configuration!