Difficulty level: 2
Space Invaders is a classic arcade game from the 80s. The player aims to shoot an invading alien armada, before it reaches the planet's surface using a mounted gun turret.
The player can only move left or right. The aliens also move from left to right, and also down each time the reach the side of the screen. The aliens also periodically drop bombs towards the player.
Once the player has destroyed a wave of aliens, the game starts again. The aim is to achieve the highest score possible before either being destroyed by the aliens, or allowing them to reach the planet's surface.
- The player should be able to clear at least one wave of aliens
- The player's score should be displayed at the end of the game
- Responsive design
- Each wave gets more difficult
- Persistent leaderboard using
localStorage
The main challenge here is the movement of large groups of aliens in formation, and the animation of the bombs and player's shots. There are several approaches here, with collision detection being the more challenging.
- Make sure you spend plenty of time planning before you start coding
- Make sure you understand all of the rules of the game
- Make a checklist of all the features you want to add to the game
- Keep It Stupid Simple
- Refactor your code as you go
- Make sure you have a good idea of what your MVP is and only add extra features once you have achieved it
- Do just enough styling to get started, then once you have your MVP polish up the styling before moving on