Game behaviors that adapt to the player during the game (i.e. “online”) are a great thing. In fact, in a sense, they’re probably a requirement — otherwise your game is just a simulation. Adaptation makes the gameplay much more dynamic, and the levels more interesting for the player…
However, at the mention of the word “adaptation,” most developers think of machine learning (ML). Most games don’t use it; most games don’t need it. Yes, even the more advanced AI designs can be implemented without runtime learning.
Here are three complementary approaches, which actually work in practice…
1) Game Designers
“Most necessary adaptation in the behaviors is easily identified during development.”
The best games are very specifically designed in most aspects. Even the parts you consider emergent are identified by the designers, and improved iteratively. This is the case for gameplay, and the environment too. Designers create levels with multiple different approaches in mind for the player.
So in practice, there aren’t very many surprises;
The development team knows exactly what kinds of situations occur in the game, what roles or style the player can take, etc.
Designers can already create the different AI behaviors they require to support their ideas while in production.
In fact, there’s not much of a choice. It’s impossible to design the game well without building the AI supporting that gameplay. So the behaviors must be built offline.
2) Higher-Level Logic
With hard work, the designers can predict the majority of game situations and build behaviors for each of them. What’s left is putting them together at runtime…
To do this, it’s sufficient to have some simple logic that decide at runtime which static behaviors to select from. Adaptation comes from this higher-level logic; no learning is required here.
Generally speaking, learning is required if a behavior is missing, or if information is lacking. Designers can provide the first easily, but you need the game engine for the second…
3) Statistical Information
In the cases where behaviors must be personalized to the player (more so than just high-level logic), these fixed behaviors can be parameterized by data gathered about the player during the game.
Let’s call this indirect learning. The behaviors don’t change, but the raw data that supports them does change. So there’s no machine learning (ML) going on since no additional patterns are extracted from the raw data that’s available. It’s just a good use of statistics (though arguably, that defines machine learning :-).
Is Online Learning Useful?
These three tricks can help you make amazing adaptive AI with little hassle. Most games currently would benefit from machine learning during development, but there are few reasons to do it online.
Do you think online learning is a risky gimmick, or do you think it’s generally useful?













