Cubes collission not working when jumping

http://pastebin.com/Rz7b1TPn

When you jump and there a blocks placed infront of you, you will just fly through them. I can’t jump on blocks because then I fall inside of the terrain.