seperation between saving to a file and saving to a string for collision grids