Space Racers! is a Space Invaders clone for the MBED. The goal is to avoid the oncoming alien onslaught by shooting them with your missiles. The aliens traverse the screen getting lower and lower until they either reach the bottom of the screen or shoot your spaceship player 3 times. To win the game, the user has to shoot all 9 of the enemy aliens. The controls can be handled either with the navigation switch or the Adafruit Bluetooth Connect app Control Pad on your mobile device. Left and Right arrows are used to move the player, the up arrow is used to shoot at the aliens.

Dependencies:   4DGL-uLCD-SE PinDetect mbed wave_player

Committer:
mdargie6
Date:
Wed May 02 18:49:04 2018 +0000
Revision:
0:aeb7a12718ed
okay

Who changed what in which revision?

UserRevisionLine numberNew contents of line
mdargie6 0:aeb7a12718ed 1 aliens[7].erase();
mdargie6 0:aeb7a12718ed 2 if (aliens[7].alive & aliens[7].x <= 17) {
mdargie6 0:aeb7a12718ed 3 dirs[7]=1;
mdargie6 0:aeb7a12718ed 4 aliens[7].y += 17
mdargie6 0:aeb7a12718ed 5
mdargie6 0:aeb7a12718ed 6 }
mdargie6 0:aeb7a12718ed 7 if (aliens[7].alive & aliens[7].x >= 98) {
mdargie6 0:aeb7a12718ed 8 dirs[7]=-1;
mdargie6 0:aeb7a12718ed 9 aliens[7].y += 17
mdargie6 0:aeb7a12718ed 10 }
mdargie6 0:aeb7a12718ed 11 aliens[7].x += 1*dirs[7];
mdargie6 0:aeb7a12718ed 12 }
mdargie6 0:aeb7a12718ed 13