Enemies and Artificial Intelligence

This chapter brings the Dead Keys project to an important developmental stage, adding a certain roundness and completeness by adding enemy characters (zombies). In creating an enemy, we'll bring together many features that we've already created, from health and damage, to combat mechanics and UI elements. Specifically, we'll build a zombie enemy that can wander the level in search of the player, then chase the player when found, and finally, attack them when close enough. In addition, the player will be able to engage and attack the zombie in word-combat. To create this functionality, we'll work with Prefabs, Navigation Meshes, Artificial Intelligence (AI), and Finite State Machines (FSMs), so let's get ...

Get Mastering Unity 2017 Game Development with C# - Second Edition 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.