The My_navy project aims to recreate the classic Battleship game using signals. The game is played on an 8x8 grid, and each turn involves displaying the player's positions followed by the enemy's positions. The game concludes when all of a player's ships have been hit, determining the winner.
The file passed as parameter must contain lines formatted the following way:
LENGTH : FIRST_SQUARE : LAST_SQUARE
where LENGTH is the length of the ship, FIRST_SQUARE and LAST_SQUARE its first and last positions.
In this file, you must have 4 ships (of lengths 2, 3, 4 and 5).
Navigate to the root of the repository from your Terminal and run make
to build the static library,
now you have created a binary that can compile the program. You can also use make clean
to delete the .o
files created
by the make
command.
After successfully compiling the program, execute it with the following command:
./my_navy arg1 arg2
Replace arg1 and arg2 with the appropriate input parameters. If specific requirements exist for the input arguments, provide that information in this section.