diff --git a/src/GomokuBoard.java b/src/GomokuBoard.java index 0dc4b51..e864dab 100644 --- a/src/GomokuBoard.java +++ b/src/GomokuBoard.java @@ -33,6 +33,12 @@ public class GomokuBoard{ this(width, height, null); } + /** + * This constructor take the width and the height to creat a board of gomoku. + * @param width Size of width. + * @param height Size of height. + * @param colors Is colors of cells after load a game. + */ public GomokuBoard(int width, int height, Color[][] colors){ this.firstCell = new GomokuCell(Color.NIL); this.boardWidth = width; @@ -41,6 +47,12 @@ public class GomokuBoard{ } + /** + * This method gen all cells in the board and link each other. + * @param width Size of width. + * @param height Size of height. + * @param colors Array of Color. + */ private void genCells(int width, int height, Color[][] colors){ this.firstCell = new GomokuCell(colors == null ? Color.NIL : colors[0][0]); GomokuCell act = this.firstCell;