ECE 2524

Introduction to Unix for Engineers

Battleship <>

Usage

Very straightforward instrucitons to simply run ‘make’ and ‘./battleship’. Started playing immediately with no hassel!

Style

Very modular and visually pleasing code. The header and .cpp files were organized according to the funcion purposes. Very easy to read and understand all of the code. I do feel that adding ships to the game board could be made into it’s own .cpp file instead of main.cpp, but that is only a small detail I noticed.

Philosophy

It’s human readable, modular, seperable, and made as simple as possible. The code is not very loud, and it was clever to use system(“clear”) rather than printing a bunch of loud new lines to hide the opponent’s board from the player. The game is perfect except for a few bugs.

The bugs I found were:

  • Does not tell player they have already missed/hit a coordinate. (it seems this check was commented out in the code)

  • Player 2 does not see his current game board when placing his first ship.

Otherwise, everything was great about the project. Good job!