It took a few stages to get there, but we have a convenient interface with the game. We noticed a few important things along the way:
There are many possible ways to define navigation formally.
It's important to consider the definition the state of the animat in space (context).
Inputs make the information about space explicitly available to the AI, although it doesn't have to use the information.
Outputs allow the AI to control the resulting movement, and influence the outcome in a flexible fashion.
We must take into account the high-level requirements to decide which model to pick.
We've established a scaffolding for movement that's problem independent (can handle any type of movement).
This is an example of a specification process. It's a very important phase in AI development, because it defines the problem by exposing information to the AI. By doing this wrong, we can cripple the entire development. Conversely, selecting the right specification can make the AI very simple to develop. It's such an important concept—along with knowledge representation—that we'll dedicate the entire next chapter to it.
Here's another chance to try out a quick demo before we discuss some concepts. Among the demos on the web site at http://AiGameDev.com/, there is one for Part II called Pinbot, along with source code. Follow the step-by-step procedures online to launch him into the game. Pinbot can actually detect the orientation of the wall when collisions occur. The direction of the collision allows Pinbot to ricochet off the wall in a direction that's very likely to be clear, like a pinball would! Once again, nothing complex, but it's something to distract us for a few moments before we discuss the importance of specifications and knowledge representation.