You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
718 B

7 years ago
  1. // Carrier = 5
  2. // Battleship = 4
  3. // Cruiser = 3
  4. // Submarine = 3
  5. // Pilot = 2
  6. public class Battleship{
  7. private int[][] playerBaoard;
  8. private int[][] computerBoardDisplay;
  9. private int[][] computerBoardHidden;
  10. private static int playerHits;
  11. private static int ComputerHits;
  12. public Battleship(int x, int y){
  13. this.playerBoard = new int[x][y];
  14. this.computerBoardDisplay = new int[x][y];
  15. this.computerBoardHidden = new int[x][y];
  16. }
  17. public getComputerBoardHidden(){
  18. return this.computerBoardHidden;
  19. }
  20. public getComputerBoardDisplay(){
  21. return this.computerBoardDisplay;
  22. }
  23. public getPlayerBoard(){
  24. return this.playerBaoard;
  25. }