New makeBlocks function