Moved all map drawing code into map.js.
Still not sure if I want to move the unit loop into map.js as well or keep it external.