Completed gridmaker (with a few bugs)