Content
Introduction
In this guide, you’ll learn…
What are Dynamic Races?
Configuring Dynamic Races
Bot Speed Calculations in Dynamic Races
Overview
Races are time-limited in-game mechanisms, where users compete against a configurable number of bot adversaries to complete targets.
Players receive rewards based on their final position in the race. While rewards are commonly given for finishing in the top three, there's no hardcoded limit and it's possible to configure rewards for additional positions as well. The race concludes when the player or bots finish, or when the event’s time limit expires.
The event has a defined start and end date. There is a possibility of re-running the races multiple times, one at a time. Hawk provides possibility to configure single stage race, or multi-stage race where player can progress across different stages.
Dynamic Races introduce a new way to configure races based on player speed attributes. Instead of using fixed values, admins can define formulas that adapt to player performance, making races more dynamic and personalised.
As with other activity types, activity sticks to the player from the moment the player is assigned there. However, for races Hawk doesn’t stick the activity to the player. It means that if the player changes segment during an ongoing event, Hawk will start to serve race configuration associated with their new segment.
Dynamic Races Highlights
A single formula-based configuration adapts speeds dynamically.
Admins only need to define a base speed formula for both players and bots.
No need to create multiple static configurations.
Personalisation for Players
Dynamic Races allow real-time difficulty adjustments based on a player’s individual performance.
Instead of using static speed values , races can now adapt using player attributes like:
avg_win_time_20_lvl (average time taken by a player to win a single level , based on the last 20 levels).
This ensures that races are:
Reducing Manual Configuration Effort
Before Dynamic Races, product teams needed to manually create multiple predefined difficulty levels:
Very Slow
Slow
Medium
Fast
Very Fast
Each segment required separate race configurations with different speed values.
Making Bots More Realistic
Static bots follow predictable speed patterns, making races repetitive.
With Dynamic Races, bots get:
Varying speeds per target (controlled randomness).
Adaptive difficulty scaling based on real player data.
Example:
If a player improves over time, bots automatically get hard with each race.
If a player struggles, bots slow down, making races feel fair.
Configuring Dynamic Races
To configure Races, follow the steps below:
In your game, navigate to Events < Races , and click [+ Add Race].
Add a name for your race and select the availability.
Then, input the Player Speed Reference, which represents the average time (in seconds) for a player to complete a level. This reference is used to calculate bot speeds only when the client is responsible for determining bot speeds.
Under Target , input the number of targets the player needs to reach to finish the race.
Your target can vary, for example: from completing levels to collecting tiles. In most races, the target is defined as the number of levels a player needs to win to complete the race.
![]()
Race Template – Allows selecting a predefined race template. Selecting a race template will lead to populating the parameters for the race. See the Activity Templates User Guide for more details.
![]()
Bot Configuration
Bot Speed Reference:
Bot Speed Reference Fallback:
Minimum & Maximum Range (Percentage):
Important: None of these fields can be empty when saving the race.
![]()
You can add as many bots as needed.
Reward Configuration
To create the rewards for players who finish the Event, click [+Add Rank], and select a game item to provide as a reward.
You can add more than one reward, and you can also create more than one Rank. Rank represents rewards for different positions in the race. You can change the rank with arrows on the side.
![]()
Bot Speed Calculations in Dynamic Races
The server calculates bot speeds dynamically based on Bot Speed Reference and Min/Max Range percentages.
These calculations ensure that bot difficulty is adjusted per race while maintaining overall fairness.
Formula for Bot Speed Calculation
For each bot in a race, the server follows these steps:
Determine Total Bot Speed
Determine Speed per Target
Example Calculation
Scenario
Bot Speed Reference = 10 Seconds
Total Targets = 3
Min Range = -20%
Max Range = +30%
Step 1: Calculate Total Bot Speed
Total Bot Speed = 10×3 = 30 seconds
Step 2: Random Speed Adjustments Per Target
The server picks random values within the range (-20% to +30%).
Example random values:
Step 3: Compute Adjusted Speed for Each Target
Speed for Target 1 = 10×(1+0.15) = 11.5 sec
Speed for Target 2= 10×(1−0.10)= 9 sec
Speed for Target 3=1 0×(1+0.05)=10.5 sec
Step 4: Validate Total Bot Speed
11.5+9+10.5 = 30 sec (Total Bot Speed is maintained)
Thus, the bot speed per target is dynamically adjusted while keeping the total race time unchanged.
Key Takeaways
Bot speeds fluctuate per target to create variability in difficulty.
Bot speeds are recalculated with each request to ensure balance. However, once a race starts, the client fixes the received bot speeds until the race ends, ensuring consistency for that race.
The percentage range provides randomness, preventing predictable bot behaviour.
Selecting Dynamic Races as an Activity
Users can select the activity type: "Dynamic Races" while configuring an event.
Once selected, an Activity Configuration dropdown allows choosing from the configured dynamic races.
Chunks 1
# Introduction
In this guide, you’ll learn…
- What are Dynamic Races?
- Configuring Dynamic Races
- Bot Speed Calculations in Dynamic Races
# Overview
Races are time-limited in-game mechanisms, where users compete against a configurable number of bot adversaries to complete targets.
Players receive rewards based on their final position in the race. While rewards are commonly given for finishing in the top three, there's no hardcoded limit and it's possible to configure rewards for additional positions as well. The race concludes when the player or bots finish, or when the event’s time limit expires.
The event has a defined start and end date. There is a possibility of re-running the races multiple times, one at a time. Hawk provides possibility to configure single stage race, or multi-stage race where player can progress across different stages.
Dynamic Races introduce a new way to configure races based on player speed attributes. Instead of using fixed values, admins can define formulas that adapt to player performance, making races more dynamic and personalised.
As with other activity types, activity sticks to the player from the moment the player is assigned there. However, for races Hawk doesn’t stick the activity to the player. It means that if the player changes segment during an ongoing event, Hawk will start to serve race configuration associated with their new segment.
## **Dynamic Races Highlights**
- A single formula-based configuration adapts speeds dynamically.
- Admins only need to define a **base speed formula** for both players and bots.
- No need to create multiple static configurations.
### **Personalisation for Players**
Dynamic Races allow **real-time difficulty adjustments** based on a player’s individual performance.
Instead of using **static speed values** , races can now adapt using **player attributes** like:
- **avg\_win\_time\_20\_lvl** (average time taken by a player to win a single level , based on the last 20 levels).
- This ensures that races are:
### **Reducing Manual Configuration Effort**
Before Dynamic Races, product teams needed to manually create multiple predefined difficulty levels:
- Very Slow
- Slow
- Medium
- Fast
- Very Fast
Each segment required separate race configurations with different speed values.
### **Making Bots More Realistic**
Static bots follow predictable speed patterns, making races repetitive.
With Dynamic Races, bots get:
- Varying speeds per target (controlled randomness).
- Adaptive difficulty scaling based on real player data.
Example:
- If a player improves over time, bots automatically get hard with each race.
- If a player struggles, bots slow down, making races feel fair.
## Configuring Dynamic Races
To configure Races, follow the steps below:
1. In your game, navigate to **Events \< Races** , and click **[+ Add Race]**.
2. Add a name for your race and select the availability.
3. Then, input the Player Speed Reference, which represents the average time (in seconds) for a player to complete a level. This reference is used to calculate bot speeds **only when the client is responsible for determining bot speeds**.
4. Under **Target** , input the number of targets the player needs to reach to finish the race.
Your target can vary, for example: from completing levels to collecting tiles. In most races, the target is defined as the number of levels a player needs to win to complete the race.

