O'Reilly logo

Unity 4.x Game AI Programming by Thet Naing Swe, Aung Sithu Kyaw, Clifford Peters

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Setting up the map

To get started, we'll build a simple scene, as shown in the following figure. This is the first scene in our sample project called NavMesh01-Simple.scene. You can use a plane as a ground object and several cube entities as the wall objects. Later, we'll put in some AI agents (of course, our all time favorite tanks) to go to the mouse-clicked position, as in an RTS game.

Setting up the map

Scene with obstacles—NavMesh01-Simple.scene

Navigation Static

Once we've added the walls and ground, it's important to mark them as Navigation Static, so that the navmesh generator knows those are the static obstacle objects to avoid. To do this, select all those ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required