Thank you, I'm glad you enjoyed it!
Here's the code for the countdown block. The one for the countup block is identical, but excludes the countdown_iteration bit.
The var grid is an array with all of the possible grid positions, (0,1) , (2,5), etc., block_array is an array of all positions of spawned blocks, and gold_x_y is the position where you last picked up a block.
I'm pretty sure that my problem lies in the while loops, but I'm not sure.