- * Calculates the change in x if we want to move in the specified direction.

+ * Calculates the difference in x-coordinate to an adjacent cell in the

- * @param direction The direction we want to move.

- * @return The change in x if we want to move in that direction.

+ * @param direction The relative direction of the adjacent cell.

+ * @return The difference in x-coordinate.

private int DX(int direction) {

- * Calculates the change in y if we want to move in the specified direction.

+ * Calculates the difference in y-coordinate to an adjacent cell in the

- * @param direction The direction we want to move

- * @return the change in y if we want to move in that direction.

+ * @param direction The relative direction of the adjacent cell.

+ * @return The difference in y-coordinate.

private int DY(int direction) {

* Checks if there is any cell that has a direction of '0'.

* This is a workaround function.

- * @return If the maze ~~we generated ~~contains errors.

+ * @return If the maze contains errors.

public boolean containErrors() {

for (int i = 0; i < height; i++) {