Recode and Blocks

Recoded everything from scratch and added the blocks.