refactored some code
commenting 
add basics for creating and managing tiles and maps.