xiv
Introduction
Hi there, and welcome to the world of Android game development. You came here to learn about
game development on Android, and we hope to be the people who enable you to realize your
ideas.
Together we’ll cover quite a range of materials and topics: Android basics, audio and
graphics programming, a little math and physics, and a scary thing called OpenGL ES. Based on
all this knowledge, we’ll develop three different games, one even being 3D.
Game programming can be easy if you know what you’re doing. Therefore, we’ve tried to
present the material in a way that not only gives you helpful code snippets to reuse, but actually
shows you the big picture of game development. Understanding the underlying principles is the
key to tackling ever more complex game ideas. You’ll not only be able to write games similar to
the ones developed over the course of this book, but you’ll also be equipped with enough
knowledge to go to the Web or the bookstore and take on new areas of game development on
your own.
A Word About the Target Audience
This book is aimed first and foremost at complete beginners in game programming. You don’t
need any prior knowledge on the subject matter; We’ll walk you through all the basics. However,
we need to assume a little knowledge on your end about Java. If you feel rusty on the matter, we’d
suggest refreshing your memory by reading the online edition of Thinking in Java, by Bruce Eckel
(Prentice Hall, 2006), an excellent introductory text on the programming language. Other than
that, there are no other requirements. No prior exposure to Android or Eclipse is necessary!
This book is also aimed at the intermediate-level game programmer that wants to get her
hands dirty with Android. While some of the material may be old news for you, there are still a lot
of tips and hints contained that should make reading this book worthwhile. Android is a strange
beast at times, and this book should be considered your battle guide.
How This Book Is Organized
This book takes an iterative approach in that we’ll slowly but surely work our way from the
absolute basics to the esoteric heights of hardware-accelerated game programming goodness.
Over the course of the chapters, we’ll build up a reusable code base, so we’d suggest going
through the chapters in sequence. Of course, more experienced readers canskip certain sections
they feel confident with. Just make sure to read through the code listings of sections you skim
over, so you will understand how the classes and interfaces are used in subsequent, more
advanced sections.