Skip to content

Battle Pass System

The Battle Pass system is a popular monetization strategy in video games, especially in free-to-play online multiplayer games. It consists of a series of tiers with rewards that players can earn by completing specific challenges or tasks within the game.

Typically, there are two tracks in a Battle Pass: a free track and a premium track. The free track is available to all players and offers basic rewards, while the premium track offers more valuable and exclusive rewards but requires the player to purchase the Battle Pass with real money or in-game currency.

Players progress through the tiers of the Battle Pass by earning experience points (XP) or completing specific challenges. The more you play, the more rewards you unlock. Once the season ends, a new Battle Pass is released with a new set of rewards and challenges.

This system encourages continuous play and engagement with the game, as players are motivated to complete challenges and earn rewards before the season ends. It also provides a way for developers to monetize their game while offering value to the players.

Screenshot

In the example image above, you can see the two tracks of the Battle Pass. The top track is the premium track, which includes exclusive rewards such as skins, emotes, and in-game currency. The bottom track is the free track, which includes basic rewards such as experience points and consumable items. Players can progress through the tiers by earning experience points or completing challenges.

Passes

The Battle Pass template allows you to create multiple configs. You can provide different rules for each of the configs. The configs are called Documents in Balancy. One of the parameters in Battle Pass is Condition. We are going to use it to give different configs for players, depending on their level, but you can come up with any other segmentation.

Screenshot

Each document also has a parameter Points, where you can specify the content of the battle passes. There are multiple levels of reward available for players during their progress in the game. On each level there are Free and Premium

Section for programmers

using System.Collections.Generic;
using Balancy;
using Balancy.Models;
using Balancy.Models.SmartObjects.Conditions;
using Balancy.SmartObjects;
using UnityEngine;

public class BattlePassExample : IConditionsListener
{
    private List<BattlePass> _availableBattlePasses;
    private BattlePass _activeBattlePass;//TODO store this value in profile

    public BattlePassExample()
    {
        Init();
    }

    private void Init()
    {
        _availableBattlePasses = new List<BattlePass>();

        foreach (var battlePass in DataEditor.BattlePasses)
            LiveOps.General.ConditionSubscribe(battlePass.Condition, battlePass, this, _activeBattlePass == battlePass ? PassType.True : PassType.False);
    }

    public void Clear()
    {
        _availableBattlePasses.Clear();
        _availableBattlePasses = null;
        _activeBattlePass = null;
    }

    public void ConditionPassed(object data)
    {
        var bonus = data as BattlePass;
        _availableBattlePasses.Add(bonus);
        CheckPass();
    }

    public void ConditionFailed(object data)
    {
        var bonus = data as BattlePass;
        _availableBattlePasses.Remove(bonus);

        if (_activeBattlePass == bonus)
        {
            _activeBattlePass = null;
            CheckPass();
        }
    }

    private void CheckPass()
    {
        var bonus = _availableBattlePasses.Count > 0 ? _availableBattlePasses[0] : null;
        if (bonus != null && _activeBattlePass == null)
            _activeBattlePass = bonus;
    }

    public BattlePass GetActiveBattlePass()
    {
        return _activeBattlePass;
    }

    public void PrintActivePassInfo()
    {
        if (_activeBattlePass == null)
            Debug.LogError("No Battle Pass active");
        else
        {
            Debug.LogWarning($"==> {_activeBattlePass.Points.Length} Points");
            foreach (var point in _activeBattlePass.Points)
            {
                Debug.Log($"{point.Scores} : Free Reward = {point.FreeReward.Items.Length} ; Premium Reward = {point.PremiumReward.Items.Length}");
            }   
        }
    }
}

What's next

  1. Import the Template.
  2. Deploy the changes.
  3. Open the Unity project and generate the code.
  4. Add the files to your project, written above.
  5. Initialize Balancy.
  6. Add the following code in the callback.
var pass = new BattlePassExample();
pass.PrintActivePassInfo();