Nine use cases for Unity’s Game Backend tools
Breaking down game backend
Building a backend to support your game systems isn’t easy, and you may not be able to build, host, and scale your own servers.
With Unity’s Game Backend suite, you can focus on creating content while we handle the heavy lifting.
Nine use cases for Unity’s Game Backend tools
Find out below what Unity’s Cloud Code, Cloud Save, Economy, and Authentication can do for you.
The simplest way to build timed elements in a game is to use device time. While that’s viable, unreliable device times can pose a challenge considering some players may use device time to cheat.
For example, players could manipulate the time on their device in order to expand the window during which they can access limited-time items.
Cloud Code allows you to write stateless server-side code and can offer a trusted, centralized "server” time that you can use when writing game logic.
Designing a rich system of in-game rewards can keep players engaged for a long time. Using Cloud Code, you can write scripts that can validate coupon codes and reward items in your game.
Plus, you can alter coupon logic even when the game is live without requiring a new game client update. Publishing changes on the server is enough to enforce new coupon redemption rules in the client.
You can use Cloud Save to track whether a player has redeemed their coupon and, once you’ve set up Economy, you can gift resources like in-game currencies or items.
Daily rewards can be an effective way to keep players coming back while letting them earn a variety of in-game items, especially in mobile games.
Since Cloud Code can be integrated with other Unity services, it’s a great tool for building the logic around daily rewards. You can define items and currencies in Economy, probabilities in Remote Config, and write the underlying algorithm in Cloud Code.
This allows you to alter the logic of daily rewards on the fly, without needing to update the game client.
Players expect to have all their in-game achievements and purchases to be preserved, no matter what. Their progress should not only be intact, but tied uniquely to them and consistent across all the devices they use to play.
By combining Cloud Save, Economy, and Remote Config with Authentication, you can save a player’s progress automatically and link it to their account.
When you use Authentication, you can set up sign-ins with platform accounts so the same player can sign in from Google, Facebook, Apple, or Steam and continue playing from wherever they left off from any device.
Once you’ve designed your in-game economy, you need to make sure you set up safeguards for it. Some ill-intentioned players may try to impersonate others in order to reap their in-game rewards or in-app purchases.
Economy works with Authentication and allows you to identify each player using unique tokens and IDs which can’t be manipulated by cheaters. This way, you’ll know which player has logged in and what their current inventory of currencies and items is.
Adding Cloud Code can make this process server authoritative, which adds another layer of protection to your in-game economy.
Rolling out live updates, bug fixes and improvements to your game often come with a difficult release process.
By moving in-game logic away from the game client by using Cloud Code, you can make changes for all of your players instantly. If you isolate your game logic away from the client device, you could update the game logic without requiring the player to update their installed version.
Using many online services for a mobile game means sending data via the internet multiple times. This can cause a jarring experience if a player’s connection is slow.
Normally, when you make changes to services like Economy or Cloud Save, you would read data from the server and decide what happens on the device. The resulting data would then have to be sent back to the server.
With Cloud Code, there is only one round-trip of information and the changes are implemented directly on the server. This creates a smoother experience for all players, no matter the speed of their internet connection.
If you’re using the Unity engine to develop a multiplayer game, you can take advantage of tools that are integrated in the editor in order to build and test your game securely, as well as maintain a consistent tech stack.
You can use Unity’s Relay service with Authentication to authenticate players connected on Relay in one of two ways: Anonymous sign-in or platform-specific sign-in.
These tools allow you to build, test, and operate your multiplayer game without needing a third-party solution or a dedicated game server.
When developing multiplayer games, you have to consider how your game’s features will encourage people to connect and play together.
Having a good understanding of which players to group into specific lobbies, parties, or matches can greatly impact players’ experiences.
By combining Unity’s Lobby and Matchmaker services with Authentication, you can group specific types of players and allow them to anonymously authenticate, connect, communicate, and play together.
These tools are flexible enough to support an array of game types, and scalable enough to support an influx of players in your game.
Our collection of samples shows you how to combine various Unity Gaming Services to solve common game development challenges, like creating loot boxes, starter packs, seasonal events, and more.