Energy Modifiers

Overview #
Energy modifiers temporarily change the limits set by a game’s energy system. In Hiro, energy modifiers are part of reward definitions.
Energy systems assign a set amount of energy or stamina that players spend to unlock or play content. Games automatically refill energy over time according to predefined rules—for example, restoring one “Life” every 30 minutes. Energy modifiers let you adjust these refill rules.
Use cases #
- Infinite energy for a limited time — for example, giving players one hour of unlimited energy after a store purchase or achievement reward.
- Double the refill rate — for example, reducing the refill time from 30 minutes to 15 minutes.
- Increase max energy capacity — for example, Season Pass owners may have 8 lives instead of 5 for the duration of the season.
Configuration #
Energy modifiers are configured within reward definitions. Any system capable of granting rewards—such as Economy, Achievements, or Event Leaderboards—can grant an energy modifier.
| |
The following table lists all fields available in an energy modifier:
| Property | Type | Description |
|---|---|---|
id | string | The ID of the energy that should be modified. |
operator | string | The operation that will modify the energy. |
value | RewardRangeInt64 | The modifier value range. |
duration_sec | RewardRangeUInt64 | The duration range for the modifier (in seconds). |
To see how an “Energy Modifier” block can be used within a reward, please check Rewards.
Allowed operators #
| Operator | Description |
|---|---|
infinite | Provides unlimited energy for the duration defined in duration_sec |
set_refill_count | Replaces the default refill_count with the number provided in value. |
set_refill_sec | Replaces the default refill_time_sec with the duration in duration_sec. |
set_refill_max | Replaces the default max_count with the number in value. |
