Book Image

SFML Blueprints

Book Image

SFML Blueprints

Overview of this book

Table of Contents (15 chapters)
SFML Blueprints
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Chapter 4. Playing with Physics

In the previous chapter, we built several games, including a Tetris clone. In this chapter, we will add physics into this game and turn it into a new one. By doing this, we will learn:

  • What is a physics engine

  • How to install and use the Box2D library

  • How to pair the physics engine with SFML for the display

  • How to add physics in the game

In this chapter, we will learn the magic of physics. We will also do some mathematics but relax, it's for conversion only. Now, let's go!