Sub topic 3
Flow: matching challenge to skill
This chapter assumes you know the difference between intrinsic and extrinsic motivation and have a working idea of autonomy, competence and relatedness from the earlier chapters. You should also be comfortable with common game mechanics such as levels, difficulty settings and checkpoints. The code examples use simple Python.
What flow is
Flow is a mental state of full absorption in an activity. The psychologist Mihaly Csikszentmihalyi described it after studying people who lose track of time while climbing, playing chess, composing music or performing surgery. Players describe it in similar terms: "I looked up and three hours had passed."
Flow matters for game design because it explains a common pattern. The same game can feel thrilling to one player, boring to a second and stressful to a third. The game has not changed. What differs is the relationship between what the game asks of the player and what the player can do.
Flow is not a synonym for "fun". A player can enjoy a relaxed, low-intensity session without being in flow. It is a specific state with identifiable conditions, and designers can aim for it deliberately.
The conditions for flow
Csikszentmihalyi's work lists several conditions that tend to accompany flow. The ones most useful in games are these:
- Clear goals. The player knows what they are trying to do right now.
- Immediate feedback. The player can tell within moments whether an action worked.
- Challenge matched to skill. The task is hard enough to require full attention and not so hard that it feels impossible.
- A sense of control. The player feels their actions determine the outcome.
- Concentration on the task. Distractions fall away, including self-consciousness and awareness of time.
The third condition gets the most attention, and the rest of this chapter focuses on it. The other four are what make it workable in practice. A perfectly tuned challenge still fails if the player cannot tell what the goal is or cannot see whether their last action helped.
The challenge-skill model
The classic diagram of flow plots challenge on one axis and skill on the other. A diagonal band where the two are roughly equal is the flow channel. Above the band, challenge exceeds skill. Below it, skill exceeds challenge.
The two failure states have different signatures:
| State | Challenge vs skill | What the player feels | Typical behaviour |
|---|---|---|---|
| Anxiety | Challenge well above skill | Overwhelmed, frustrated | Repeated deaths, quitting, looking up guides |
| Flow | Roughly balanced | Absorbed, in control | Long sessions, steady improvement |
| Boredom | Skill well above challenge | Under-stimulated | Skipping content, idling, quitting |
Many versions of the diagram add more regions, such as arousal, worry, apathy, relaxation and control. These split the plane by whether challenge and skill are above or below the player's own average. The three-state version above is enough for most design discussion.
Flow is a moving target
The key property of the model is that skill grows. A level that produced flow at the start of the game produces boredom after the player has practised. If difficulty stays fixed, the player drifts out of the channel on the boredom side. If difficulty rises faster than skill grows, the player drifts out on the anxiety side.
So the design goal is a trajectory, not a single difficulty value. The challenge curve should rise roughly in step with the skill curve.
def flow_state(challenge, skill, tolerance=0.2):
"""Classify a moment of play from challenge and skill, both on a 0-1 scale.
tolerance is the half-width of the flow channel.
"""
gap = challenge - skill
if gap > tolerance:
return 'anxiety'
if gap < -tolerance:
return 'boredom'
return 'flow'
# A fixed-difficulty game: challenge stays at 0.4 while skill grows.
challenge = 0.4
for hour, skill in enumerate([0.2, 0.35, 0.5, 0.7, 0.9]):
print(hour, skill, flow_state(challenge, skill))
# 0 0.2 flow
# 1 0.35 flow
# 2 0.5 flow
# 3 0.7 boredom
# 4 0.9 boredomThe output shows the pattern. A game with fixed difficulty is in the flow channel only for a short window of the player's growth. The code is a teaching toy, since real challenge and skill cannot be measured on a clean 0-1 scale, but it captures the dynamics.
How games keep players in the channel
Designers use several techniques, and each has a cost.
Authored difficulty curves
The designer hand-builds a progression: tutorial, easy early levels, rising difficulty, occasional spikes for bosses, and rest periods afterwards. This gives the most control over pacing and mood. The cost is that the curve is tuned for an imagined average player. Players far from that average fall out of the channel.
Player-selected difficulty
Easy, normal and hard settings let players choose their own target. This supports autonomy, since the player decides how much challenge they want. The weakness is that players often choose badly. Some pick a level that is too hard out of pride, and some pick one that is too easy because they fear failing. Labels matter too. A setting called "Easy" can feel like an insult, and some games rename tiers to reduce that effect.
Dynamic difficulty adjustment
Dynamic difficulty adjustment (DDA) changes challenge during play based on observed performance. Examples include enemies that deal less damage after repeated deaths, or item drops that improve when a player is struggling.
def adjust_difficulty(difficulty, recent_results, step=0.05, low=0.0, high=1.0):
"""Nudge difficulty based on recent outcomes.
recent_results: list of booleans, True when the player succeeded.
Returns a new difficulty clamped to [low, high].
"""
if not recent_results:
return difficulty
success_rate = sum(recent_results) / len(recent_results)
if success_rate > 0.8:
difficulty += step
elif success_rate < 0.4:
difficulty -= step
return max(low, min(high, difficulty))
d = 0.5
d = adjust_difficulty(d, [True, True, True, True, True])
print(round(d, 2)) # 0.55
d = adjust_difficulty(d, [False, False, True, False, False])
print(round(d, 2)) # 0.5DDA has real edge cases:
- Detectable adjustment. If players notice the game helping them, the sense of accomplishment drops. Competence feels unearned.
- Exploitation. Players who learn the rule can fail on purpose to make the game easier. Some will then use that for a faster route to rewards.
- Noisy signals. A death may come from a hard encounter, a bug, a distraction or an experiment. Adjusting on a few deaths can misfire.
- Competitive fairness. In player-versus-player modes, silently adjusting difficulty for one side is usually unacceptable. Skill-based matchmaking serves the same goal there by adjusting the opponent instead of the rules.
Choice within the level
Some games offer several routes with different difficulty in the same space, such as optional side paths, optional bosses, or tools that make a challenge easier for those who find them. This lets different players find their own channel without any visible difficulty setting.
The role of feedback and goals
Challenge-skill balance is necessary but not enough. Two design failures break flow even when difficulty is well tuned.
- Unclear goals. The player does not know what to do next, so they cannot direct their attention. Typical causes are vague quest text and cluttered maps.
- Delayed or ambiguous feedback. A player attacks an enemy and cannot tell whether the attack landed. Without feedback the player cannot adjust their skill, which prevents the loop of try, observe and improve that flow depends on.
Interruptions also break flow. Long loading screens, frequent pop-ups, unskippable cutscenes and monetization prompts at the wrong moment all pull attention away from the task.
Flow and the other models
Flow connects to the models in this tutorial in several ways.
- Self-determination theory. Matching challenge to skill is how a game supports competence. Letting players choose difficulty or route supports autonomy. Flow is partly the felt experience of those needs being met.
- Player types. Different players want different positions in the channel. Achievers often seek hard challenges they can master, while players who prefer exploration or social play may want low-pressure challenge and will tolerate boredom longer if other motivations are served.
- Motivation profiles. A single player's target difficulty changes by context. The same person may want a demanding raid on Saturday and a relaxing farming session after work.
This last point is why a single global difficulty setting rarely works.
Limits of the flow model
Flow is a useful design lens, but it has limits you should know before relying on it.
- It is hard to measure. Flow is a subjective state. Surveys can ask about it after the fact, and telemetry can only infer it from behaviour such as session length and retry rate.
- It is not the only good state. Players also enjoy relaxation, narrative immersion, social chatting and deliberate mastery of something too hard. A game built only to maximize flow can feel narrow.
- Skill is multi-dimensional. A player may have strong reaction speed and weak strategic planning. One challenge dial cannot match both, so a game can feel too hard and too easy at once.
- Sustained flow is not the goal. Pacing needs peaks and rests. Constant maximum engagement is tiring, and rest periods make later challenges feel stronger.
Exercise
A game uses fixed difficulty. Playtest data shows new players quit in the first hour with many repeated deaths, while players with 40 hours of play report that fights feel pointless. Using the challenge-skill model, explain what is happening at each end and name two design techniques that would help both groups.
Show answer
New players are in the anxiety region, because challenge is well above their skill, which explains the repeated deaths and quitting. Veteran players are in the boredom region, because their skill has grown while challenge stayed fixed. Two techniques that help both groups are player-selected difficulty (each group picks a suitable setting) and an authored difficulty curve with rising challenge, or optional harder content for veterans combined with an easier early game. Dynamic difficulty adjustment would also work for single-player play, with the caveat that it should not be detectable or exploitable.
Exercise
In the adjust_difficulty function, a player deliberately loses five fights in a row to make the game easier, then plays normally. Name the problem this shows and one way to reduce it.
Show answer
The problem is exploitation of dynamic difficulty adjustment, because the function reacts only to recent failure and cannot tell failing by accident from failing on purpose. One mitigation is to adjust more slowly by using a longer window of results or a smaller step. Another is to cap the total reduction, or to adjust only when the failures are consistent with real struggle, such as repeated deaths at the same encounter.