O'Reilly logo

SFML Blueprints by Maxime Barbier

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Building a Tetris clone

Now that we've created a complete game, let's build another one, a Tetris clone. This game is simpler than the previous one and will take less time to build, but is still very interesting. In fact, the internal architecture of this game is really different from the others. This is due to the kind of game that it is: a puzzle. The aim of the game is to fill lines of a grid with pieces made of four squares. Each time a line in completed, it's destroyed, and points are added to the player. Because this is a different kind of game, there are several implications as there is no player or no enemies in this game, only pieces and a board (grid). For this game, I will focus on the game logic only. So I will not reuse the previously ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required