Fixed a major bug in foldTiles.

The regions it was generating were using the direct tree co-ordinate system, not the offsetted one used by atLocation.

Been fixing documentation too.