Book Image

PhoneGap By Example

Book Image

PhoneGap By Example

Overview of this book

Table of Contents (17 chapters)
PhoneGap By Example
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Planning the game


It is always good to have a plan before development. Let's decide what kind of game we would like to implement and describe the main use cases.

I think in the beginning, it should be a simple game. I decided to create a puzzle game, like Gem Match. Here are few examples in the stores:

The main principle of such games is:

  • Swap on adjacent color objects to exchange their positions

  • Match three or more colors horizontally or vertically to clear the elements and receive points

  • Accumulate as many points as you can

We will implement these principles, but instead of gems, we will use colored bubbles:

Bubbles of the same color will be cleared once they appear in a row or a column. After cleanup, new, randomly generated bubbles will drop from the top. If there are already three or more bubbles of the same color in a row, the player...