Chapter 3. Implementing Weapons and Ammo

Any good side-scroller game wouldn't be fun if you didn't have cool weapons of great destruction. One thing to pay attention to is that CRYENGINE includes full support for weapons and ammo, right out of the box. However, my goal here is to show you how much you can do on your own. Many people struggle over figuring out how to add extensive new code while maintaining great integration with the rest of CRYENGINE. I want you to learn that anything you can think of is possible, and implementing a custom weapon and ammo system is no exception. In this chapter, you will learn how to create a complete weapon and ammo system and link them to events and other systems such as the Game Rules. Here is what you will learn:

  • How to create a weapon class
  • How to create an ammo class
  • How to create ammo events