CompSci 308
Fall 2018
Software Design and Implementation

Build a Breakout Game

If children can build, play and understand games that work, it's possible that someday they will understand and design systems that work. And the world is full of complicated systems. —Sara Corbett

Back in the 1980s, video arcade games were in their prime. Local restaurants, pubs, and arcades lured customers with all of the latest titles: Pac-man, Galaxian, Donkey Kong, Tempest, Centipede, Defender, and more. (Un)fortunately, the rise of home video game systems and home computers relegated these gems to the back storage rooms of many establishments. They are not forgotten, however — even today, arcade cabinets are collected by enthusiasts and arcade ROM emulation systems such as MAME allow my generation to experience these relics first-hand on modern hardware (including, briefly, the iPad).

Breakout is a popular extension to the first cabinet arcade game, Pong, that was designed by Steve Jobs and Steve Wozniak, the founders of Apple, Inc. It was such a big hit that, to this day, it is still spawning additional game spin-offs in the form of the game Arkanoid. These games build on the basic premise of Breakout, clearing a field of bricks, but add elements of every other game imaginable. Here is a (long) video of the original gameplay and here is playlist of dozens of variants of the original game. If you are having trouble seeing implementing this game as a challenge, here are several specific variants that may get you thinking:

Specifications

Write a Java program to play a 2D game of Breakout, in which a ball bounces around the screen and destroys blocks as it bounces into them. The player controls a paddle to block the ball from moving off the screen. The ball may bounce off of some sides of the screen; however, if the ball moves off a specific area of the screen (typically the bottom), the player loses a life and the ball is reset to its starting position. If the player misses blocking the ball too many times, the game should end and display a message that the player lost. If all the blocks are cleared from the screen, the level should end and a new one loaded (with a different configuration of blocks). If the player clears all the levels, the game ends with a message that declares the player won.

It does not need to be the greatest variant created, or even have sophisticated graphics, but it does have to meet a few basic requirements:

You will use JavaFX as a starting point for building your game. You are welcome to look at the tutorial below or any other ones you find online, but your game should be distinctly different from any given examples you find (i.e., create a Breakout game, do not simply copy one). While some basic code will be discussed in class, it is expected you will learn most of the details by reading online examples and documentation.

Project Goals

This project is intended as a warm-up to get you started coding a project from scratch: so you can determine if the course is at the right level for your abilities and so we can determine a baseline for your sense of design. It is also intended to introduce you to using the JavaFX software since we will use it throughout the semester.

Deliverables

You will submit this project in stages to introduce you to the course's basic workflow.

Resources