Uncertainty in Games: Why Tic-tac-toe is -Almost- Perfect

I solved tic-tac-toe a second time. The new secret I found: it’s not a bad game. It’s near perfect. Tic-tac-toe is elegant, designed around a simple core mechanic, intuitive to learn and play, has a consistent and short play time, and surprisingly every move matters. The issue is we all know how it will end. But that’s about it. There’s a lot we can learn from it about certainty, and the nature of solving games in general.

We all know how to play this game optimally and read its inevitable outcome early on. This certainty is its fatal flaw, but its other components are surprisingly sound. Did you realize that even an optimally played match of Tic-tac-toe’s outcome is not technically certain until the last turn ?

It’s true. Check out this diagram.

ttt blog

Note that until the last frame there are always at least 2 moves the next player could make that could affect who wins. This is true through turn 8 of 9. For a supposedly deterministic game that’s pretty good!

Since there’s no choice of plays on turn 9 of 9, literally every choice in tic-tac-toe has the potential to affect the outcome.

But we know from the first move that it will end in a tie. How do we know that? Well X played centre, which we understand is the optimal opener. Why does that mean a tie? Because we know O will optimally play to a corner in response, X will optimally play to a corner not opposite O, and so on. We only know the outcome because we know that both players know the optimal play pattern.

We’re evaluating a game based on literally flawless play by both participants. That’s not a fair metric. From Michael Jordan to Garry Kasparov we operate on the assumption that even the greatest players of a game in history will make mistakes and play sub-optimally at times. We do this because we recognize it is unrealistic to expect flawless play. And that is where tic-tac-toe is different. It’s not difficult to expect flawless play in tic-tac-toe.

In theory all games are solvable. There is an ideal way to play them to optimize your chances of victory. Two big things keep most games from tic-tac-toe’s fate though: the challenge of figuring out that optimal strategy, and the challenge of executing that strategy. For something like basketball the latter is the case. The optimal way to play is to intercept every pass and shot, and the instant you have the ball throw it in the net. This being effectively impossible also complicates finding the optimal strategy. Basketball remains interesting because it is both difficult to solve and play.

By contrast everything about tic-tac-toe lends itself to being easily solved, and played:

Rapid Iteration
Matches are fast so it is easy to test strategies, and see the ultimate outcome of your choices.

Perfect Information
You know everything there is to know about the state of the game at any given time: current positions, possible next moves, possible win conditions.

No Variance or Execution Barrier
The immediate outcome of every action can be predicted with 100% accuracy.

Lack of Complexity
Minimal variables and small scope at play make it easy to predict long term consequences of actions accurately.

No Competing Concerns
The one and only consideration to playing is where to place an X or O. Nothing within the game encourages anything but flawless decision making.

All these contributes to Tic-tac-toe’s outcome being too certain. Perfect certainty can ruin an otherwise good game like few things can. We want games to be learnable, but ideally never solvable. Too much certainty, and we make that too easy for players. But too much uncertainty makes the game unlearnable. Players will feel frustrated and cheated if a setback is too far removed from the cause in their mind. It appears unfair. We have to apply the above tools thoughtfully.

So let’s broadly classify them to understand how they can be used. Each is about the player’s relationship to information to make decisions.

— Hidden Information —

Uncertainty can come from not knowing everything. Hidden information might be about the variables, the mechanics, or the outcome. We talk about hidden info of outcome all the time: randomness or RNG. Hidden variables can be information hidden behind the fog of war in Starcraft, but also the nuance of a player’s ability to execute an action. If a player misses a headshot with a perfectly accurate gun, the outcome is certain. It’s the exact input of the player that was unknown. Lastly hidden mechanics mean some part of the game’s function is unknown.

What it accomplishes as a tool:
Hidden information encourages planning. It can gathering more information to make a decision later (scouting in Starcraft). It can be planning around potential outcomes (firing more bullets than needed in a shooter, anticipating misses). It can be experimenting with game mechanics to understand them intuitively.

When it’s too much:
So much information becomes hidden that players don’t understand the intended play. Ex: You make a wand that damages the target 60% of the time and heals them 40% of the time. Without these numbers visible, many players will not understand it is primarily a damage dealing weapon even if it’s tuned to be statistically better than more predictable alternatives.

— Separated Information —

Any uncertainty creates separation in player’s minds, but here I mean separation by design. A cause and effect might be separated by time, complexity, or association.

Time – Getting a bad ending in a JRPG because of 1 dialogue option early in the game.

Complexity – A damage calculation that’s entirely transparent will still create uncertainty if it’s very complex. Most players will not want to do complex calculations while playing.

Association – A fighting game with flashy, purely aesthetic effects communicates a unique power only through subtle visual effect variations.

What it accomplishes as a tool:
Separated information rewards investment. Players get long term learning objectives. Those that achieve this knowledge can set themselves apart from more junior players, even highly skilled ones. It is both practically rewarded in play, and a point of pride.

When it’s too much:
Even when explained, players are confused about why or how the cause and effect are associated.
Players hit roadblocks to improvement, and don’t even know what aspects of their play to look into.

— Competing Information —

When all else is clear, an action can still be uncertain if there is competing information. “I need lots of territory, “I need to preserve my troops” are both goals in many strategy games, and pursuing one risks the other. Whether it’s a binary choice or one of balance, there is no evident solution because there are multiple solutions that contradict each other.

What it accomplishes as a tool:
Competing information fosters player expression. This is where play styles, and role play are born. There are no longer just game players, but “aggressive” players, “patient”, “adaptable”, etc.

When it’s too much:
Players will feel overwhelmed, like their choices don’t matter, or that the game feels generic (player speak for ‘lack of theme or intended play’). It is generally better to offer polish a few select play styles than pure freedom. The latter is inevitably unmanageable as a developer.

Managing uncertainty is one of our primary jobs as game designers. It’s important enough that its misuse ruined tic tac toe. Next time I’ll be going over a practical case study on how I introduced uncertainty to tic tac toe to try and make it fun again!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s