Creating a shooting system

As we saw in Chapter 5, Freeze! Creating an Intergalactic Shooter, there are many different ways a player can "shoot" something. As we also learned, in our game, the player will shoot at a range of different objects. Therefore, there are a few things that you may want to consider when it comes to implementing the elements of shooting. One such thing is the "consequence" for shooting or, alternatively, getting shot. For example, when a player shoots at the enemy, how many hits can the enemy take before it is destroyed, and vice versa for the player? Are some enemies harder than others, perhaps more powerful? Now, the answers to these kinds of questions become refined through playtesting. It is what we game designers refer to as "balancing", and ideally you want a game to be not too easy or too hard at the beginning, but something that grows in difficulty as the player becomes more skilled at it.

For now, we will work on setting the shooting system up, then we will look at how to balance it later. In particular, the shooting system is not just one script, but in our case, it is made of the interactions between the PlayerController, the EnemyController, and the BulletController. This chapter wants also to show you how it is possible to create challenging enemies without using complex AI algorithms not suitable for beginners since sometimes less is more. So, let's explore these controllers one by one.

..................Content has been hidden....................

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