Extending the Framework
This chapter begins by reviewing the code for the game from the previous chapter. Your main focus will be streamlining your code from the previous chapter by refactoring common elements into new classes that can be reused as needed. This will also make it easier to introduce more-advanced features, such as new methods for processing user input. Then you will see how your new classes can be used as a basis for additional game projects. Finally, you will improve your custom extensions of the Actor class by adding improved collision detection and response, managing multiple animations, and implementing physics-based movement.