Cleaned up Map.cs

Refactored and cleaned up the Map.cs class, added conditional Debug
statements to help in debugging.  Moved obsolete code to the
Obsolete.txt file