private void clearLines() {
        List<Integer> lines = new ArrayList<Integer>();
        // Identify the lines to be deleted
        for (int y = 0; y < maze[0].length; y++) {
            boolean removeRow = true;
            for (BlockType[] aMaze : maze) {
                if (aMaze[y] == BlockType.EMPTY) {
                    removeRow = false;
                    break;
                }
            }
            if (removeRow)
                lines.add(y);
        }
        // Delete the lines
        for (Integer i : lines)
            clearLine(i);
        // Increase score
        if (lines.size() > 0)
            score += level * lineScores[lines.size() - 1];
        // Change level
        if (linesCleared >= LINES_PER_LEVEL) {
            level++;
            linesCleared = 0;
        }
    }