O'Reilly logo

Getting Started with UDK by John P. Doran

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

Chapter 2. Tower Defense

Now that we have an area we can play around with, let's start taking charge of our game environment and get some basic gameplay in.

Over the course of this chapter, we will perform four tasks:

  • Spawn enemies that run to the base
  • Damage our base and create a Game Over scenario
  • Create/Spawn a single tower
  • Easily create multiple towers with prefab

With that said, let's get started!

Spawning enemies

Now that we have the basic world and a functioning player, it would be a good time to start adding things that the player can actually fight against. In this section, we will be spawning enemies and giving them a behavioral pattern.

The first step to take in order to create enemies is to first create the points in which the enemies can be ...

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