Completed the initial grid and corrected some bugs.