public synchronized boolean incrementLevel2(Shape shape) {
        boolean[][][] shapeMatrix = shape.getMatrix();
        int x, y, z;
        for (int k = 0; k < shapeMatrix[0][0].length; ++k) {
            for (int i = 0; i < shapeMatrix.length; ++i) {
                for (int j = 0; j < shapeMatrix[0].length; ++j) {
                    x = i + shape.getDesfX();
                    y = j + shape.getDesfY();
                    z = k + shape.getLevel() + 1;
                    if (x > 0 && x < matrix.length - 1 && y > 0 && y < matrix[0].length - 1 && z < matrix[0][0].length) {

                        if (matrix[x][y][z]) {
                            System.out.println("===========");
                            System.out.println("X: " + x);
                            System.out.println("Y: " + y);
                            System.out.println("Z: " + z);
                            System.out.println("d");
                            joinShape(shape);
                            return true;
                        }
                    }
                }
            }
        }
        shape.setLevel(shape.getLevel() + 1);
        return false;
    }