Now that we’ve completed both the “AdvancedAttack” and “Boxer” classes, let’s take some time to test them out and have fun with them!
Shown here is some example code that uses both an AdvancedAttack that is added to the player, and a Boxer used as an enemy. Try using this code at first and then try making your own. Check out what a difference these classes both add to the game! Notice how there is an “f” after 0.2. This is to tell the computer that this number is a float, there will be an error if you don’t put this.
Once you’ve spent some time using these two new classes in your game, go ahead and move on to the next section where we will create one more new class to add even more mechanics to this game.