Book Image

Kivy Blueprints

Book Image

Kivy Blueprints

Overview of this book

Table of Contents (17 chapters)
Kivy Blueprints
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
The Python Ecosystem
Index

Summary


In this chapter, we built a playable replica of the 2048 game. We also showcased a number of implementation details that can be reused in other similar projects:

  • Creating a scalable board that fits the screen in any resolution and orientation

  • Putting together custom tiles, and implementing smooth movement for those with the help of Kivy's Animation API

  • Mapping player's controls to both touch screen gestures and keyboard arrow keys at the same time, to account for any control scheme the user might expect from the game

The Kivy framework supports game development nicely; in particular, canvas rendering and support for animations can be very useful when building video games. Prototyping in Kivy is also feasible, albeit somewhat harder to do than in JavaScript (a modern browser is a very powerful platform, and it's especially hard to beat when it comes to cheap prototyping).

The resulting Python program is also inherently cross-platform unless you're using an OS-specific API in a way that...