Adding Plugin to a Unity Project
Learn how to add the GamePush plugin to your Unity project.
The latest version of the plugin can be downloaded under the link.
The plugin works on Unity versions 2020 and higher.
Open the Public Zone in the game you want:
In the Unity project, open:
Project Settings >
Resolution and Presentation
Select WebGL Template - GamePush and fill:
Project id and
Public Token of your project as on the screenshot:
If you want to show ads immediately when you open the game, then in the field:
Show Preloader Ad set
Open the GamePush folder and drop Prefab
GameScoreSDK into the project
Prefab can be dropped on the initial scene, the prefab will not be deleted when changing scenes
Rewarded ad example
// Add GamePush Library
public class AdsManager : MonoBehaviour
// Subscribe to the GP_Ads.OnRewardedReward event;
private void OnEnable()
GP_Ads.OnRewardedReward += OnRewarded;
private void OnDisable()
GP_Ads.OnRewardedReward -= OnRewarded;
// When calling the method, you can specify any text value
// For example: COINS or GEMS
private void ShowRewarded(string idOrTag)
// If you successfully view Reward ads
// you can give a reward by checking the specified value:
private void OnRewarded()
if (idOrTag == "COINS")
if (idOrTag == "GEMS")
To check if the ad is installed correctly:
In the Unity editor, stubs are substituted with the output of the necessary information in the Console. They look like this:
If errors appear in the Unity editor as:
These methods of the plugin are not stubbed, and to check all the functionality of the plugin, you need to create a Build game and check it on the right site or on the hosting.
The project uses WEBGL Template:
In the folder:
You can change the logo to your own, it will be displayed when loading.
The plugin inherits the hierarchy and naming convention from sdk, you can refer to the documentation for more information about methods work.
Repository link: https://gitlab.com/shagidullin/gamepush_unity
GamePush Community (Telegram): @gs_community
We wish you success!
Stay in Touch
For your suggestions
We Wish you Success!