Hex World AI – New World, Broken AI

With the announcement that Hex World had gotten through to the world finals of the Imagine Cup Riccardo, our resident world programmer, decided that he wanted to upgrade Hex World for the final stage. He had been thinking about how to bring Hex World from small individually loaded levels to vast sprawling worlds to explore. This meant breaking a lot of what the current world system of Hex World did and throwing away many of the constants we were all used to.

This means that the 3D A* solution wouldn’t work with the new world in it’s current state. The solution mapped entire levels for the AI to navigate, with vast worlds these maps would become unbearably large, take a lot of time to generate and most of the map would be useless to the system. So at this point I had two choices, either make a new system, or go through some painstaking remodelling of the current system to create small maps that move with the AI character that is using it.

I opted for a new system, for two reasons;

  1. we wanted a simpler AI system available as well as the complex one that would allow “dumb” AI to blindly navigate and chase and attack the player.
  2. with the world finals looming, AI needed to be working again quickly and remodelling the 3D A* solution may not have been possible in the time frame.

So simple AI is what Hex World needed, simple AI is what it got. The AI had no knowledge of the world and simply reacted to what was in front of them, using normal vectors to redirect around static obstacles and using a sphere collider as a sensor for dynamic objects to avoid the AI walking into other AI. I built the system in a vacuum so that I could not make any use of Hex World code so that it wouldn’t break if something else in Hex World got changed.

With that, here’s the first showcase of the new simple AI:

And here is a bigger shocase:


Author: mfhartydev

I'm a programmer who loves games and has always dreamed of making them.

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