Fixed dot collision detection and added wall collision detection for dots.