O'Reilly logo

Building an FPS Game with Unity 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

Adding a simple turret enemy

To start off with, UFPS already comes built in with an example enemy that we can work with, that is, a turret that will fire at a player if they get too close. More importantly, the turret is an example of how to damage a player, as well as how the player can damage objects. This will be quite useful once we create enemies. Let's take a look at how it's used in an example level:

  1. From the Project tab, go to the UFPS/Base/Content/Levels/SkyCity folder and then-double click on the UFPS_SkyCity.unity file to open it.
    Adding a simple turret enemy

    If you haven't gotten a chance to play this demo map yet, give it a try so that you're more familiar with the ...

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