Learning Outcomes

By the end of this chapter, you will be able to:

Add a SentryDrone to your scene.

Add a script to the SentryDrone so that it spins on the Y axis.

Configure the SentryDrone so that it will lock on and fire at the player.

Though it’s fun for a while to walk around shooting at Crates, after a while it becomes quite boring. In this chapter, we’ll add some enemies to the game in the form of SentryDrones.

The SentryDrones will spin on the Y axis.

When the player is in front of the Drone, it will stop spinning and fire lasers at the player.

The Drone will lock onto the player’s position and continue to shoot, until the player moves out of sight for a set duration.

The SentryDrone 3D models ...

Get Game Audio with FMOD and Unity now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.