put in some flags to prevent multiple re-writes of the polyfile and regenerating the mesh