This fixes #363 (closed). The long-range gravity task has to consider all the cells that were assigned to it at the rebuild time.
Additional improvements: