Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Learning Java by Building Android  Games

You're reading from   Learning Java by Building Android Games Learn Java and Android from scratch by building six exciting games

Arrow left icon
Product type Paperback
Published in Aug 2018
Publisher
ISBN-13 9781788839150
Length 774 pages
Edition 2nd Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
John Horton John Horton
Author Profile Icon John Horton
John Horton
Arrow right icon
View More author details
Toc

Table of Contents (28) Chapters Close

Preface 1. Java, Android and Game Development FREE CHAPTER 2. Java: First Contact 3. Variables, Operators and Expressions 4. Structuring Code with Java Methods 5. The Android Canvas Class – Drawing to the Screen 6. Repeating Blocks of Code with Loops 7. Making Decisions with Java If, Else and Switch 8. Object-Oriented Programming 9. The Game Engine, Threads, and The Game Loop 10. Coding the Bat and Ball 11. Collisions, Sound Effects and Supporting Different Versions of Android 12. Handling Lots of Data with Arrays 13. Bitmap Graphics and Measuring Time 14. The Stack, the Heap, and the Garbage Collector 15. Android Localization -Hola! 16. Collections, Generics and Enumerations 17. Manipulating Bitmaps and Coding the Snake class 18. Introduction to Design Patterns and much more! 19. Listening with the Observer Pattern, Multitouch and Building a Particle System 20. More Patterns, a Scrolling Background and Building the Player's ship 21. Completing the Scrolling Shooter Game 22. Exploring More Patterns and Planning the Platformer Project 23. The Singleton Pattern, Java HashMap, Storing Bitmaps Efficiently and Designing Levels 24. Sprite-sheet animations, Controllable Player and Parallax Scrolling Backgrounds 25. Intelligent Platforms and Advanced Collision Detection 26. What next? Index

Setting up Android Studio

Setting up Android Studio is quite straightforward if a little lengthy. Grab some refreshment and get started with the following steps.

  1. Visit developer.android.com/studio/index.html. Click the big green button to proceed.
    Setting up Android Studio
  2. Accept the terms and conditions by checking the box and then click the big blue button DOWNLOAD ANDROID STUDIO FOR WINDOWS.
    Setting up Android Studio
  3. When the download is completed run the file you just downloaded. It has a name that starts android-studio-ide… the end of the name of the file will vary based on the current version at time of reading.
  4. Click the Next button to proceed.
    Setting up Android Studio
  5. Leave the default options selected as shown next and click the Next button.
    Setting up Android Studio
  6. Next, we need to choose where to install Android Studio as shown in the next image.
    Setting up Android Studio

    The install wizard recommends 500mb, however there are more requirements later in the install process. It is much easier if you have all your Android Studio parts as well as your project files on the same hard drive. I recommend having at least 2gb of free space. If you need to switch drives to accommodate this, then use the Browse.. button to browse to a suitable place on your hard drive.

    Tip

    Write down a note of where you choose

  7. When you are ready click the Next button.
  8. In this next window you are choosing the folder in your start menu where Android Studio will appear. Leave it at the default as shown next.
    Setting up Android Studio
  9. Click Install.
  10. This step might take some time, especially on older machines or if you have a slow Internet connection. When this stage is done you will see this screen.
    Setting up Android Studio
  11. Click Next.
  12. Android Studio is now installed, check the Start Android Studio check-box and click the Finish button.
    Setting up Android Studio
  13. You will be greeted with the Welcome screen as shown next.
    Setting up Android Studio
  14. Click the Next button.
  15. Choose Standard install type as shown next.
    Setting up Android Studio
  16. Click the Next button.
  17. Choose whichever color scheme looks nice to you, I chose InteliJ as shown next.
    Setting up Android Studio
  18. Click Next.
  19. Now you will see the Verify Settings screen.
    Setting up Android Studio
  20. Click the Finish button. Android Studio will now commence some more downloads, they could take some time.
  21. When Android Studio is ready you will have the option to run Android Studio. At this point click the Finish button. Android Studio is ready- probably. You can leave it open if you are carrying straight on with the next section or you can close it and then reopen it when instructed in the next section.

Final step

Using your preferred file manager software, perhaps Windows Explorer, Create a folder called AndroidProjects. Make it at the root of the same drive where you installed Android Studio. So, if you installed Android Studio at C:/Program Files/Android then create your new folder as C:/AndroidProjects.

Or if you installed Android Studio at D:/Program Files/Android then create your new folder as D:/AndroidProjects.

Note

Note that the screen shots in the next section show the AndroidProjects folder on the D: drive. This is because my C: drive is a bit full-up. Either is fine. Keeping it on the same drive as the Android installation is neater and could avoid future problems so do so if you can.

Tip

Notice that there is no space between the words Android and Projects and that the first letter of both words is capitalized.

You have been reading a chapter from
Learning Java by Building Android Games - Second Edition
Published in: Aug 2018
Publisher:
ISBN-13: 9781788839150
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image