minor rearrangements in code
germ of map generation process