In chapter 14, I learned about artificial intelligence. A good AI should be challenging, believable, and programmable. Sometimes, instead of improving how the games AI works, some developers just give the AI advantages over the player. Now I can see why developers do that, programming an AI can be very challenging. I improved StarRacer to have a fully functional AI. It will slowdown and navigate around asteroids. It is a pathfinding AI. It works sort of like the maze AI, but much more complex as there are no defined borders for the AI to navigate, and it must calculate a path in real time. In the video below, I am on the left while the AI is on the right. It isn't as good as me, but it is capable of reaching the finish line.
Source Code
Source Code