**Race Template** – Allows selecting a predefined race template. Selecting a race template will lead to populating the parameters for the race. See the [Activity Templates](/wiki/spaces/KB/pages/4124409886/Parameters+and+Activity+Templates#Activity-Templates) User Guide for more details.

### **Bot Configuration**
- **Bot Speed Reference:**
- **Bot Speed Reference Fallback:**
- **Minimum & Maximum Range (Percentage):**
Important: None of these fields can be empty when saving the race.

You can add as many bots as needed.
### **Reward Configuration**
To create the rewards for players who finish the Event, click **[+Add Rank]**, and select a game item to provide as a reward.
You can add more than one reward, and you can also create more than one Rank. Rank represents rewards for different positions in the race. You can change the rank with arrows on the side.

## **Bot Speed Calculations in Dynamic Races**
The server calculates bot speeds dynamically based on Bot Speed Reference and Min/Max Range percentages.
These calculations ensure that bot difficulty is adjusted per race while maintaining overall fairness.
### **Formula for Bot Speed Calculation**
For each bot in a race, the server follows these steps:
1. Determine Total Bot Speed
2. Determine Speed per Target
### **Example Calculation**
**Scenario**
- **Bot Speed Reference** = 10 Seconds
- **Total Targets** = 3
- **Min Range** = -20%
- **Max Range** = +30%
**Step 1: Calculate Total Bot Speed**
Total Bot Speed = 10×3 = 30 seconds
**Step 2: Random Speed Adjustments Per Target**
- The server picks random values **within the range (-20% to +30%)**.
- Example random values:
**Step 3: Compute Adjusted Speed for Each Target**
- Speed for Target 1 = 10×(1+0.15) = 11.5 sec
- Speed for Target 2= 10×(1−0.10)= 9 sec
- Speed for Target 3=1 0×(1+0.05)=10.5 sec
**Step 4: Validate Total Bot Speed**
11.5+9+10.5 = 30 sec (Total Bot Speed is maintained)
Thus, the bot speed per target is dynamically adjusted while keeping the total race time unchanged.
### **Key Takeaways**
- Bot speeds fluctuate per target to create variability in difficulty.
- Bot speeds are recalculated with each request to ensure balance. However, once a race starts, the client fixes the received bot speeds until the race ends, ensuring consistency for that race.
- The percentage range provides randomness, preventing predictable bot behaviour.
* * *
## **Selecting Dynamic Races as an Activity**
- Users can select the activity type: **"Dynamic Races"** while configuring an event.
- Once selected, an **Activity Configuration** dropdown allows choosing from the configured dynamic races.
* * *