Upgrading the AI Enemies

In this chapter, we will add more functionality to our AI enemies in order to introduce the potential for the player to fail, and to create greater gameplay diversity. At this point, we are going to begin settling on the kind of challenge we want to offer the player. We are going to create zombie-like enemies that will relentlessly pursue the player, creating an action-focused experience, where the player must try to survive against hordes of enemies. We will start by giving more capability to the AI, including the ability to deal damage and use wandering patterns, in order to increase the difficulty of player survival. We will then turn our attention to the player, giving them the ability to fight back against these dangerous enemies. Finally, we will complete the balancing of our increased difficulty by creating a system to spawn new enemies in the game world over time. In the process, we will cover the following topics:

  • Introducing an enemy melee attack that will damage the player's health
  • Giving the AI the ability to hear the player's footsteps and shots
  • Having the enemy investigate the last known location of the player based on sound
  • Allowing the player to destroy the enemies with their gun
  • Spawning new enemies in the world
  • Setting AI enemies to wander the Level randomly
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset