Craft with Code 3: Shooter Games with MIT App Inventor

Use a database in your animated Android app to offer features like leaderboard

Have you had an idea for an app and wondered what to do next? With MIT App Inventor, you can take your idea to action – no programming experience required. It gives you building blocks that you snap together like LEGOs to build an app. You can have a basic app ready in under 30 minutes!

What you’ll learn

  • Coding by building Android apps with App Inventor. In this course, which is the 3rd course in the series, we will code a game of Pong..
  • Persist data across sessions and devices using a database. Use this to offer advanced features like a leaderboard..
  • Equip your app to make decisions using IF-ELSE STATEMENTS. Use flow control to code conditional logic of an algorithm..
  • Give animated sprites autonomy to interact with each other with collision events. Make sprites responsive to player’s actions and canvas perimeter..
  • Familiarize with APIs – WHY they are popular, WHAT lies under the hood and HOW to use them, with live demo..

Course Content

  • Introduction –> 1 lecture • 1min.
  • Demo of Pong –> 1 lecture • 2min.
  • App’s Design –> 1 lecture • 3min.
  • Code –> 4 lectures • 33min.
  • Concepts –> 7 lectures • 54min.
  • Project –> 1 lecture • 11min.

Craft with Code 3: Shooter Games with MIT App Inventor

Requirements

  • You will need a laptop or desktop with web browser, an Android phone or tablet and a stable internet connection..
  • It is recommended that you have completed the previous courses in the series..

Have you had an idea for an app and wondered what to do next? With MIT App Inventor, you can take your idea to action – no programming experience required. It gives you building blocks that you snap together like LEGOs to build an app. You can have a basic app ready in under 30 minutes!

About App Inventor:

MIT App Inventor is the result of a collaboration between the Massachusetts Institute of Technology and Google. It has 8.2 M users in 195 countries who have built over 34 M apps with it. Just this month has had 890.1 K active users. Applications include Artificial Intelligence, Internet of Things and Cloud Computing.

Examples of apps built include: a pedometer app to count and report daily footsteps; an app to monitor the home garden, detect when plants need watering and irrigate them from anywhere in the world; an app that learns to play rock-paper-scissors using machine learning; the only limit is your imagination!

About the Series:

In Craft with Code, participants learn by doing, growing skill by developing apps of increasing complexity through a series of courses. In each course, I introduce a new app and show you how to build it step by step. In the process, I introduce new software concepts. You will apply the concepts to bring your own ideas to life in the course project. All the code from a course is available to you to download and use in your projects.

You will need a laptop or desktop with a web browser and an Android Phone. I use a MacBook Pro with Opera browser and a Google Pixel phone. You will need a Google account to sign up and sign in. App Inventor runs in the browser, so there is nothing to install to get started developing apps.

About this course:

In this course, I show you how to use a database in your Android app. We shall build the classic computer game of Pong. This course builds on the previous course showing how to create an animated computer game using image sprites on a canvas. I show you how to write procedures that package code and help keep our programs tidy and well-organized. I introduce you to one of the best-kept secrets of App Inventor, which is, abstract components. These come in handy when writing programs where components take concrete shape during game-time!

Web 2.0 is all about interactivity, where Web 1.0 was about “read-only” content served on a web-page. In Web 2.0, APIs have emerged as the de facto way to discover, access and share information to integrate in apps. I show you the basics of SQL, the language that a database speaks, and then demystify APIs.

At the end of this course, you should have all the knowledge you need to build your own computer games in App Inventor, modeled on iconic games like Super Mario Run or Temple Run.

Credits:

I want to thank Prof. David Wolber who is my inspiration for jumping on-board MIT App Inventor and taking the technology out to others. His Course-in-a-box teaching materials are the foundation on which I built this course. And I want to thank the folks at MIT for this project.

Let’s rock and roll.

Get Tutorial