This book is a guide for you to develop your own android game. The various steps which are necessary for one to come up with complete and functional game have been discussed. The book begins by guiding on how to create a new project for the game application. You will get to understand how the game to be developed will function from the plan established at this stage. The next part of the book discusses the loop to be used for the game, in other words, how the activities for the game will flow. This will help you to get organized. On reading this book, you will be guided on how to display images on the screen of an android device. The kind of images which are highly preferred is discussed. The book will also guide you on how …show more content…
We need to prepare the environment ready for programming. You can choose to use either eclipse or android studio as the IDE (Integrated Development Environment). If you have not created the AVD (Android Virtual Device), then begin by doing so. In case you do not know how to do this, consult from the first part of this book and you will definitely get assistance.
To create the AVD, navigate to “Window -> Android SDK and AVD Manager”. At this point, click on the button written “New” and then specify the details for your AVD. You can then create a new project for your game application. Just click on “New -> Project” and then choose “Android Project”. A dialog willappear on which you will have to specify the details of the project: You can try to test the project by running it. You will notice that it comes with a default “Hello World!” program. Once you see this, just know that you are set to get into programming.
You can open the main java class with name “MainActivity.java”. It comes with the following code by default: import android.os.Bundle; import android.app.Activity; public class MainActivity extends Activity {
/** Called when the activity is first created.