O'Reilly logo

UnrealScript Game Programming Cookbook by Dave Voyles

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

Adding an AI pawn via Kismet

With our means for navigating a level out of the way, we can finally work on adding a pawn who will take advantage of the things we've built, and allow the pawn to wander around the level. Later on we're even going to add functionality so that it follows us around the map.

Getting ready

We're going to create a new bot, which is really just an AI controller for pathfinding, by extending from UDKBot.

Class TutBot extends UDKBot;

As we move along, we'll begin to add more functionality to it such as the ability to wander using the PathNodes or NavMeshes, as well as follow our pawn.

How to do it...

One of Kismet's many useful functions is the ability to spawn bots and pawns. In Chapter 8, Miscellaneous Recipes we'll cover how ...

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