A version of Battleships for the BBC MicroBit This is just a small project I made for my Computer Science class.
Requirements:
- Two microbits with battlebits installed on them.
- A source of power for the microbits
Setup:
Press the reset buttons on the backs of the microbits. Stagger the button presses to ensure the player number is not duplicated.
How to play:
In the first stage you get to place your five ships. You do this by using button B to move horizontally and A to move vertically. Press A+B to place the ship. If you wish to replace a ship, select its position and press A+B again.
Once you have placed your ships the screen will tell you to wait. Once both players have placed their ships, the screen will show a heart. At this point, player 1 will be able to attack. Attacking is done by using button B to move horizontally and A to move vertically then by pressing A+B to fire.
Once a player has made their move, the other player will be able to attack.
A miss is indicated by a dim light and a hit is indicated by either a dim flashing light in view mode or a solid light in attack mode. A solid light in view mode indicates the position of your ships.
Once a player destroys all five targets, the game will end and will read out your score.